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

Side by Side Diff: pkg/compiler/lib/src/closure.dart

Issue 2908153003: It's alive! (Closed)
Patch Set: Created 3 years, 6 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
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 closureToClassMapper; 5 library closureToClassMapper;
6 6
7 import 'common/names.dart' show Identifiers; 7 import 'common/names.dart' show Identifiers;
8 import 'common/resolution.dart' show ParsingContext, Resolution; 8 import 'common/resolution.dart' show ParsingContext, Resolution;
9 import 'common/tasks.dart' show CompilerTask; 9 import 'common/tasks.dart' show CompilerTask;
10 import 'common.dart'; 10 import 'common.dart';
(...skipping 1046 matching lines...) Expand 10 before | Expand all | Expand 10 after
1057 enclosingElement.kind == ElementKind.GENERATIVE_CONSTRUCTOR || 1057 enclosingElement.kind == ElementKind.GENERATIVE_CONSTRUCTOR ||
1058 enclosingElement.kind == ElementKind.CLASS || 1058 enclosingElement.kind == ElementKind.CLASS ||
1059 enclosingElement.kind == ElementKind.FUNCTION || 1059 enclosingElement.kind == ElementKind.FUNCTION ||
1060 enclosingElement.kind == ElementKind.GETTER || 1060 enclosingElement.kind == ElementKind.GETTER ||
1061 enclosingElement.kind == ElementKind.SETTER); 1061 enclosingElement.kind == ElementKind.SETTER);
1062 enclosingElement = enclosingElement.enclosingElement) { 1062 enclosingElement = enclosingElement.enclosingElement) {
1063 // TODO(johnniwinther): Simplify computed names. 1063 // TODO(johnniwinther): Simplify computed names.
1064 if (enclosingElement.isGenerativeConstructor || 1064 if (enclosingElement.isGenerativeConstructor ||
1065 enclosingElement.isGenerativeConstructorBody || 1065 enclosingElement.isGenerativeConstructorBody ||
1066 enclosingElement.isFactoryConstructor) { 1066 enclosingElement.isFactoryConstructor) {
1067 parts = parts 1067 ConstructorElement constructor = enclosingElement;
1068 .prepend(Elements.reconstructConstructorName(enclosingElement)); 1068 parts = parts.prepend(Elements.reconstructConstructorName(constructor));
1069 } else { 1069 } else {
1070 String surroundingName = 1070 String surroundingName =
1071 Elements.operatorNameToIdentifier(enclosingElement.name); 1071 Elements.operatorNameToIdentifier(enclosingElement.name);
1072 parts = parts.prepend(surroundingName); 1072 parts = parts.prepend(surroundingName);
1073 } 1073 }
1074 // A generative constructors's parent is the class; the class name is 1074 // A generative constructors's parent is the class; the class name is
1075 // already part of the generative constructor's name. 1075 // already part of the generative constructor's name.
1076 if (enclosingElement.kind == ElementKind.GENERATIVE_CONSTRUCTOR) break; 1076 if (enclosingElement.kind == ElementKind.GENERATIVE_CONSTRUCTOR) break;
1077 } 1077 }
1078 StringBuffer sb = new StringBuffer(); 1078 StringBuffer sb = new StringBuffer();
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
1235 /// 1235 ///
1236 /// Move the below classes to a JS model eventually. 1236 /// Move the below classes to a JS model eventually.
1237 /// 1237 ///
1238 abstract class JSEntity implements Entity { 1238 abstract class JSEntity implements Entity {
1239 Entity get declaredEntity; 1239 Entity get declaredEntity;
1240 } 1240 }
1241 1241
1242 abstract class PrivatelyNamedJSEntity implements JSEntity { 1242 abstract class PrivatelyNamedJSEntity implements JSEntity {
1243 Entity get rootOfScope; 1243 Entity get rootOfScope;
1244 } 1244 }
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/common_elements.dart » ('j') | pkg/compiler/lib/src/common_elements.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698