Skip to content

Commit 2767209

Browse files
Gabriel Schulhofaddaleax
Gabriel Schulhof
authored andcommitted
addons: remove semicolons from after module definition
Having semicolons there runs counter to our documentation and illicits warnings in pedantic mode. This removes semicolons from after uses of NODE_MODULE and NODE_MODULE_CONTEXT_AWARE_BUILTIN. PR-URL: #12919 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Daniel Bevenius <[email protected]> Reviewed-By: Alexey Orlenko <[email protected]>
1 parent b23d414 commit 2767209

File tree

15 files changed

+15
-15
lines changed

15 files changed

+15
-15
lines changed

benchmark/misc/function_call/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ extern "C" void init (Local<Object> target) {
1414
NODE_SET_METHOD(target, "hello", Hello);
1515
}
1616

17-
NODE_MODULE(binding, init);
17+
NODE_MODULE(binding, init)

doc/api/addons.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1116,7 +1116,7 @@ void init(Local<Object> exports) {
11161116
AtExit(at_exit_cb1, exports->GetIsolate());
11171117
}
11181118

1119-
NODE_MODULE(addon, init);
1119+
NODE_MODULE(addon, init)
11201120

11211121
} // namespace demo
11221122
```

src/node.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -4618,5 +4618,5 @@ int Start(int argc, char** argv) {
46184618
#if !HAVE_INSPECTOR
46194619
static void InitEmptyBindings() {}
46204620

4621-
NODE_MODULE_CONTEXT_AWARE_BUILTIN(inspector, InitEmptyBindings);
4621+
NODE_MODULE_CONTEXT_AWARE_BUILTIN(inspector, InitEmptyBindings)
46224622
#endif // !HAVE_INSPECTOR

src/node_contextify.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1033,4 +1033,4 @@ void InitContextify(Local<Object> target,
10331033
} // anonymous namespace
10341034
} // namespace node
10351035

1036-
NODE_MODULE_CONTEXT_AWARE_BUILTIN(contextify, node::InitContextify);
1036+
NODE_MODULE_CONTEXT_AWARE_BUILTIN(contextify, node::InitContextify)

test/addons/async-hello-world/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,4 @@ void init(v8::Local<v8::Object> exports, v8::Local<v8::Object> module) {
7777
NODE_SET_METHOD(module, "exports", Method);
7878
}
7979

80-
NODE_MODULE(binding, init);
80+
NODE_MODULE(binding, init)

test/addons/at-exit/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,4 @@ void init(Local<Object> exports) {
4040
atexit(sanity_check);
4141
}
4242

43-
NODE_MODULE(binding, init);
43+
NODE_MODULE(binding, init)

test/addons/buffer-free-callback/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,4 @@ void init(v8::Local<v8::Object> exports) {
4141
NODE_SET_METHOD(exports, "check", Check);
4242
}
4343

44-
NODE_MODULE(binding, init);
44+
NODE_MODULE(binding, init)

test/addons/hello-world-function-export/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ void init(v8::Local<v8::Object> exports, v8::Local<v8::Object> module) {
1111
NODE_SET_METHOD(module, "exports", Method);
1212
}
1313

14-
NODE_MODULE(binding, init);
14+
NODE_MODULE(binding, init)

test/addons/hello-world/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ void init(v8::Local<v8::Object> exports) {
1111
NODE_SET_METHOD(exports, "hello", Method);
1212
}
1313

14-
NODE_MODULE(binding, init);
14+
NODE_MODULE(binding, init)

test/addons/load-long-path/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ void init(v8::Local<v8::Object> exports) {
1010
NODE_SET_METHOD(exports, "hello", Method);
1111
}
1212

13-
NODE_MODULE(binding, init);
13+
NODE_MODULE(binding, init)

test/addons/null-buffer-neuter/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ void init(v8::Local<v8::Object> exports) {
3838
NODE_SET_METHOD(exports, "run", Run);
3939
}
4040

41-
NODE_MODULE(binding, init);
41+
NODE_MODULE(binding, init)

test/addons/parse-encoding/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@ void Initialize(v8::Local<v8::Object> exports) {
3535

3636
} // anonymous namespace
3737

38-
NODE_MODULE(binding, Initialize);
38+
NODE_MODULE(binding, Initialize)

test/addons/repl-domain-abort/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ void init(Local<Object> exports) {
4444
NODE_SET_METHOD(exports, "method", Method);
4545
}
4646

47-
NODE_MODULE(binding, init);
47+
NODE_MODULE(binding, init)

test/addons/stringbytes-external-exceed-max/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ void init(v8::Local<v8::Object> exports) {
2121
NODE_SET_METHOD(exports, "ensureAllocation", EnsureAllocation);
2222
}
2323

24-
NODE_MODULE(binding, init);
24+
NODE_MODULE(binding, init)

test/addons/symlinked-module/binding.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ void init(v8::Local<v8::Object> exports) {
1010
NODE_SET_METHOD(exports, "hello", Method);
1111
}
1212

13-
NODE_MODULE(binding, init);
13+
NODE_MODULE(binding, init)

0 commit comments

Comments
 (0)