File tree Expand file tree Collapse file tree
include/codi/expressions/complex Expand file tree Collapse file tree Original file line number Diff line number Diff line change 66 ${CODIPACK_NAME}
77 VERSION ${CODIPACK_VERSION}
88 DESCRIPTION "CoDiPack - Code Differentiation Package"
9- HOMEPAGE_URL "http://scicomp.rptu.de/software/codi" )
9+ HOMEPAGE_URL "http://scicomp.rptu.de/software/codi"
10+ LANGUAGES CXX )
1011
1112add_library (${PROJECT_NAME } INTERFACE )
1213
Original file line number Diff line number Diff line change @@ -199,6 +199,31 @@ namespace codi {
199199
200200 return *this ;
201201 }
202+
203+ #if CODI_HasCpp20
204+ using Base::real;
205+
206+ template <typename Arg>
207+ void real (ExpressionInterface<InnerReal, Arg> const & arg) {
208+ Base::values[0 ] = arg;
209+ }
210+
211+ void real (InnerReal const & arg) {
212+ Base::values[0 ] = arg;
213+ }
214+
215+ using Base::imag;
216+
217+ template <typename Arg>
218+ void imag (ExpressionInterface<InnerReal, Arg> const & arg) {
219+ Base::values[1 ] = arg;
220+ }
221+
222+ void imag (InnerReal const & arg) {
223+ Base::values[1 ] = arg;
224+ }
225+
226+ #endif
202227 };
203228
204229 namespace RealTraits {
You can’t perform that action at this time.
0 commit comments