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

Unified Diff: utils/compiler/create_snapshot.dart

Issue 15832003: Change File.directory to not do any IO (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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
« no previous file with comments | « tests/standalone/io/file_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/compiler/create_snapshot.dart
diff --git a/utils/compiler/create_snapshot.dart b/utils/compiler/create_snapshot.dart
index f1bc9dbf30d1260aaea99a3141547e52cb5097c4..c5a8af45e9ca0f3a2965c75ec0b2c654dc2ea824 100644
--- a/utils/compiler/create_snapshot.dart
+++ b/utils/compiler/create_snapshot.dart
@@ -82,10 +82,9 @@ void main() {
if (!args.containsKey("dart2js_main")) throw "Please specify dart2js_main";
if (!args.containsKey("output_dir")) throw "Please specify output_dir";
- var scriptFile = new File(options.script);
- var path = new Path(scriptFile.directorySync().path);
+ var scriptFile = new File(new File(options.script).fullPathSync());
+ var path = new Path(scriptFile.directory.path);
var rootPath = path.directoryPath.directoryPath;
-
getSnapshotGenerationFile(options, args, rootPath).then((result) {
var wrapper = "${args['output_dir']}/utils_wrapper.dart";
writeSnapshotFile(wrapper, result);
« no previous file with comments | « tests/standalone/io/file_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698