Chromium Code Reviews| Index: pkg/analyzer/lib/src/generated/source_io.dart |
| diff --git a/pkg/analyzer/lib/src/generated/source_io.dart b/pkg/analyzer/lib/src/generated/source_io.dart |
| index 9c40d7461b4666ffb553a8b69545968bc2b0ee28..1dae5a04cbac737995df6f84751df4b5f5bf9918 100644 |
| --- a/pkg/analyzer/lib/src/generated/source_io.dart |
| +++ b/pkg/analyzer/lib/src/generated/source_io.dart |
| @@ -276,11 +276,11 @@ class FileUriResolver extends UriResolver { |
| static String FILE_SCHEME = "file"; |
| @override |
| - Source resolveAbsolute(Uri uri) { |
| + Source resolveAbsolute(Uri uri, [Uri actualUri]) { |
| if (!isFileUri(uri)) { |
| return null; |
| } |
| - return new FileBasedSource(new JavaFile.fromUri(uri), uri); |
| + return new FileBasedSource(new JavaFile.fromUri(uri), actualUri); |
|
Paul Berry
2015/07/21 19:39:27
There's a subtle change in behavior in the case wh
pquitslund
2015/07/21 20:55:10
Good catch!
|
| } |
| @override |
| @@ -425,7 +425,7 @@ class PackageUriResolver extends UriResolver { |
| } |
| @override |
| - Source resolveAbsolute(Uri uri) { |
| + Source resolveAbsolute(Uri uri, [Uri actualUri]){ |
| if (!isPackageUri(uri)) { |
| return null; |
| } |
| @@ -463,7 +463,7 @@ class PackageUriResolver extends UriResolver { |
| } |
| } |
| return new FileBasedSource( |
| - getCanonicalFile(_packagesDirectories[0], pkgName, relPath), uri); |
| + getCanonicalFile(_packagesDirectories[0], pkgName, relPath), actualUri); |
|
Paul Berry
2015/07/21 19:39:27
This has the same problem as above, but it's defin
pquitslund
2015/07/21 20:55:10
Absolutely. Spot on. Thanks!
|
| } |
| @override |
| @@ -537,7 +537,7 @@ class RelativeFileUriResolver extends UriResolver { |
| : super(); |
| @override |
| - Source resolveAbsolute(Uri uri) { |
| + Source resolveAbsolute(Uri uri, [Uri actualUri]) { |
| String rootPath = _rootDirectory.toURI().path; |
| String uriPath = uri.path; |
| if (uriPath != null && uriPath.startsWith(rootPath)) { |
| @@ -545,7 +545,7 @@ class RelativeFileUriResolver extends UriResolver { |
| for (JavaFile dir in _relativeDirectories) { |
| JavaFile file = new JavaFile.relative(dir, filePath); |
| if (file.exists()) { |
| - return new FileBasedSource(file, uri); |
| + return new FileBasedSource(file, actualUri); |
|
Paul Berry
2015/07/21 19:39:27
Similar problem here, although I can't assess the
pquitslund
2015/07/21 20:55:10
Done.
|
| } |
| } |
| } |