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

Side by Side Diff: pkg/compiler/lib/src/resolution/class_hierarchy.dart

Issue 3007043002: Align synthetic mixin names with fasta. (Closed)
Patch Set: Created 3 years, 3 months 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
« no previous file with comments | « no previous file | no next file » | 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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 dart2js.resolution.class_hierarchy; 5 library dart2js.resolution.class_hierarchy;
6 6
7 import '../common.dart'; 7 import '../common.dart';
8 import '../common/resolution.dart' show Resolution; 8 import '../common/resolution.dart' show Resolution;
9 import '../common_elements.dart' show CommonElements; 9 import '../common_elements.dart' show CommonElements;
10 import '../elements/resolution_types.dart'; 10 import '../elements/resolution_types.dart';
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after
440 if (lastAndNamed) { 440 if (lastAndNamed) {
441 mixinElement = element; 441 mixinElement = element;
442 variables = freeTypes; 442 variables = freeTypes;
443 } else { 443 } else {
444 String signature = computeSignature(signatureIndex); 444 String signature = computeSignature(signatureIndex);
445 name = supertype.name; 445 name = supertype.name;
446 int index = name.indexOf("^"); 446 int index = name.indexOf("^");
447 if (index != -1) { 447 if (index != -1) {
448 name = name.substring(0, index); 448 name = name.substring(0, index);
449 } 449 }
450 name = "$name&${mixin.name}$signature"; 450 name = "_$name&${mixin.name}$signature";
451 mixinElement = mixinApplicationClasses[name]; 451 mixinElement = mixinApplicationClasses[name];
452 if (mixinElement != null) return mixinElement.thisType; 452 if (mixinElement != null) return mixinElement.thisType;
453 453
454 mixinElement = new UnnamedMixinApplicationElementX( 454 mixinElement = new UnnamedMixinApplicationElementX(
455 name, element, resolution.idGenerator.getNextFreeId(), node); 455 name, element, resolution.idGenerator.getNextFreeId(), node);
456 variables = computeTypeVariables(mixinElement, node); 456 variables = computeTypeVariables(mixinElement, node);
457 mixinElement.setThisAndRawTypes(variables.values.toList()); 457 mixinElement.setThisAndRawTypes(variables.values.toList());
458 mixinApplicationClasses[name] = mixinElement; 458 mixinApplicationClasses[name] = mixinElement;
459 } 459 }
460 460
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
858 Identifier selector = node.selector.asIdentifier(); 858 Identifier selector = node.selector.asIdentifier();
859 var e = prefixElement.lookupLocalMember(selector.source); 859 var e = prefixElement.lookupLocalMember(selector.source);
860 if (e == null || !e.impliesType) { 860 if (e == null || !e.impliesType) {
861 reporter.reportErrorMessage(node.selector, 861 reporter.reportErrorMessage(node.selector,
862 MessageKind.CANNOT_RESOLVE_TYPE, {'typeName': node.selector}); 862 MessageKind.CANNOT_RESOLVE_TYPE, {'typeName': node.selector});
863 return; 863 return;
864 } 864 }
865 loadSupertype(e, node); 865 loadSupertype(e, node);
866 } 866 }
867 } 867 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698