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 and MoLow committed Jul 6, 2023
1 parent 67b2c2a commit 563f9fe
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 @@ -1002,7 +1002,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 @@ -1590,6 +1591,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 563f9fe

Please sign in to comment.