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.
Found: Previously accepted code now results in what look like false positive errors.
Steps to reproduce:
* Load the attached project under the first C# 6.0-bearing alpha release.
* Build the project.
Program.cs(24,34): error CS8080: `CS6.AutoProperties.MainClass.Baz.Condition': Auto-implemented properties must override all accessors of the overridden property
Expected: No error.
The simple case of an auto-implemented get-only property works fine (as noted).
In the abstract/overridden case, the override implements exactly the same set of accessors as prescribed by the abstract class. The same construct worked fine up until this release. So this is either a case of shouldn't-have-worked-before (past bug) or should-work-now (new bug).
Any insight appreciated.
Created attachment 10635 [details]
Note that an initial workaround is to declare a public setter for the hierarchy, but this of course changes the contract from what was intended.
Note that MSVS 2015 CTP appears to accept this case just fine --- maybe just a case of some upstream Roslyn fixes that haven't yet been merged?
Fixed in master
Has this fix been incorporated into any of the Mono releases? I am still having this issue running the MDK installed with the Alpha channel on OS X (184.108.40.206).
The fix will be included in Mono 4.2
Is there a chance of merging this to 4.0? This effectively breaks a C# 6 language feature that is supposedly supported in 4.0 for any readonly overridable properties.