[Mono-bugs] [Bug 421736] New: [Regression] Compiler fails on some block containing yield keyword

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Sat Aug 30 12:34:36 EDT 2008


           Summary: [Regression] Compiler fails on some block containing
                    yield keyword
           Product: Mono: Compilers
           Version: SVN
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: C#
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: jeremie.laval at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---

The attached snippet fails to compile with gmcs SVN and outputs the following
stacktrace : 

[csc] Exception caught by the compiler while emitting:
[csc]    Block that caused the problem begin at:
[csc] System.Exception: Trying to emit a local from a different ILGenerator.
[csc] Internal compiler error at
exception caught while emitting MethodBuilder
[csc] Unhandled Exception: System.Exception: Trying to emit a local from a
different ILGenerator.
[csc]   at System.Reflection.Emit.ILGenerator.Emit (OpCode opcode,
System.Reflection.Emit.LocalBuilder local) [0x00000]
[csc]   at Mono.CSharp.LocalInfo.Emit (Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.VariableReference.EmitLoad (Mono.CSharp.EmitContext ec)
[csc]   at Mono.CSharp.VariableReference.Emit (Mono.CSharp.EmitContext ec,
Boolean leave_copy) [0x00000]
[csc]   at Mono.CSharp.TemporaryVariable.Emit (Mono.CSharp.EmitContext ec)
[csc]   at Mono.CSharp.Foreach+CollectionForeach.EmitFinallyBody
(Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at
(Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.ExceptionStatement.EmitForDispose
(Mono.CSharp.EmitContext ec, Mono.CSharp.Iterator iterator, Label end, Boolean
have_dispatcher) [0x00000]
[csc]   at Mono.CSharp.Iterator.EmitDispose (Mono.CSharp.EmitContext ec)
[csc]   at
(Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.Statement.Emit (Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.Block.DoEmit (Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.Block.Emit (Mono.CSharp.EmitContext ec) [0x00000]
[csc]   at Mono.CSharp.ExplicitBlock.Emit (Mono.CSharp.EmitContext ec)
[csc]   at Mono.CSharp.ToplevelBlock.Emit (Mono.CSharp.EmitContext ec)
[csc]   at Mono.CSharp.EmitContext.EmitResolvedTopBlock
(Mono.CSharp.ToplevelBlock block, Boolean unreachable) [0x00000]
[csc]   at Mono.CSharp.EmitContext.EmitTopBlock (IMethodData md,
Mono.CSharp.ToplevelBlock block) [0x00000]

The snippet was reported to compile correctly on a stock 1.9.1 gmcs .

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.

More information about the mono-bugs mailing list