Code generation error will cause a crash when checking result of nullable in if statement.
Code.zip
The attached project will reproduce the crash if you try to compile it.