Quantcast
Channel: Fast Lightweight Expression Evaluator
Viewing all articles
Browse latest Browse all 96

Closed Issue: Implicit castor is not used in FLEE expression [7048]

$
0
0
I have implemented an implicit conversion to a double in a class (DoubleWrapper) that is used as a variable. When I use this class in C#, it works as expected:
double dResult = Math.Cos( aDouble );
However the same expression does not work in FLEE.
IDynamicExpression expression = context.CompileDynamic( "Math.Cos( aDouble )" );
It throws an exception indicating it cannot find Cos(DoubleWrapper)
 
It seems to me that FLEE should behave the same as C#. Perhaps when it does not find the initial method signature, try to find the first method with a signature that can be used via implicit conversion of the parameter.
 
The attached file contains example code to better explain the problem.

Viewing all articles
Browse latest Browse all 96

Trending Articles