diff options
author | Ben Noordhuis <info@bnoordhuis.nl> | 2017-11-24 00:13:44 +0100 |
---|---|---|
committer | Ben Noordhuis <info@bnoordhuis.nl> | 2017-11-24 00:13:44 +0100 |
commit | 6f724e1563159fb332ed43068649958e99e7be28 (patch) | |
tree | 524febbafe51e70e328b4386db174294a5debd31 /doc/api/vm.md | |
parent | 05948d8e4e3fefb757ea8b8aa5160cacd07e0cf4 (diff) | |
download | android-node-v8-6f724e1563159fb332ed43068649958e99e7be28.tar.gz android-node-v8-6f724e1563159fb332ed43068649958e99e7be28.tar.bz2 android-node-v8-6f724e1563159fb332ed43068649958e99e7be28.zip |
lib,src: remove vm.runInDebugContext()
The V8 API it is based on is deprecated and scheduled for removal later
this year. Remove it.
PR-URL: https://github.com/nodejs/node/pull/13295
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Diffstat (limited to 'doc/api/vm.md')
-rw-r--r-- | doc/api/vm.md | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/doc/api/vm.md b/doc/api/vm.md index 209302b450..001e7b0a23 100644 --- a/doc/api/vm.md +++ b/doc/api/vm.md @@ -334,36 +334,6 @@ console.log(util.inspect(sandbox)); // { globalVar: 1024 } ``` -## vm.runInDebugContext(code) -<!-- YAML -added: v0.11.14 -deprecated: v8.0.0 -changes: - - version: v9.0.0 - pr-url: https://github.com/nodejs/node/pull/12815 - description: Calling this function now emits a deprecation warning. ---> - -> Stability: 0 - Deprecated. An alternative is in development. - -* `code` {string} The JavaScript code to compile and run. - -The `vm.runInDebugContext()` method compiles and executes `code` inside the V8 -debug context. The primary use case is to gain access to the V8 `Debug` object: - -```js -const vm = require('vm'); -const Debug = vm.runInDebugContext('Debug'); -console.log(Debug.findScript(process.emit).name); // 'events.js' -console.log(Debug.findScript(process.exit).name); // 'internal/process.js' -``` - -*Note*: The debug context and object are intrinsically tied to V8's debugger -implementation and may change (or even be removed) without prior warning. - -The `Debug` object can also be made available using the V8-specific -`--expose_debug_as=` [command line option][]. - ## vm.runInNewContext(code[, sandbox][, options]) <!-- YAML added: v0.3.1 @@ -517,7 +487,6 @@ associating it with the `sandbox` object is what this document refers to as [`vm.runInContext()`]: #vm_vm_runincontext_code_contextifiedsandbox_options [`vm.runInThisContext()`]: #vm_vm_runinthiscontext_code_options [V8 Embedder's Guide]: https://github.com/v8/v8/wiki/Embedder's%20Guide#contexts -[command line option]: cli.html [contextified]: #vm_what_does_it_mean_to_contextify_an_object [global object]: https://es5.github.io/#x15.1 [indirect `eval()` call]: https://es5.github.io/#x10.4.2 |