https://bugzilla.novell.com/show_bug.cgi?id=365188
Summary: gmcs generates invalid IL for creation of anonymous method Product: Mono: Compilers Version: SVN Platform: x86-64 OS/Version: Other Status: NEW Severity: Normal Priority: P5 - None Component: C# AssignedTo: mono-bugs@lists.ximian.com ReportedBy: [EMAIL PROTECTED] QAContact: mono-bugs@lists.ximian.com Found By: --- As reported by somebody on mono-devel a while ago: <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< public class Test { static public void TestFunc () { return; string testStr; System.AppDomain.CurrentDomain.AssemblyLoad += delegate (object Sender, System.AssemblyLoadEventArgs e) { testStr = "sss"; }; } public static void Main (string[] args) { TestFunc (); } } <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Running the compiled code will fail with: Unhandled Exception: System.InvalidProgramException: Invalid IL code in Test:TestFunc (): IL_0024: ldc.i4.4 at Test.Main (System.String[] args) [0x00000] This is because TestFunc () doesn't have a 'ret' at the end. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug. You are the assignee for the bug. _______________________________________________ mono-bugs maillist - mono-bugs@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-bugs