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

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

Issue 1861563002: Avoid Object.hashCode on a few objects (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 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 | pkg/compiler/lib/src/dart_types.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) 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.dart'; 7 import 'common.dart';
8 import 'common/names.dart' show 8 import 'common/names.dart' show
9 Identifiers; 9 Identifiers;
10 import 'common/resolution.dart' show 10 import 'common/resolution.dart' show
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 throw new UnsupportedError("BoxFieldElement.resolvedAst"); 302 throw new UnsupportedError("BoxFieldElement.resolvedAst");
303 } 303 }
304 304
305 @override 305 @override
306 ConstantExpression get constant => null; 306 ConstantExpression get constant => null;
307 } 307 }
308 308
309 /// A local variable used encode the direct (uncaptured) references to [this]. 309 /// A local variable used encode the direct (uncaptured) references to [this].
310 class ThisLocal extends Local { 310 class ThisLocal extends Local {
311 final ExecutableElement executableContext; 311 final ExecutableElement executableContext;
312 final hashCode = ++ElementX.elementHashCode;
312 313
313 ThisLocal(this.executableContext); 314 ThisLocal(this.executableContext);
314 315
315 String get name => 'this'; 316 String get name => 'this';
316 317
317 ClassElement get enclosingClass => executableContext.enclosingClass; 318 ClassElement get enclosingClass => executableContext.enclosingClass;
318 } 319 }
319 320
320 /// Call method of a closure class. 321 /// Call method of a closure class.
321 class SynthesizedCallMethodElementX extends BaseFunctionElementX 322 class SynthesizedCallMethodElementX extends BaseFunctionElementX
(...skipping 835 matching lines...) Expand 10 before | Expand all | Expand 10 after
1157 /// 1158 ///
1158 /// Move the below classes to a JS model eventually. 1159 /// Move the below classes to a JS model eventually.
1159 /// 1160 ///
1160 abstract class JSEntity implements Entity { 1161 abstract class JSEntity implements Entity {
1161 Entity get declaredEntity; 1162 Entity get declaredEntity;
1162 } 1163 }
1163 1164
1164 abstract class PrivatelyNamedJSEntity implements JSEntity { 1165 abstract class PrivatelyNamedJSEntity implements JSEntity {
1165 Entity get rootOfScope; 1166 Entity get rootOfScope;
1166 } 1167 }
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/dart_types.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698