mirror of
https://github.com/nodejs/node.git
synced 2026-11-21 12:59:16 -05:00
src: delete unused method SetTemplateMethodNoSideEffect
PR-URL: https://github.com/nodejs/node/pull/26451 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
1 parent
c4015ebfed
commit
dd23fc1fd5
2 files changed
-20
No files matched your search
@@ -957,22 +957,6 @@ inline void Environment::SetTemplateMethod(v8::Local<v8::FunctionTemplate> that,
|
||||
t->SetClassName(name_string); // NODE_SET_METHOD() compatibility.
|
||||
}
|
||||
|
||||
inline void Environment::SetTemplateMethodNoSideEffect(
|
||||
v8::Local<v8::FunctionTemplate> that,
|
||||
const char* name,
|
||||
v8::FunctionCallback callback) {
|
||||
v8::Local<v8::FunctionTemplate> t =
|
||||
NewFunctionTemplate(callback, v8::Local<v8::Signature>(),
|
||||
v8::ConstructorBehavior::kAllow,
|
||||
v8::SideEffectType::kHasNoSideEffect);
|
||||
// kInternalized strings are created in the old space.
|
||||
const v8::NewStringType type = v8::NewStringType::kInternalized;
|
||||
v8::Local<v8::String> name_string =
|
||||
v8::String::NewFromUtf8(isolate(), name, type).ToLocalChecked();
|
||||
that->Set(name_string, t);
|
||||
t->SetClassName(name_string); // NODE_SET_METHOD() compatibility.
|
||||
}
|
||||
|
||||
void Environment::AddCleanupHook(void (*fn)(void*), void* arg) {
|
||||
auto insertion_info = cleanup_hooks_.emplace(CleanupHookCallback {
|
||||
fn, arg, cleanup_hook_counter_++
|
||||
|
||||
@@ -885,10 +885,6 @@ class Environment {
|
||||
inline void SetProtoMethodNoSideEffect(v8::Local<v8::FunctionTemplate> that,
|
||||
const char* name,
|
||||
v8::FunctionCallback callback);
|
||||
inline void SetTemplateMethodNoSideEffect(
|
||||
v8::Local<v8::FunctionTemplate> that,
|
||||
const char* name,
|
||||
v8::FunctionCallback callback);
|
||||
|
||||
void BeforeExit(void (*cb)(void* arg), void* arg);
|
||||
void RunBeforeExitCallbacks();
|
||||
|
||||
Reference in new issue
Block a user