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

Unified Diff: pkg/analyzer/lib/src/context/source.dart

Issue 2326813002: Replace and remove JavaException(s). (Closed)
Patch Set: Created 4 years, 3 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
Index: pkg/analyzer/lib/src/context/source.dart
diff --git a/pkg/analyzer/lib/src/context/source.dart b/pkg/analyzer/lib/src/context/source.dart
index 0c9a84fd7e46a4f12cf0aa1d6b3023851818c4ce..d6f5c15ca14e8699e054a9232b646ad4badc9dcf 100644
--- a/pkg/analyzer/lib/src/context/source.dart
+++ b/pkg/analyzer/lib/src/context/source.dart
@@ -143,8 +143,7 @@ class SourceFactoryImpl implements SourceFactory {
Source fromEncoding(String encoding) {
Source source = forUri(encoding);
if (source == null) {
- throw new IllegalArgumentException(
- "Invalid source encoding: '$encoding'");
+ throw new ArgumentError("Invalid source encoding: '$encoding'");
}
return source;
}

Powered by Google App Engine
This is Rietveld 408576698