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

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

Issue 2994383003: Avoid crash for type variables in mixed in fields. (Closed)
Patch Set: Created 3 years, 4 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 import 'common/names.dart' show Identifiers; 5 import 'common/names.dart' show Identifiers;
6 import 'common/resolution.dart' show ParsingContext, Resolution; 6 import 'common/resolution.dart' show ParsingContext, Resolution;
7 import 'common/tasks.dart' show CompilerTask, Measurer; 7 import 'common/tasks.dart' show CompilerTask, Measurer;
8 import 'common.dart'; 8 import 'common.dart';
9 import 'compiler.dart' show Compiler; 9 import 'compiler.dart' show Compiler;
10 import 'constants/expressions.dart'; 10 import 'constants/expressions.dart';
(...skipping 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after
1525 int get hashCode => typeVariable.hashCode; 1525 int get hashCode => typeVariable.hashCode;
1526 1526
1527 bool operator ==(other) { 1527 bool operator ==(other) {
1528 if (other is! TypeVariableLocal) return false; 1528 if (other is! TypeVariableLocal) return false;
1529 return typeVariable == other.typeVariable; 1529 return typeVariable == other.typeVariable;
1530 } 1530 }
1531 1531
1532 String toString() { 1532 String toString() {
1533 StringBuffer sb = new StringBuffer(); 1533 StringBuffer sb = new StringBuffer();
1534 sb.write('type_variable_local('); 1534 sb.write('type_variable_local(');
1535 if (memberContext.enclosingClass != null) { 1535 sb.write(typeVariable);
1536 sb.write(memberContext.enclosingClass.name);
1537 sb.write('.');
1538 }
1539 sb.write(memberContext.name);
1540 sb.write('#');
1541 sb.write(name);
1542 sb.write(')'); 1536 sb.write(')');
1543 return sb.toString(); 1537 return sb.toString();
1544 } 1538 }
1545 } 1539 }
1546 1540
1547 /// 1541 ///
1548 /// Move the below classes to a JS model eventually. 1542 /// Move the below classes to a JS model eventually.
1549 /// 1543 ///
1550 abstract class JSEntity implements MemberEntity { 1544 abstract class JSEntity implements MemberEntity {
1551 Local get declaredEntity; 1545 Local get declaredEntity;
1552 } 1546 }
1553 1547
1554 abstract class PrivatelyNamedJSEntity implements JSEntity { 1548 abstract class PrivatelyNamedJSEntity implements JSEntity {
1555 Entity get rootOfScope; 1549 Entity get rootOfScope;
1556 } 1550 }
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/ssa/builder.dart » ('j') | pkg/compiler/lib/src/ssa/builder.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698