Skip to content

Commit fcfde34

Browse files
legendecasjuanarbol
authored andcommitted
src: rename internal module declaration as internal bindings
This is a continuation of the name reification on the internal bindings. Renames NODE_MODULE_CONTEXT_AWARE_INTERNAL and NODE_MODULE_EXTERNAL_REFERENCE to NODE_BINDING_CONTEXT_AWARE_INTERNAL and NODE_BINDING_EXTERNAL_REFERENCE respectively. PR-URL: #45551 Backport-PR-URL: #46336 Refs: #44036 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com> Reviewed-By: Jacob Smith <jacob@frende.me> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
1 parent 536322f commit fcfde34

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+193
-189
lines changed

src/README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -419,9 +419,9 @@ void Initialize(Local<Object> target,
419419
SetConstructorFunction(context, target, "ChannelWrap", channel_wrap);
420420
}
421421

422-
// Run the `Initialize` function when loading this module through
422+
// Run the `Initialize` function when loading this binding through
423423
// `internalBinding('cares_wrap')` in Node.js's built-in JavaScript code:
424-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(cares_wrap, Initialize)
424+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(cares_wrap, Initialize)
425425
```
426426
427427
If the C++ binding is loaded during bootstrap, it needs to be registered
@@ -438,10 +438,10 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
438438
} // namespace util
439439
} // namespace node
440440
441-
// The first argument passed to `NODE_MODULE_EXTERNAL_REFERENCE`,
441+
// The first argument passed to `NODE_BINDING_EXTERNAL_REFERENCE`,
442442
// which is `util` here, needs to be added to the
443443
// `EXTERNAL_REFERENCE_BINDING_LIST_BASE` list in node_external_reference.h
444-
NODE_MODULE_EXTERNAL_REFERENCE(util, node::util::RegisterExternalReferences)
444+
NODE_BINDING_EXTERNAL_REFERENCE(util, node::util::RegisterExternalReferences)
445445
```
446446

447447
Otherwise, you might see an error message like this when building the

src/async_wrap.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -709,6 +709,6 @@ Local<Object> AsyncWrap::GetOwner(Environment* env, Local<Object> obj) {
709709

710710
} // namespace node
711711

712-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(async_wrap, node::AsyncWrap::Initialize)
713-
NODE_MODULE_EXTERNAL_REFERENCE(async_wrap,
714-
node::AsyncWrap::RegisterExternalReferences)
712+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(async_wrap, node::AsyncWrap::Initialize)
713+
NODE_BINDING_EXTERNAL_REFERENCE(async_wrap,
714+
node::AsyncWrap::RegisterExternalReferences)

src/cares_wrap.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -1976,6 +1976,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
19761976
} // namespace cares_wrap
19771977
} // namespace node
19781978

1979-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(cares_wrap, node::cares_wrap::Initialize)
1980-
NODE_MODULE_EXTERNAL_REFERENCE(cares_wrap,
1981-
node::cares_wrap::RegisterExternalReferences)
1979+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(cares_wrap, node::cares_wrap::Initialize)
1980+
NODE_BINDING_EXTERNAL_REFERENCE(cares_wrap,
1981+
node::cares_wrap::RegisterExternalReferences)

src/crypto/crypto_tls.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -2148,6 +2148,6 @@ void TLSWrap::RegisterExternalReferences(ExternalReferenceRegistry* registry) {
21482148
} // namespace crypto
21492149
} // namespace node
21502150

2151-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(tls_wrap, node::crypto::TLSWrap::Initialize)
2152-
NODE_MODULE_EXTERNAL_REFERENCE(
2151+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(tls_wrap, node::crypto::TLSWrap::Initialize)
2152+
NODE_BINDING_EXTERNAL_REFERENCE(
21532153
tls_wrap, node::crypto::TLSWrap::RegisterExternalReferences)

src/fs_event_wrap.cc

+4-3
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,7 @@ void FSEventWrap::OnEvent(uv_fs_event_t* handle, const char* filename,
237237
} // anonymous namespace
238238
} // namespace node
239239

240-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(fs_event_wrap, node::FSEventWrap::Initialize)
241-
NODE_MODULE_EXTERNAL_REFERENCE(fs_event_wrap,
242-
node::FSEventWrap::RegisterExternalReferences)
240+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(fs_event_wrap,
241+
node::FSEventWrap::Initialize)
242+
NODE_BINDING_EXTERNAL_REFERENCE(fs_event_wrap,
243+
node::FSEventWrap::RegisterExternalReferences)

