smartcaveman / runsharp-google-export

Automatically exported from code.google.com/p/runsharp
MIT License
0 stars 0 forks source link

In a dynamic method, one cannot create local variables inside a block #18

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
ILGenerator.BeginScope() throws an exception if called for a dynamic method.

Less-than-ideal quick fix: change CodeGen.Statements.cs as follows:

// line 618
try { g.il.BeginScope(); } catch(NotSupportedException) {}

// line 627
try { g.il.EndScope(); } catch(NotSupportedException) {}

By the way, where should I post questions? I can't cast ushort to char with 
Operand.Cast() -> "Operand of type 'TriAxis.RunSharp.Operands.Cast' cannot be 
written".

Original issue reported on code.google.com by qwertie...@gmail.com on 18 Aug 2010 at 8:31

GoogleCodeExporter commented 9 years ago
Oops, never mind about the Cast() thing. It does work, I was just using it 
wrong.

Original comment by qwertie...@gmail.com on 18 Aug 2010 at 9:22

GoogleCodeExporter commented 9 years ago
Oops, I just noticed this is a duplicate of issue 10.

Original comment by qwertie...@gmail.com on 20 Aug 2010 at 3:04

GoogleCodeExporter commented 9 years ago

Original comment by StefanSi...@gmail.com on 20 Aug 2010 at 8:55