Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src/env.h
diff options
context:
space:
mode:
authorJames M Snell <jasnell@gmail.com>2020-12-15 22:52:17 +0300
committerJames M Snell <jasnell@gmail.com>2021-01-03 23:58:09 +0300
commit28fe1ef63512acd40cfd1dd15918db494c92f45f (patch)
treefb65e10e0c966e2484a3f2151870738499d575b7 /src/env.h
parent7cfa1bee418696c1c97c1f2466520ab4f4cc8791 (diff)
src: reduce duplicated boilerplate with new env utility fn
Signed-off-by: James M Snell <jasnell@gmail.com> PR-URL: https://github.com/nodejs/node/pull/36536 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Diffstat (limited to 'src/env.h')
-rw-r--r--src/env.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/env.h b/src/env.h
index a0d59ff8728..9ac090e07cc 100644
--- a/src/env.h
+++ b/src/env.h
@@ -1233,6 +1233,14 @@ class Environment : public MemoryRetainer {
const char* name,
v8::FunctionCallback callback);
+ inline void SetConstructorFunction(v8::Local<v8::Object> that,
+ const char* name,
+ v8::Local<v8::FunctionTemplate> tmpl);
+
+ inline void SetConstructorFunction(v8::Local<v8::Object> that,
+ v8::Local<v8::String> name,
+ v8::Local<v8::FunctionTemplate> tmpl);
+
void AtExit(void (*cb)(void* arg), void* arg);
void RunAtExitCallbacks();