diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2020-10-07 22:30:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-07 22:30:06 +0200 |
commit | d8879feb8c832dbb38649551b1cb0730874f7be6 (patch) | |
tree | ece7adc6d3611c87f6c2f13732b29ac4314a80ef /cli | |
parent | 8bd7c936f9a9a63334e5f512d6b6c1f8b47a42b8 (diff) |
refactor(core): JsRuntime is not a Future (#7855)
This commit rewrites deno_core::JsRuntime to not implement Future
trait.
Instead there are two separate methods:
- JsRuntime::poll_event_loop() - does single tick of event loop
- JsRuntime::run_event_loop() - runs event loop to completion
Diffstat (limited to 'cli')
-rw-r--r-- | cli/worker.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cli/worker.rs b/cli/worker.rs index 488a2eeba..ea9362a6b 100644 --- a/cli/worker.rs +++ b/cli/worker.rs @@ -240,7 +240,7 @@ impl Future for Worker { // We always poll the inspector if it exists. let _ = inner.inspector.as_mut().map(|i| i.poll_unpin(cx)); inner.waker.register(cx.waker()); - inner.js_runtime.poll_unpin(cx) + inner.js_runtime.poll_event_loop(cx) } } |