File tree Expand file tree Collapse file tree 7 files changed +18
-24
lines changed Expand file tree Collapse file tree 7 files changed +18
-24
lines changed Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ repository = "https://github.com/denoland/deno"
62
62
63
63
[workspace .dependencies ]
64
64
deno_ast = { version = " =0.50.0" , features = [" transpiling" ] }
65
- deno_core = { version = " 0.359 .0" }
65
+ deno_core = { version = " 0.360 .0" }
66
66
67
67
deno_cache_dir = " =0.25.0"
68
68
deno_doc = " =0.183.0"
Original file line number Diff line number Diff line change @@ -61,11 +61,9 @@ pub fn op_inspector_url() -> Option<String> {
61
61
62
62
#[ op2( fast) ]
63
63
pub fn op_inspector_wait ( state : & OpState ) -> bool {
64
- match state. try_borrow :: < Rc < RefCell < JsRuntimeInspector > > > ( ) {
64
+ match state. try_borrow :: < Rc < JsRuntimeInspector > > ( ) {
65
65
Some ( inspector) => {
66
- inspector
67
- . borrow_mut ( )
68
- . wait_for_session_and_break_on_next_statement ( ) ;
66
+ inspector. wait_for_session_and_break_on_next_statement ( ) ;
69
67
true
70
68
}
71
69
None => false ,
@@ -131,7 +129,7 @@ where
131
129
let context = v8:: Global :: new ( scope, context) ;
132
130
let callback = v8:: Global :: new ( scope, callback) ;
133
131
134
- let inspector = state. borrow :: < Rc < RefCell < JsRuntimeInspector > > > ( ) . clone ( ) ;
132
+ let inspector = state. borrow :: < Rc < JsRuntimeInspector > > ( ) . clone ( ) ;
135
133
136
134
// The inspector connection does not keep the event loop alive but
137
135
// when the inspector sends a message to the frontend, the JS that
Original file line number Diff line number Diff line change @@ -696,11 +696,7 @@ pub fn op_require_package_imports_resolve<
696
696
697
697
#[ op2( fast, reentrant) ]
698
698
pub fn op_require_break_on_next_statement ( state : Rc < RefCell < OpState > > ) {
699
- let inspector_rc = {
700
- let state = state. borrow ( ) ;
701
- state. borrow :: < Rc < RefCell < JsRuntimeInspector > > > ( ) . clone ( )
702
- } ;
703
- let mut inspector = inspector_rc. borrow_mut ( ) ;
699
+ let inspector = { state. borrow ( ) . borrow :: < Rc < JsRuntimeInspector > > ( ) . clone ( ) } ;
704
700
inspector. wait_for_session_and_break_on_next_statement ( )
705
701
}
706
702
Original file line number Diff line number Diff line change @@ -104,8 +104,7 @@ impl InspectorServer {
104
104
js_runtime : & mut JsRuntime ,
105
105
wait_for_session : bool ,
106
106
) {
107
- let inspector_rc = js_runtime. inspector ( ) ;
108
- let mut inspector = inspector_rc. borrow_mut ( ) ;
107
+ let inspector = js_runtime. inspector ( ) ;
109
108
let session_sender = inspector. get_session_sender ( ) ;
110
109
let deregister_rx = inspector. add_deregister_handler ( ) ;
111
110
let info = InspectorInfo :: new (
Original file line number Diff line number Diff line change @@ -900,10 +900,9 @@ impl MainWorker {
900
900
self
901
901
. js_runtime
902
902
. inspector ( )
903
- . borrow_mut ( )
904
903
. wait_for_session_and_break_on_next_statement ( ) ;
905
904
} else if self . should_wait_for_inspector_session {
906
- self . js_runtime . inspector ( ) . borrow_mut ( ) . wait_for_session ( ) ;
905
+ self . js_runtime . inspector ( ) . wait_for_session ( ) ;
907
906
}
908
907
}
909
908
Original file line number Diff line number Diff line change @@ -567,7 +567,9 @@ async fn inspector_does_not_hang() {
567
567
. unwrap ( ) ;
568
568
569
569
assert_eq ! ( & tester. stdout_lines. next( ) . unwrap( ) , "done" ) ;
570
- assert ! ( tester. child. wait( ) . unwrap( ) . success( ) ) ;
570
+ // TODO(bartlomieju): this line makes no sense - if the inspector is connected then the
571
+ // process should not exit on its own.
572
+ // assert!(tester.child.wait().unwrap().success());
571
573
}
572
574
573
575
#[ tokio:: test]
You can’t perform that action at this time.
0 commit comments