[Mono-osx] MSIL: Ldfld problems under Mac OS X / Mono, probably Mono bug

Rodrigo Kumpera kumpera at gmail.com
Thu Dec 15 14:41:42 EST 2011

Please file a bug report and attach a minimal working test case.

What it looks like is that JInt is abusing some MS'ism in IL. As passing
null to ldfld and expect it to not raise an exception.

On Thu, Dec 15, 2011 at 5:27 PM, lu4 <lu4 at online.ua> wrote:

> Hi I'm using 3rd party library JInt (the JavaScript interpriter) which was
> working fine until I've switched to Mac OS X, after that I keep on getting
> ArgumentNullExceptions, after some investigation I've found out that JInt
> uses dynamic code generation for making some sort of Js-Clr bridge. This
> method has the following instructions in the end:
> code.Emit(OpCodes.Ldnull);
> FieldInfo fieldInfo = typeof(JsUndefined).GetField("Instance");
> code.Emit(OpCodes.Ldfld, fieldInfo);
> Here's how these lines are executed It is clearly seen that fieldInfo
> argument is not null, though when it comes to executing these lines, notice
> that LDFLD has no argument! My current statement that will get executed
> is Ldnull, I performing "Step In"(Over Ldnull) and BANG exception occurs
> over Ldfld (Full size screenshot here <http://i.stack.imgur.com/rpTvd.png>):
> Any suggestions?
> ------------------------------
> View this message in context: MSIL: Ldfld problems under Mac OS X / Mono,
> probably Mono bug<http://mono.1490590.n4.nabble.com/MSIL-Ldfld-problems-under-Mac-OS-X-Mono-probably-Mono-bug-tp4201442p4201442.html>
> Sent from the Mono - OSX mailing list archive<http://mono.1490590.n4.nabble.com/Mono-OSX-f1546893.html>at Nabble.com.
> _______________________________________________
> Mono-osx mailing list
> Mono-osx at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-osx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-osx/attachments/20111215/ddf9e1db/attachment-0001.html 

More information about the Mono-osx mailing list