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

Side by Side Diff: pkg/compiler/lib/src/kernel/element_map.dart

Issue 2917653002: Use failedAt in more places (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
« no previous file with comments | « pkg/compiler/lib/src/elements/elements.dart ('k') | pkg/compiler/lib/src/kernel/kernel.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) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 'package:kernel/ast.dart' as ir; 5 import 'package:kernel/ast.dart' as ir;
6 6
7 import '../common.dart'; 7 import '../common.dart';
8 import '../common/names.dart'; 8 import '../common/names.dart';
9 import '../constants/constructors.dart'; 9 import '../constants/constructors.dart';
10 import '../constants/expressions.dart'; 10 import '../constants/expressions.dart';
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after
498 return function; 498 return function;
499 } 499 }
500 } 500 }
501 // If [member] is not a valid `noSuchMethod` the target is 501 // If [member] is not a valid `noSuchMethod` the target is
502 // `Object.superNoSuchMethod`. 502 // `Object.superNoSuchMethod`.
503 break; 503 break;
504 } 504 }
505 } 505 }
506 FunctionEntity function = elementEnvironment.lookupClassMember( 506 FunctionEntity function = elementEnvironment.lookupClassMember(
507 commonElements.objectClass, Identifiers.noSuchMethod_); 507 commonElements.objectClass, Identifiers.noSuchMethod_);
508 assert(invariant(cls, function != null, 508 assert(function != null,
509 message: "No super noSuchMethod found for class $cls.")); 509 failedAt(cls, "No super noSuchMethod found for class $cls."));
510 return function; 510 return function;
511 } 511 }
512 } 512 }
513 513
514 /// Visitor that converts string literals and concatenations of string literals 514 /// Visitor that converts string literals and concatenations of string literals
515 /// into the string value. 515 /// into the string value.
516 class Stringifier extends ir.ExpressionVisitor<String> { 516 class Stringifier extends ir.ExpressionVisitor<String> {
517 @override 517 @override
518 String visitStringLiteral(ir.StringLiteral node) => node.value; 518 String visitStringLiteral(ir.StringLiteral node) => node.value;
519 519
(...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after
927 TypeMask getInferredTypeOf(MemberEntity member); 927 TypeMask getInferredTypeOf(MemberEntity member);
928 928
929 /// Returns the inferred type of a dynamic [selector] access on a receiver of 929 /// Returns the inferred type of a dynamic [selector] access on a receiver of
930 /// type [mask]. 930 /// type [mask].
931 TypeMask selectorTypeOf(Selector selector, TypeMask mask); 931 TypeMask selectorTypeOf(Selector selector, TypeMask mask);
932 932
933 /// Returns the returned type annotation in the [nativeBehavior]. 933 /// Returns the returned type annotation in the [nativeBehavior].
934 TypeMask typeFromNativeBehavior( 934 TypeMask typeFromNativeBehavior(
935 native.NativeBehavior nativeBehavior, ClosedWorld closedWorld); 935 native.NativeBehavior nativeBehavior, ClosedWorld closedWorld);
936 } 936 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/elements/elements.dart ('k') | pkg/compiler/lib/src/kernel/kernel.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698