mirror of
https://github.com/servo/servo.git
synced 2025-09-29 16:19:14 +01:00
script: Return a Result from GlobalScope::evaluate_script_on_global_with_result (#38549)
Make GlobalScope::evaluate_script_on_global_with_result return a Result instead of a boolean. This is the first step to resolve issue #37810. Testing: Should not break or fix any existing tests --------- Signed-off-by: Rodion Borovyk <rodion.borovyk@gmail.com>
This commit is contained in:
parent
86c37a380b
commit
4f8731d562
11 changed files with 45 additions and 28 deletions
|
@ -60,7 +60,7 @@ pub(crate) fn handle_evaluate_js(
|
|||
let source_code = SourceCode::Text(Rc::new(DOMString::from_string(eval)));
|
||||
// TODO: run code with SpiderMonkey Debugger API, like Firefox does
|
||||
// <https://searchfox.org/mozilla-central/rev/f6a806c38c459e0e0d797d264ca0e8ad46005105/devtools/server/actors/webconsole/eval-with-debugger.js#270>
|
||||
global.evaluate_script_on_global_with_result(
|
||||
_ = global.evaluate_script_on_global_with_result(
|
||||
&source_code,
|
||||
"<eval>",
|
||||
rval.handle_mut(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue