You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NullableWalker.Scan().getFieldSymbolToBeInitialized(): Is checking IsAutoProperty sufficient or should we check the appropriate accessors are missing or auto-implemented
#75245
Open
RikkiGibson opened this issue
Sep 25, 2024
· 0 comments
· May be fixed by #75872
static Symbol getFieldSymbolToBeInitialized(SymbolrequiredMember)
=> requiredMember is SourcePropertySymbol { IsAutoProperty:true} prop ? prop.BackingField :requiredMember;
It feels like this is another piece of our attempts to correctly substitute the field for the property and vice-versa when initializing/reading/managing flow state, and this check/branch can probably be consolidated into another area. But it doesn't appear to be urgent or impacting correctness.
The text was updated successfully, but these errors were encountered:
Originally posted by @RikkiGibson in #75116 (comment)
Code being referenced:
roslyn/src/Compilers/CSharp/Portable/FlowAnalysis/NullableWalker.cs
Lines 1076 to 1077 in bdebb57
It feels like this is another piece of our attempts to correctly substitute the field for the property and vice-versa when initializing/reading/managing flow state, and this check/branch can probably be consolidated into another area. But it doesn't appear to be urgent or impacting correctness.
The text was updated successfully, but these errors were encountered: