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

Side by Side Diff: pkg/analyzer/lib/src/generated/incremental_resolver.dart

Issue 794863003: Issue 21842. Fix incremental resolving of parameters of function typed parameters. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/incremental_resolver_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library engine.incremental_resolver; 5 library engine.incremental_resolver;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 import 'dart:math' as math; 8 import 'dart:math' as math;
9 9
10 import 'ast.dart'; 10 import 'ast.dart';
(...skipping 668 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 static void _setParameterElements(FormalParameterList nodes, 679 static void _setParameterElements(FormalParameterList nodes,
680 List<ParameterElement> elements) { 680 List<ParameterElement> elements) {
681 if (nodes != null) { 681 if (nodes != null) {
682 for (int i = 0; i < elements.length; i++) { 682 for (int i = 0; i < elements.length; i++) {
683 ParameterElement element = elements[i]; 683 ParameterElement element = elements[i];
684 FormalParameter node = nodes.parameters[i]; 684 FormalParameter node = nodes.parameters[i];
685 ParameterElement newElement = node.element; 685 ParameterElement newElement = node.element;
686 node.identifier.staticElement = element; 686 node.identifier.staticElement = element;
687 (element as ElementImpl).name = newElement.name; 687 (element as ElementImpl).name = newElement.name;
688 (element as ElementImpl).nameOffset = newElement.nameOffset; 688 (element as ElementImpl).nameOffset = newElement.nameOffset;
689 if (node is FunctionTypedFormalParameter) {
690 _setParameterElements(node.parameters, element.parameters);
691 }
689 } 692 }
690 } 693 }
691 } 694 }
692 } 695 }
693 696
694 697
695 /** 698 /**
696 * Describes how declarations match an existing elements model. 699 * Describes how declarations match an existing elements model.
697 */ 700 */
698 class DeclarationMatchKind { 701 class DeclarationMatchKind {
(...skipping 1028 matching lines...) Expand 10 before | Expand all | Expand 10 after
1727 String toString() => name; 1730 String toString() => name;
1728 } 1731 }
1729 1732
1730 1733
1731 class _TokenPair { 1734 class _TokenPair {
1732 final _TokenDifferenceKind kind; 1735 final _TokenDifferenceKind kind;
1733 final Token oldToken; 1736 final Token oldToken;
1734 final Token newToken; 1737 final Token newToken;
1735 _TokenPair(this.kind, this.oldToken, this.newToken); 1738 _TokenPair(this.kind, this.oldToken, this.newToken);
1736 } 1739 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/incremental_resolver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698