Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(170)

Issue 2771123002: Arglist `children:` default value gen fixes. (Closed)

Created:
3 years, 9 months ago by pquitslund
Modified:
3 years, 9 months ago
CC:
reviews_dartlang.org
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Arglist `children:` default value gen fixes. * fixed arglist codegen (include params) * fixed defaultTextRange generation (and added tests) * cleanup (followup from https://codereview.chromium.org/2768273003/ R=brianwilkerson@google.com, danrubel@google.com See: https://github.com/flutter/flutter-intellij/issues/832 Committed: https://github.com/dart-lang/sdk/commit/4a9cabf493600a6b0a002c8a5edf1a9b91253919

Patch Set 1 #

Total comments: 7

Patch Set 2 : Remove unneeded assignment. #

Messages

Total messages: 9 (2 generated)
pquitslund
3 years, 9 months ago (2017-03-23 23:10:57 UTC) #2
Brian Wilkerson
lgtm https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart File pkg/analysis_server/lib/src/services/completion/dart/utilities.dart (right): https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart#newcode86 pkg/analysis_server/lib/src/services/completion/dart/utilities.dart:86: sb.write(defaultValue); 'defaultValue' can be null here. https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart#newcode181 pkg/analysis_server/lib/src/services/completion/dart/utilities.dart:181: ...
3 years, 9 months ago (2017-03-23 23:34:48 UTC) #3
danrubel
LGTM https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart File pkg/analysis_server/lib/src/services/completion/dart/utilities.dart (right): https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart#newcode76 pkg/analysis_server/lib/src/services/completion/dart/utilities.dart:76: ClassElement classElement = element.enclosingElement; It appears that "element" ...
3 years, 9 months ago (2017-03-24 13:16:19 UTC) #4
pquitslund
Thanks! I've got another change on the way that will improve testing. More soon. https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart ...
3 years, 9 months ago (2017-03-24 15:56:23 UTC) #5
Brian Wilkerson
https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart File pkg/analysis_server/lib/src/services/completion/dart/utilities.dart (right): https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src/services/completion/dart/utilities.dart#newcode86 pkg/analysis_server/lib/src/services/completion/dart/utilities.dart:86: sb.write(defaultValue); Given a widget class with a constructor of ...
3 years, 9 months ago (2017-03-24 16:04:32 UTC) #6
pquitslund
Committed patchset #2 (id:20001) manually as 4a9cabf493600a6b0a002c8a5edf1a9b91253919 (presubmit successful).
3 years, 9 months ago (2017-03-24 16:36:31 UTC) #8
pquitslund
3 years, 9 months ago (2017-03-24 16:37:45 UTC) #9
Message was sent while issue was closed.
On 2017/03/24 16:04:32, Brian Wilkerson wrote:
>
https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src...
> File pkg/analysis_server/lib/src/services/completion/dart/utilities.dart
> (right):
> 
>
https://codereview.chromium.org/2771123002/diff/1/pkg/analysis_server/lib/src...
> pkg/analysis_server/lib/src/services/completion/dart/utilities.dart:86:
> sb.write(defaultValue);
> Given a widget class with a constructor of the form:
> 
>   Widget2({Map<String, Widget> children});
> 
> If the user requests code completion here:
> 
>   Widget2(^)
> 
> the suggestion will be "children: null". If we can't do better than this, do
we
> really want this, or should we call back to the behavior used everywhere else
of
> just suggesting "children: "? (I'd vote for the latter, but you might want a
> second opinion :-)

I'll pick this up in my other CL that gets this better under test.  I lean
towards the latter too FWIW!

Powered by Google App Engine
This is Rietveld 408576698