Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
GitHub or Developer Community with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
public static void Main (string args)
IDisposable disposable = new System.IO.MemoryStream ();
1) Put a breakpoint on the Console.WriteLine
2) Try to invoke 'disposable.Dispose ()' in the immediate window
A "System.InvalidProgramException: Missing or incorrect header for method" exception is thrown.
This appears to happen when you try to invoke methods declared on any interface when you have a local variable whose compile time type is that interface, as above.
I consulted with Jeff already and thinks this is a runtime issue. The same issue may exist for properties.
This particular bug has been reported several times on Bugzilla ( https://bugzilla.xamarin.com/show_bug.cgi?id=4390 and https://bugzilla.xamarin.com/show_bug.cgi?id=6986 at least) and I've reported it in IRC a few times and had it fixed several times in the past. It'd be great if we could add regression tests for this as breaking the same feature in the same way multiple times should not happen.
Fixed in mono master 31db4c7cb4e41f4e66c6b6bb821005d4666b1a8c.