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

Unified Diff: pkg/compiler/lib/src/universe/resolution_world_builder.dart

Issue 2982783003: Use failedAt in more places (Closed)
Patch Set: Created 3 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/types/constants.dart ('k') | pkg/compiler/lib/src/universe/selector.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/universe/resolution_world_builder.dart
diff --git a/pkg/compiler/lib/src/universe/resolution_world_builder.dart b/pkg/compiler/lib/src/universe/resolution_world_builder.dart
index 44c865aefc763bc310a6090c3a81690a5046a4b7..780f2f699941fa881412ee5e5e19e7dc3739bd33 100644
--- a/pkg/compiler/lib/src/universe/resolution_world_builder.dart
+++ b/pkg/compiler/lib/src/universe/resolution_world_builder.dart
@@ -393,7 +393,7 @@ abstract class ResolutionWorldBuilderBase
ClosedWorld get closedWorldForTesting {
if (!_closed) {
- throw new SpannableAssertionFailure(
+ failedAt(
NO_LOCATION_SPANNABLE, "The world builder has not yet been closed.");
}
return _closedWorldCache;
@@ -648,7 +648,7 @@ abstract class ResolutionWorldBuilderBase
failedAt(element, 'Direct static use is not supported for resolution.');
break;
case StaticUseKind.INLINING:
- throw new SpannableAssertionFailure(CURRENT_ELEMENT_SPANNABLE,
+ failedAt(CURRENT_ELEMENT_SPANNABLE,
"Static use ${staticUse.kind} is not supported during resolution.");
}
if (useSet.isNotEmpty) {
@@ -902,8 +902,7 @@ abstract class ResolutionWorldBuilderBase
}
assert(checkClass(cls));
if (!validateClass(cls)) {
- throw new SpannableAssertionFailure(
- cls, 'Class "${cls.name}" is not resolved.');
+ failedAt(cls, 'Class "${cls.name}" is not resolved.');
}
_updateClassHierarchyNodeForClass(cls,
« no previous file with comments | « pkg/compiler/lib/src/types/constants.dart ('k') | pkg/compiler/lib/src/universe/selector.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698