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.
When disposing a Menu its' menu items should also be disposed.
Currently they are not getting disposed when disposing the Menu but will eventually get garbage collected.
Created attachment 1365 [details]
I committed this patch without the "menu_items = null;" line. Although this instruction may help the GC, it makes us differ from .NET. It makes it so trying to access a menu item after having disposed the menu throws a NullReferenceException, while .NET throws an ArgumentOutOfRangeException.
Patch: commit 6c3c219ad3ad435ec010d9b2c365a8d678d9c336
Unit test: commit 23bf99cf299cec7e42124cc75ebd261265f3540d