You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using DynamicExpressionParser.ParseLambda in a dotnet console application.
The expression I'm parsing is pretty simple, and it involves comparing an integer and a byte.
It's working just as expected, unless I'm using the dotnet trimmer in full mode, in which case it's raising a ParseException.
I've already tried to root assembly System.Linq.Dynamic.Core for the trimmer, but it doesn't fix the issue.
Could you please help me find a solution?
2. Exception
System.Linq.Dynamic.Core.Exceptions.ParseException
Operator '==' incompatible with operand types 'Byte' and 'Int32'
at System.Linq.Dynamic.Core.Parser.ExpressionParser.CheckAndPromoteOperands(Type, TokenId, String, Expression&, Expression&, Int32)
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseComparisonOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseLogicalAndOrOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseIn()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseAndOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseOrOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseLambdaOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseNullCoalescingOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.ParseConditionalOperator()
at System.Linq.Dynamic.Core.Parser.ExpressionParser.Parse(Type , Boolean )
at System.Linq.Dynamic.Core.DynamicExpressionParser.ParseLambda(Type, ParsingConfig, Boolean, ParameterExpression[] , Type, String , Object[] )
at System.Linq.Dynamic.Core.DynamicExpressionParser.ParseLambda(ParsingConfig , Boolean, ParameterExpression[], Type , String, Object[] )
at System.Linq.Dynamic.Core.DynamicExpressionParser.ParseLambda[T,TResult](ParsingConfig, Boolean, String , Object[] )
at SldcTrimmer.LambdaExtensions.ParseLambda[T1,T2](String) in D:\Dev\Zitch\Issues\SldcTrimmer\SldcTrimmer\LambdaExtensions.cs:line 10
at SldcTrimmer.Program.Main(String[]) in D:\Dev\Zitch\Issues\SldcTrimmer\SldcTrimmer\Program.cs:line 14
3. Fiddle or Project
Here is a repro: https://github.com/tranb3r/Issues/tree/main/SldcTrimmer
Try first launching the app from VS, in debug or release: no issue.
Then, publish the app. It will run the trimmer. Then run the published SldcTrimmer.exe: it fails.
4. Any further technical details
Here is a warning that is shown when publishing the app. Assembly 'System.Linq.Dynamic.Core' produced trim warnings. For more information see https://aka.ms/dotnet-illink/libraries.
But I have no idea how I can get more information and investigate more.
The text was updated successfully, but these errors were encountered:
1. Description
I'm using
DynamicExpressionParser.ParseLambda
in a dotnet console application.The expression I'm parsing is pretty simple, and it involves comparing an
integer
and abyte
.It's working just as expected, unless I'm using the dotnet trimmer in full mode, in which case it's raising a
ParseException
.I've already tried to root assembly
System.Linq.Dynamic.Core
for the trimmer, but it doesn't fix the issue.Could you please help me find a solution?
2. Exception
3. Fiddle or Project
Here is a repro: https://github.com/tranb3r/Issues/tree/main/SldcTrimmer
Try first launching the app from VS, in debug or release: no issue.
Then, publish the app. It will run the trimmer. Then run the published
SldcTrimmer.exe
: it fails.4. Any further technical details
Here is a warning that is shown when publishing the app.
Assembly 'System.Linq.Dynamic.Core' produced trim warnings. For more information see https://aka.ms/dotnet-illink/libraries
.But I have no idea how I can get more information and investigate more.
The text was updated successfully, but these errors were encountered: