As the next version of C# gets closer, features that are not quite ready have to be cut. The features. Newly removed from the list are primary constructors and declaration expressions. Mads Torgersen writes,
As you’ve maybe heard me say before, language features are a secondary consideration in this release. The primary goal is to deliver a magnificent first release of the Roslyn value proposition: deep language understanding in the IDE and available to everyone through a robust and comprehensive API. To deliver this well, we need to scale back our appetite for language features a bit.
It’s not all bad news. A feature not previously discussed by Microsoft, string interpolation, is expected to make it in. String interpolation allows one to inline variables in strings without the need to explicitly call String.Format. String interpolation was added to the Mono compiler back in 2009 as an experimental feature.
Features that are expected to be included in the next version include:
- Auto-property initializers (Already available in VB)
- Getter-only auto-properties
- Ctor assignment to getter-only autoprops
- Parameterless struct ctors
- Using static members (Already available in VB)
- Dictionary initializer (C# only)
- Await in catch/finally (C# done. VB maybe)
- Exception filters (Already available in VB)
- Typecase (VB maybe)
- Partial modules (VB only, not applicable to C#)
- Partial interfaces (Already available in C#)
- Multiline string literals (Already available in C#)
- Year-first date literals (VB only)
- Line continuation comments (VB only, not applicable to C#)
- TypeOf IsNot (VB only, not applicable to C#)
- Expression-bodied members (C# only)
- Null propagation (C# done, VB maybe)
- Params IEnumerable (maybe)
- String interpolation (planned)
- nameof operator (C# done, VB planned)
- #pragma (Already available in C#)
- Field targets on autoprops (maybe)
You can see the list of features that didn’t make the cut on the language features status page.
Note: A previous report in InfoQ erroneously stated that pattern matching would be part of C# 6 and VB 12.