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
Developer Community or GitHub 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.
Created attachment 24837 [details]
I have some code I have changed based on code suggestions in Visual Studio 2017. Some of these were to use new language features of C# 7.
Now, I cannot build my iOS library project with getting compiler errors. All my other projects compile fine.
Error CS1644: Feature `declaration expression' cannot be used because it is not part of the C# 6.0 language specification (CS1644)
I tried changing the "C# Language Version" to "Version 7" or "Latest" but that causes another error.
Error CS1617: Invalid -langversion option Latest'. It must be ISO-1', `ISO-2', Default or value in range 1 to 6 (CS1617)
Could you provide some sample code or an entire project that reproduces these errors? Thanks!
@John Miller - I could not reproduce with a clean project so I decided to compare project files between the working and none working. In the non-working, I had the following lines at the bottom of the project:
This was to fix an issue found due to this bug:
I removed the lines and all works now.
Glad you found the issue (:
`mcs` only supports a subset of C#7 features which explains why it's fixed if you use csc (evolution).