src/handle_wrap.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -181,5 +181,5 @@ void HandleWrap::RegisterExternalReferences(
181181

182182
} // namespace node
183183

184-
NODE_MODULE_EXTERNAL_REFERENCE(handle_wrap,
185-
node::HandleWrap::RegisterExternalReferences)
184+
NODE_BINDING_EXTERNAL_REFERENCE(handle_wrap,
185+
node::HandleWrap::RegisterExternalReferences)

src/heap_utils.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -463,6 +463,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
463463
} // namespace heap
464464
} // namespace node
465465

466-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(heap_utils, node::heap::Initialize)
467-
NODE_MODULE_EXTERNAL_REFERENCE(heap_utils,
468-
node::heap::RegisterExternalReferences)
466+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(heap_utils, node::heap::Initialize)
467+
NODE_BINDING_EXTERNAL_REFERENCE(heap_utils,
468+
node::heap::RegisterExternalReferences)

src/inspector_js_api.cc

+3-4
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
399399
} // namespace inspector
400400
} // namespace node
401401

402-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(inspector,
403-
node::inspector::Initialize)
404-
NODE_MODULE_EXTERNAL_REFERENCE(inspector,
405-
node::inspector::RegisterExternalReferences)
402+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(inspector, node::inspector::Initialize)
403+
NODE_BINDING_EXTERNAL_REFERENCE(inspector,
404+
node::inspector::RegisterExternalReferences)

src/inspector_profiler.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
524524
} // namespace profiler
525525
} // namespace node
526526

527-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(profiler, node::profiler::Initialize)
528-
NODE_MODULE_EXTERNAL_REFERENCE(profiler,
529-
node::profiler::RegisterExternalReferences)
527+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(profiler, node::profiler::Initialize)
528+
NODE_BINDING_EXTERNAL_REFERENCE(profiler,
529+
node::profiler::RegisterExternalReferences)

src/js_stream.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -216,4 +216,4 @@ void JSStream::Initialize(Local<Object> target,
216216

217217
} // namespace node
218218

219-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(js_stream, node::JSStream::Initialize)
219+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(js_stream, node::JSStream::Initialize)

src/js_udp_wrap.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -217,4 +217,4 @@ void JSUDPWrap::Initialize(Local<Object> target,
217217

218218
} // namespace node
219219

220-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(js_udp_wrap, node::JSUDPWrap::Initialize)
220+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(js_udp_wrap, node::JSUDPWrap::Initialize)

src/module_wrap.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -814,5 +814,5 @@ void ModuleWrap::Initialize(Local<Object> target,
814814
} // namespace loader
815815
} // namespace node
816816

817-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(module_wrap,
818-
node::loader::ModuleWrap::Initialize)
817+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(module_wrap,
818+
node::loader::ModuleWrap::Initialize)

