diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2019-01-30 17:21:31 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-30 17:21:31 -0500 |
commit | 00597ffde1ebb05a6c60ea7e09e6578c11f92820 (patch) | |
tree | 849b6b22c07ed38a4b424c363c06435ea2de4fa9 /src/main.rs | |
parent | 7d278a0383ce634f4fa3dd792e9b202582a6fde1 (diff) |
Refactor libdeno ES module interface. (#1624)
Allows for future asynchronous module loading.
Add support for import.meta.url
Fixes #1496
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main.rs b/src/main.rs index 89c9563e1..1b93ea86d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -84,7 +84,7 @@ fn main() { let state = Arc::new(isolate::IsolateState::new(flags, rest_argv, None)); let snapshot = snapshot::deno_snapshot(); - let isolate = isolate::Isolate::new(snapshot, state, ops::dispatch); + let mut isolate = isolate::Isolate::new(snapshot, state, ops::dispatch); tokio_util::init(|| { // Setup runtime. @@ -94,9 +94,9 @@ fn main() { // Execute input file. if isolate.state.argv.len() > 1 { - let input_filename = &isolate.state.argv[1]; + let input_filename = isolate.state.argv[1].clone(); isolate - .execute_mod(input_filename, should_prefetch) + .execute_mod(&input_filename, should_prefetch) .unwrap_or_else(print_err_and_exit); } |