mirror of
https://github.com/nodejs/node.git
synced 2026-12-04 02:19:15 -05:00
Dynamic sources with FunctionConstructor is not supported yet as V8 prepends lines to the sources which makes the stack line number incorrect. PR-URL: https://github.com/nodejs/node/pull/43428 Refs: https://github.com/nodejs/node/issues/43047 Reviewed-By: Ben Coe <bencoe@gmail.com>
51 lines
1.5 KiB
C++
51 lines
1.5 KiB
C++
#ifndef SRC_NODE_CONTEXT_DATA_H_
|
|
#define SRC_NODE_CONTEXT_DATA_H_
|
|
|
|
#if defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
|
|
|
|
namespace node {
|
|
|
|
// Pick an index that's hopefully out of the way when we're embedded inside
|
|
// another application. Performance-wise or memory-wise it doesn't matter:
|
|
// Context::SetAlignedPointerInEmbedderData() is backed by a FixedArray,
|
|
// worst case we pay a one-time penalty for resizing the array.
|
|
#ifndef NODE_CONTEXT_EMBEDDER_DATA_INDEX
|
|
#define NODE_CONTEXT_EMBEDDER_DATA_INDEX 32
|
|
#endif
|
|
|
|
#ifndef NODE_CONTEXT_SANDBOX_OBJECT_INDEX
|
|
#define NODE_CONTEXT_SANDBOX_OBJECT_INDEX 33
|
|
#endif
|
|
|
|
#ifndef NODE_CONTEXT_ALLOW_WASM_CODE_GENERATION_INDEX
|
|
#define NODE_CONTEXT_ALLOW_WASM_CODE_GENERATION_INDEX 34
|
|
#endif
|
|
|
|
#ifndef NODE_CONTEXT_TAG
|
|
#define NODE_CONTEXT_TAG 35
|
|
#endif
|
|
|
|
#ifndef NODE_BINDING_LIST
|
|
#define NODE_BINDING_LIST_INDEX 36
|
|
#endif
|
|
|
|
#ifndef NODE_CONTEXT_ALLOW_CODE_GENERATION_FROM_STRINGS_INDEX
|
|
#define NODE_CONTEXT_ALLOW_CODE_GENERATION_FROM_STRINGS_INDEX 37
|
|
#endif
|
|
|
|
enum ContextEmbedderIndex {
|
|
kEnvironment = NODE_CONTEXT_EMBEDDER_DATA_INDEX,
|
|
kSandboxObject = NODE_CONTEXT_SANDBOX_OBJECT_INDEX,
|
|
kAllowWasmCodeGeneration = NODE_CONTEXT_ALLOW_WASM_CODE_GENERATION_INDEX,
|
|
kContextTag = NODE_CONTEXT_TAG,
|
|
kBindingListIndex = NODE_BINDING_LIST_INDEX,
|
|
kAllowCodeGenerationFromStrings =
|
|
NODE_CONTEXT_ALLOW_CODE_GENERATION_FROM_STRINGS_INDEX
|
|
};
|
|
|
|
} // namespace node
|
|
|
|
#endif // defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
|
|
|
|
#endif // SRC_NODE_CONTEXT_DATA_H_
|