this is neutral w.r.t. diagnostics quality, but deletes a ton
of code:
include/swift/AST/DiagnosticsSema.def | 21 ++---------
lib/Sema/CSDiag.cpp | 64 ++--------------------------------
2 files changed, 9 insertions(+), 76 deletions(-)
Swift SVN r28956
if it has already resolved a member binding of an UnresolvedDotExpr. This allows
us to give tailored diagnostics to indicate whether the destination is not an lvalue
because the property itself was immutable or when the base is immutable.
In addition to improved diagnostics, this allows us to fixit hint "let" to "var" on
property definitions, and we can even go so far as to fixit hint insert 'mutating' on
the enclosing func decl when self is the problem.
This fixes the non-subscript cases of:
<rdar://problem/17632908> QoI: Modifying struct member in non-mutating function produces difficult to understand error message
<rdar://problem/19370429> QoI: fixit to add "mutating" when assigning to a member of self in a struct
<rdar://problem/20234955> QoI: Error message for assigning to 'let' fields should say that the error is due to a 'let' binding
Subscript cases to follow.
Swift SVN r28854