Chromium Code Reviews
DescriptionUse the function name as the location for a missing return error.
Previously, it was using the entire function node, including it's body,
which makes for a gratuitously large amount of red squiggles. :)
This uses the function's name instead. As a side effect, the error now
appears a little later for a getter:
get foo => ...
^^^
Where before it was:
get foo => ...
^^^^^^^^^^^^^^
I tried putting the span on "get" instead in this case because that's
closer to where the return type should go, but I think the name looks a
little better because that's the name mentioned in the error message
too.
R=jmesserly@google.com
Committed: https://github.com/dart-lang/sdk/commit/da16354b1bf7cf86d9ab3aae9fa0e98633b327fe
Patch Set 1 #
Messages
Total messages: 5 (2 generated)
|
||||||||||||||||||||||||||||