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

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

Issue 2003633002: Use FastUri instead of Uri in analyzer. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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 b0dc5d2f6ba56d8e75a1870d2b1606dccc3df532..4d53a8e696f17f3eae66170def3d9a20fae5d079 100644
--- a/pkg/analyzer/lib/src/context/source.dart
+++ b/pkg/analyzer/lib/src/context/source.dart
@@ -15,6 +15,7 @@ import 'package:analyzer/src/generated/java_engine.dart';
import 'package:analyzer/src/generated/sdk.dart';
import 'package:analyzer/src/generated/source.dart';
import 'package:analyzer/src/generated/utilities_dart.dart' as utils;
+import 'package:analyzer/src/util/fast_uri.dart';
import 'package:package_config/packages.dart';
/**
@@ -137,7 +138,7 @@ class SourceFactoryImpl implements SourceFactory {
@override
Source forUri(String absoluteUri) {
try {
- Uri uri = parseUriWithException(absoluteUri);
+ Uri uri = FastUri.parse(absoluteUri);
if (uri.isAbsolute) {
return _internalResolveUri(null, uri);
}
@@ -212,8 +213,7 @@ class SourceFactoryImpl implements SourceFactory {
}
try {
// Force the creation of an escaped URI to deal with spaces, etc.
- return _internalResolveUri(
- containingSource, parseUriWithException(containedUri));
+ return _internalResolveUri(containingSource, FastUri.parse(containedUri));
} on URISyntaxException {
return null;
} catch (exception, stackTrace) {
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/utilities_dart.dart » ('j') | pkg/analyzer/lib/src/util/fast_uri.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698