From 5db9f627e3b105ffc1ed43bb81732886308ddfdf Mon Sep 17 00:00:00 2001 From: Bert Belder Date: Tue, 29 Jun 2021 20:39:28 +0200 Subject: chore: get rid of REPL timeout (#11175) * Get rid of timeout * Use tokio channel and reduce calls to run_event_loop Co-authored-by: David Sherret --- runtime/worker.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'runtime') diff --git a/runtime/worker.rs b/runtime/worker.rs index 567e75253..091b97119 100644 --- a/runtime/worker.rs +++ b/runtime/worker.rs @@ -7,7 +7,6 @@ use crate::ops; use crate::permissions::Permissions; use deno_broadcast_channel::InMemoryBroadcastChannel; use deno_core::error::AnyError; -use deno_core::futures::future::poll_fn; use deno_core::futures::stream::StreamExt; use deno_core::futures::Future; use deno_core::located_script_name; @@ -247,7 +246,7 @@ impl MainWorker { &mut self, wait_for_inspector: bool, ) -> Result<(), AnyError> { - poll_fn(|cx| self.poll_event_loop(cx, wait_for_inspector)).await + self.js_runtime.run_event_loop(wait_for_inspector).await } /// A utility function that runs provided future concurrently with the event loop. -- cgit v1.2.3