Eik Rentzow
Eik Rentzow
@eyalsk But not everybody has those generators by hand, especially when reading foreign code. I would also disagree to allow name collision, with the exception of modifying a local 'new'....
In the current C# 7 preview in **Local Functions** (see [here](https://blogs.msdn.microsoft.com/dotnet/2016/08/24/whats-new-in-csharp-7-0/)) when you re-declare a local variable you will get the following error: > A local or parameter named 'localVariable'...
If there is only one field needed for the primary use as backing field, I suggest an additional syntax, borrowed from C `struct`: ```C# public string FirstName { get =>...
Type infering with `var` for the property-scoped fields should be available as well. ```C# property BarClass Foo { var _field; // automatically initialized with `default(BarClass)` get { } set {...
It seems to turn out that the scoping is harder to achieve than it looks, especially when it comes to inheritance. **Update (27 Mar 2017):** revoked; see https://github.com/dotnet/csharplang/issues/133#issuecomment-297770415 As there...
@bondsbw The proposed construct would allow to support every aspect of property scoped fields, even offer more possibilities, while simultaneously keeping the API compatible. Advantages of this versus "simple" property...
@bondsbw > Why not just use a nested type? Actually that is where this idea initiated. But the overhead is quite a bit and does not prevent to have the...
I think that `: class` is a bit overshooting. When you are that far that you really need fancy class features like polymorphy, etc. you should think about a vast...
## Poll I only need this feature for a few property-scoped fields. 'private' scope to the property is sufficient for my purposes. In case of inheritance, e.g. 'protected' fields, I...
@stepanbenes What shall 🎉 mean? 😃 @bondsbw Would delegating to a (nested) class/struct help to satisfy your needs? If so, what do you think of a "delegating syntax" ```cs public...