Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No C# 6.0 in Visual Studio 2015 CTP?

Tags:

I have just created a new VM on Azure (using the image provided by the Azure team from the gallery) with CTP version of the upcoming Visual Studio 2014 that appeared yesterday online to test it and especially to play around with new C# 6.0 features.

However, it does not provide support for C# 6.0 out of the box, for none of the language extensions (primary constructors, property initializers, safe navigation operator) work there.

A blog entry on MSDN suggests adding the following to project settings:

 <LangVersion>Experimental</LangVersion> 

But this changes nothing in my console project. Even the sample code from the second link doesn't compile at all.

safe navigation operator is not recognized

Do I miss something?

like image 510
Alexander Galkin Avatar asked Jun 05 '14 17:06

Alexander Galkin


1 Answers

There is a bug in the CTP where the LangVersion switch is case sensitive. Try using experimental instead.

like image 100
Kevin Pilch Avatar answered Sep 19 '22 13:09

Kevin Pilch