Some form of compile time branch elimination
Opened this issue · 0 comments
dadhi commented
Sometimes when composing the final expression, the parts are the Lambdas and Invocations (e.g. AutoMapper does this a lot).
The more generic lambda may take the null constant or default expression as invocation of a special kind.
After inlining the Invocation contains the conditions Test like Constant(null) == Default(typeof(X))
or similar.
Knowing that we may eliminate the false branch during Collect and Emit phase, and substitute the whole condition with the true branch body.