Skip to content

Commit

Permalink
doc,vm: clarify usage of cachedData in vm.compileFunction()
Browse files Browse the repository at this point in the history
Fixes: #48175
Signed-off-by: Darshan Sen <raisinten@gmail.com>
PR-URL: #48193
Reviewed-By: Debadree Chatterjee <debadree333@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
RaisinTen authored May 29, 2023
1 parent 2423624 commit 023e880
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion doc/api/vm.md
Original file line number Diff line number Diff line change
Expand Up @@ -1005,7 +1005,8 @@ changes:
is displayed in stack traces produced by this script. **Default:** `0`.
* `cachedData` {Buffer|TypedArray|DataView} Provides an optional `Buffer` or
`TypedArray`, or `DataView` with V8's code cache data for the supplied
source.
source. This must be produced by a prior call to [`vm.compileFunction()`][]
with the same `code` and `params`.
* `produceCachedData` {boolean} Specifies whether to produce new cache data.
**Default:** `false`.
* `parsingContext` {Object} The [contextified][] object in which the said
Expand Down Expand Up @@ -1593,6 +1594,7 @@ are not controllable through the timeout either.
[`script.runInContext()`]: #scriptrunincontextcontextifiedobject-options
[`script.runInThisContext()`]: #scriptruninthiscontextoptions
[`url.origin`]: url.md#urlorigin
[`vm.compileFunction()`]: #vmcompilefunctioncode-params-options
[`vm.createContext()`]: #vmcreatecontextcontextobject-options
[`vm.runInContext()`]: #vmrunincontextcode-contextifiedobject-options
[`vm.runInThisContext()`]: #vmruninthiscontextcode-options
Expand Down

0 comments on commit 023e880

Please sign in to comment.