Chromium Code Reviews| Index: dart/pkg/compiler/samples/jsonify/jsonify.dart |
| diff --git a/dart/pkg/compiler/samples/jsonify/jsonify.dart b/dart/pkg/compiler/samples/jsonify/jsonify.dart |
| index bb0c41370193c99c131eed32e9902425572e28e7..9b70921b21fccbe85226d9e9895a3fd577d6881b 100644 |
| --- a/dart/pkg/compiler/samples/jsonify/jsonify.dart |
| +++ b/dart/pkg/compiler/samples/jsonify/jsonify.dart |
| @@ -46,7 +46,12 @@ main(List<String> arguments) { |
| Uri myLocation = |
| handler.provider.cwd.resolveUri(Platform.script); |
| - sdkRoot = myLocation.resolve(SDK_ROOT).resolve('../'); |
| + Uri packageRoot = |
| + handler.provider.cwd.resolve(Platform.packageRoot); |
|
Johnni Winther
2015/01/08 08:16:15
You need to ensure that the URI path ends with a /
ahe
2015/01/08 08:34:43
This isn't a super user friendly tool. For example
Johnni Winther
2015/01/08 09:40:42
The problem is really with Platform.packageRoot wh
|
| + |
| + Uri libraryRoot = myLocation.resolve(SDK_ROOT); |
| + |
| + sdkRoot = libraryRoot.resolve('../'); |
| // Get the names of public dart2js libraries. |
| Iterable<String> names = LIBRARIES.keys.where(isPublicDart2jsLibrary); |
| @@ -54,7 +59,7 @@ main(List<String> arguments) { |
| // Turn the names into uris by prepending dart: to them. |
| List<Uri> uris = names.map((String name) => Uri.parse('dart:$name')).toList(); |
| - analyze(uris, myLocation.resolve(SDK_ROOT), null, handler.provider, handler) |
| + analyze(uris, libraryRoot, packageRoot, handler.provider, handler) |
| .then(jsonify); |
| } |