src/node.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -765,8 +765,8 @@ int InitializeNodeWithArgs(std::vector<std::string>* argv,
765765
// Initialize node_start_time to get relative uptime.
766766
per_process::node_start_time = uv_hrtime();
767767

768-
// Register built-in modules
769-
binding::RegisterBuiltinModules();
768+
// Register built-in bindings
769+
binding::RegisterBuiltinBindings();
770770

771771
// Make inherited handles noninheritable.
772772
if (!(flags & ProcessInitializationFlags::kEnableStdioInheritance) &&
@@ -1239,5 +1239,5 @@ int Stop(Environment* env) {
12391239
#if !HAVE_INSPECTOR
12401240
void Initialize() {}
12411241

1242-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(inspector, Initialize)
1242+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(inspector, Initialize)
12431243
#endif // !HAVE_INSPECTOR

src/node_binding.cc

+38-39
Original file line numberDiff line numberDiff line change
@@ -9,36 +9,36 @@
99
#include <string>
1010

1111
#if HAVE_OPENSSL
12-
#define NODE_BUILTIN_OPENSSL_MODULES(V) V(crypto) V(tls_wrap)
12+
#define NODE_BUILTIN_OPENSSL_BINDINGS(V) V(crypto) V(tls_wrap)
1313
#else
14-
#define NODE_BUILTIN_OPENSSL_MODULES(V)
14+
#define NODE_BUILTIN_OPENSSL_BINDINGS(V)
1515
#endif
1616

1717
#if NODE_HAVE_I18N_SUPPORT
18-
#define NODE_BUILTIN_ICU_MODULES(V) V(icu)
18+
#define NODE_BUILTIN_ICU_BINDINGS(V) V(icu)
1919
#else
20-
#define NODE_BUILTIN_ICU_MODULES(V)
20+
#define NODE_BUILTIN_ICU_BINDINGS(V)
2121
#endif
2222

2323
#if HAVE_INSPECTOR
24-
#define NODE_BUILTIN_PROFILER_MODULES(V) V(profiler)
24+
#define NODE_BUILTIN_PROFILER_BINDINGS(V) V(profiler)
2525
#else
26-
#define NODE_BUILTIN_PROFILER_MODULES(V)
26+
#define NODE_BUILTIN_PROFILER_BINDINGS(V)
2727
#endif
2828

2929
#if HAVE_DTRACE || HAVE_ETW
30-
#define NODE_BUILTIN_DTRACE_MODULES(V) V(dtrace)
30+
#define NODE_BUILTIN_DTRACE_BINDINGS(V) V(dtrace)
3131
#else
32-
#define NODE_BUILTIN_DTRACE_MODULES(V)
32+
#define NODE_BUILTIN_DTRACE_BINDINGS(V)
3333
#endif
3434

35-
// A list of built-in modules. In order to do module registration
36-
// in node::Init(), need to add built-in modules in the following list.
37-
// Then in binding::RegisterBuiltinModules(), it calls modules' registration
38-
// function. This helps the built-in modules are loaded properly when
35+
// A list of built-in bindings. In order to do binding registration
36+
// in node::Init(), need to add built-in bindings in the following list.
37+
// Then in binding::RegisterBuiltinBindings(), it calls bindings' registration
38+
// function. This helps the built-in bindings are loaded properly when
3939
// node is built as static library. No need to depend on the
4040
// __attribute__((constructor)) like mechanism in GCC.
41-
#define NODE_BUILTIN_STANDARD_MODULES(V) \
41+
#define NODE_BUILTIN_STANDARD_BINDINGS(V) \
4242
V(async_wrap) \
4343
V(blob) \
4444
V(block_list) \
@@ -92,21 +92,21 @@
9292
V(worker) \
9393
V(zlib)
9494

95-
#define NODE_BUILTIN_MODULES(V) \
96-
NODE_BUILTIN_STANDARD_MODULES(V) \
97-
NODE_BUILTIN_OPENSSL_MODULES(V) \
98-
NODE_BUILTIN_ICU_MODULES(V) \
99-
NODE_BUILTIN_PROFILER_MODULES(V) \
100-
NODE_BUILTIN_DTRACE_MODULES(V)
95+
#define NODE_BUILTIN_BINDINGS(V) \
96+
NODE_BUILTIN_STANDARD_BINDINGS(V) \
97+
NODE_BUILTIN_OPENSSL_BINDINGS(V) \
98+
NODE_BUILTIN_ICU_BINDINGS(V) \
99+
NODE_BUILTIN_PROFILER_BINDINGS(V) \
100+
NODE_BUILTIN_DTRACE_BINDINGS(V)
101101

102-
// This is used to load built-in modules. Instead of using
102+
// This is used to load built-in bindings. Instead of using
103103
// __attribute__((constructor)), we call the _register_<modname>
104-
// function for each built-in modules explicitly in
105-
// binding::RegisterBuiltinModules(). This is only forward declaration.
106-
// The definitions are in each module's implementation when calling
107-
// the NODE_MODULE_CONTEXT_AWARE_INTERNAL.
104+
// function for each built-in bindings explicitly in
105+
// binding::RegisterBuiltinBindings(). This is only forward declaration.
106+
// The definitions are in each binding's implementation when calling
107+
// the NODE_BINDING_CONTEXT_AWARE_INTERNAL.
108108
#define V(modname) void _register_##modname();
109-
NODE_BUILTIN_MODULES(V)
109+
NODE_BUILTIN_BINDINGS(V)
110110
#undef V
111111

112112
#ifdef _AIX
@@ -559,9 +559,9 @@ inline struct node_module* FindModule(struct node_module* list,
559559
return mp;
560560
}
561561

562-
static Local<Object> InitModule(Environment* env,
563-
node_module* mod,
564-
Local<String> module) {
562+
static Local<Object> InitInternalBinding(Environment* env,
563+
node_module* mod,
564+
Local<String> module) {
565565
// Internal bindings don't have a "module" object, only exports.
566566
Local<Function> ctor = env->binding_data_ctor_template()
567567
->GetFunction(env->context())
@@ -585,7 +585,7 @@ void GetInternalBinding(const FunctionCallbackInfo<Value>& args) {
585585

586586
node_module* mod = FindModule(modlist_internal, *module_v, NM_F_INTERNAL);
587587
if (mod != nullptr) {
588-
exports = InitModule(env, mod, module);
588+
exports = InitInternalBinding(env, mod, module);
589589
env->internal_bindings.insert(mod);
590590
} else if (!strcmp(*module_v, "constants")) {
591591
exports = Object::New(env->isolate());
@@ -602,7 +602,7 @@ void GetInternalBinding(const FunctionCallbackInfo<Value>& args) {
602602
builtins::BuiltinLoader::GetConfigString(env->isolate()))
603603
.FromJust());
604604
} else {
605-
return THROW_ERR_INVALID_MODULE(env, "No such module: %s", *module_v);
605+
return THROW_ERR_INVALID_MODULE(env, "No such binding: %s", *module_v);
606606
}
607607

608608
args.GetReturnValue().Set(exports);
@@ -633,7 +633,7 @@ void GetLinkedBinding(const FunctionCallbackInfo<Value>& args) {
633633

634634
if (mod == nullptr) {
635635
return THROW_ERR_INVALID_MODULE(
636-
env, "No such module was linked: %s", *module_name_v);
636+
env, "No such binding was linked: %s", *module_name_v);
637637
}
638638

639639
Local<Object> module = Object::New(env->isolate());
@@ -649,8 +649,7 @@ void GetLinkedBinding(const FunctionCallbackInfo<Value>& args) {
649649
mod->nm_register_func(exports, module, mod->nm_priv);
650650
} else {
651651
return THROW_ERR_INVALID_MODULE(
652-
env,
653-
"Linked moduled has no declared entry point.");
652+
env, "Linked binding has no declared entry point.");
654653
}
655654

656655
auto effective_exports =
@@ -659,11 +658,11 @@ void GetLinkedBinding(const FunctionCallbackInfo<Value>& args) {
659658
args.GetReturnValue().Set(effective_exports);
660659
}
661660

662-
// Call built-in modules' _register_<module name> function to
663-
// do module registration explicitly.
664-
void RegisterBuiltinModules() {
661+
// Call built-in bindings' _register_<module name> function to
662+
// do binding registration explicitly.
663+
void RegisterBuiltinBindings() {
665664
#define V(modname) _register_##modname();
666-
NODE_BUILTIN_MODULES(V)
665+
NODE_BUILTIN_BINDINGS(V)
667666
#undef V
668667
}
669668

@@ -675,5 +674,5 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
675674
} // namespace binding
676675
} // namespace node
677676

678-
NODE_MODULE_EXTERNAL_REFERENCE(binding,
679-
node::binding::RegisterExternalReferences)
677+
NODE_BINDING_EXTERNAL_REFERENCE(binding,
678+
node::binding::RegisterExternalReferences)

src/node_binding.h

+5-5
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ static_assert(static_cast<int>(NM_F_LINKED) ==
2424
static_cast<int>(node::ModuleFlags::kLinked),
2525
"NM_F_LINKED != node::ModuleFlags::kLinked");
2626

27-
#define NODE_MODULE_CONTEXT_AWARE_CPP(modname, regfunc, priv, flags) \
27+
#define NODE_BINDING_CONTEXT_AWARE_CPP(modname, regfunc, priv, flags) \
2828
static node::node_module _module = { \
2929
NODE_MODULE_VERSION, \
3030
flags, \
@@ -44,8 +44,8 @@ void napi_module_register_by_symbol(v8::Local<v8::Object> exports,
4444

4545
namespace node {
4646

47-
#define NODE_MODULE_CONTEXT_AWARE_INTERNAL(modname, regfunc) \
48-
NODE_MODULE_CONTEXT_AWARE_CPP(modname, regfunc, nullptr, NM_F_INTERNAL)
47+
#define NODE_BINDING_CONTEXT_AWARE_INTERNAL(modname, regfunc) \
48+
NODE_BINDING_CONTEXT_AWARE_CPP(modname, regfunc, nullptr, NM_F_INTERNAL)
4949

5050
// Globals per process
5151
// This is set by node::Init() which is used by embedders
@@ -83,10 +83,10 @@ class DLib {
8383
};
8484

8585
// Call _register<module_name> functions for all of
86-
// the built-in modules. Because built-in modules don't
86+
// the built-in bindings. Because built-in bindings don't
8787
// use the __attribute__((constructor)). Need to
8888
// explicitly call the _register* functions.
89-
void RegisterBuiltinModules();
89+
void RegisterBuiltinBindings();
9090
void GetInternalBinding(const v8::FunctionCallbackInfo<v8::Value>& args);
9191
void GetLinkedBinding(const v8::FunctionCallbackInfo<v8::Value>& args);
9292
void DLOpen(const v8::FunctionCallbackInfo<v8::Value>& args);

src/node_blob.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -499,5 +499,5 @@ void Blob::RegisterExternalReferences(ExternalReferenceRegistry* registry) {
499499

500500
} // namespace node
501501

502-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(blob, node::Blob::Initialize)
503-
NODE_MODULE_EXTERNAL_REFERENCE(blob, node::Blob::RegisterExternalReferences)
502+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(blob, node::Blob::Initialize)
503+
NODE_BINDING_EXTERNAL_REFERENCE(blob, node::Blob::RegisterExternalReferences)

src/node_buffer.cc

+3-2
Original file line numberDiff line numberDiff line change
@@ -1455,5 +1455,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
14551455
} // namespace Buffer
14561456
} // namespace node
14571457

1458-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(buffer, node::Buffer::Initialize)
1459-
NODE_MODULE_EXTERNAL_REFERENCE(buffer, node::Buffer::RegisterExternalReferences)
1458+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(buffer, node::Buffer::Initialize)
1459+
NODE_BINDING_EXTERNAL_REFERENCE(buffer,
1460+
node::Buffer::RegisterExternalReferences)

src/node_builtins.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ void BuiltinLoader::RegisterExternalReferences(
683683
} // namespace builtins
684684
} // namespace node
685685

686-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(builtins,
687-
node::builtins::BuiltinLoader::Initialize)
688-
NODE_MODULE_EXTERNAL_REFERENCE(
686+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(builtins,
687+
node::builtins::BuiltinLoader::Initialize)
688+
NODE_BINDING_EXTERNAL_REFERENCE(
689689
builtins, node::builtins::BuiltinLoader::RegisterExternalReferences)

src/node_config.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -86,4 +86,4 @@ static void Initialize(Local<Object> target,
8686

8787
} // namespace node
8888

89-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(config, node::Initialize)
89+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(config, node::Initialize)

src/node_contextify.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -1425,6 +1425,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
14251425
} // namespace contextify
14261426
} // namespace node
14271427

1428-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(contextify, node::contextify::Initialize)
1429-
NODE_MODULE_EXTERNAL_REFERENCE(contextify,
1430-
node::contextify::RegisterExternalReferences)
1428+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(contextify, node::contextify::Initialize)
1429+
NODE_BINDING_EXTERNAL_REFERENCE(contextify,
1430+
node::contextify::RegisterExternalReferences)

src/node_credentials.cc

+3-3
Original file line numberDiff line numberDiff line change
@@ -483,6 +483,6 @@ static void Initialize(Local<Object> target,
483483
} // namespace credentials
484484
} // namespace node
485485

486-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(credentials, node::credentials::Initialize)
487-
NODE_MODULE_EXTERNAL_REFERENCE(credentials,
488-
node::credentials::RegisterExternalReferences)
486+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(credentials, node::credentials::Initialize)
487+
NODE_BINDING_EXTERNAL_REFERENCE(credentials,
488+
node::credentials::RegisterExternalReferences)

src/node_crypto.cc

+3-2
Original file line numberDiff line numberDiff line change
@@ -92,5 +92,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
9292
} // namespace crypto
9393
} // namespace node
9494

95-
NODE_MODULE_CONTEXT_AWARE_INTERNAL(crypto, node::crypto::Initialize)
96-
NODE_MODULE_EXTERNAL_REFERENCE(crypto, node::crypto::RegisterExternalReferences)
95+
NODE_BINDING_CONTEXT_AWARE_INTERNAL(crypto, node::crypto::Initialize)
96+
NODE_BINDING_EXTERNAL_REFERENCE(crypto,
97+
node::crypto::RegisterExternalReferences)

0 commit comments

Comments
 (0)