I’m hunting for a short example on IL generation programming that includes:
- a return value
- branching on a null test
- assigning to a temporary variable, or having a method with a function return as an argument to another method
It’d be great if there was a resource with examples + line by line explanation of what is occuring.
Does VS 2010 help with tracing at the il level?
I could post some incomplete examples
An easy way to learn about IL is to write the code in e.g. C# and look at the generated IL. That way you can easily see what various code constructs map to. For a great book on the subject, I recommend Expert .NET IL Assembler.