@ -74,7 +74,7 @@ void init(Local<Object> exports) {
NODE_SET_METHOD(exports, "hello", Method);
NODE_SET_METHOD(exports, "hello", Method);
}
}
NODE_MODULE(addon , init)
NODE_MODULE(NODE_GYP_MODULE_NAME , init)
} // namespace demo
} // namespace demo
```
```
@ -84,7 +84,7 @@ the pattern:
```cpp
```cpp
void Initialize(Local< Object > exports);
void Initialize(Local< Object > exports);
NODE_MODULE(module_name , Initialize)
NODE_MODULE(NODE_GYP_MODULE_NAME , Initialize)
```
```
There is no semi-colon after `NODE_MODULE` as it's not a function (see
There is no semi-colon after `NODE_MODULE` as it's not a function (see
@ -330,7 +330,7 @@ void Init(Local<Object> exports) {
NODE_SET_METHOD(exports, "add", Add);
NODE_SET_METHOD(exports, "add", Add);
}
}
NODE_MODULE(addon , Init)
NODE_MODULE(NODE_GYP_MODULE_NAME , Init)
} // namespace demo
} // namespace demo
```
```
@ -378,7 +378,7 @@ void Init(Local<Object> exports, Local<Object> module) {
NODE_SET_METHOD(module, "exports", RunCallback);
NODE_SET_METHOD(module, "exports", RunCallback);
}
}
NODE_MODULE(addon , Init)
NODE_MODULE(NODE_GYP_MODULE_NAME , Init)
} // namespace demo
} // namespace demo
```
```
@ -434,7 +434,7 @@ void Init(Local<Object> exports, Local<Object> module) {
NODE_SET_METHOD(module, "exports", CreateObject);
NODE_SET_METHOD(module, "exports", CreateObject);
}
}
NODE_MODULE(addon , Init)
NODE_MODULE(NODE_GYP_MODULE_NAME , Init)
} // namespace demo
} // namespace demo
```
```
@ -493,7 +493,7 @@ void Init(Local<Object> exports, Local<Object> module) {
NODE_SET_METHOD(module, "exports", CreateFunction);
NODE_SET_METHOD(module, "exports", CreateFunction);
}
}
NODE_MODULE(addon , Init)
NODE_MODULE(NODE_GYP_MODULE_NAME , Init)
} // namespace demo
} // namespace demo
```
```
@ -529,7 +529,7 @@ void InitAll(Local<Object> exports) {
MyObject::Init(exports);
MyObject::Init(exports);
}
}
NODE_MODULE(addon , InitAll)
NODE_MODULE(NODE_GYP_MODULE_NAME , InitAll)
} // namespace demo
} // namespace demo
```
```
@ -713,7 +713,7 @@ void InitAll(Local<Object> exports, Local<Object> module) {
NODE_SET_METHOD(module, "exports", CreateObject);
NODE_SET_METHOD(module, "exports", CreateObject);
}
}
NODE_MODULE(addon , InitAll)
NODE_MODULE(NODE_GYP_MODULE_NAME , InitAll)
} // namespace demo
} // namespace demo
```
```
@ -926,7 +926,7 @@ void InitAll(Local<Object> exports) {
NODE_SET_METHOD(exports, "add", Add);
NODE_SET_METHOD(exports, "add", Add);
}
}
NODE_MODULE(addon , InitAll)
NODE_MODULE(NODE_GYP_MODULE_NAME , InitAll)
} // namespace demo
} // namespace demo
```
```
@ -1117,7 +1117,7 @@ void init(Local<Object> exports) {
AtExit(sanity_check);
AtExit(sanity_check);
}
}
NODE_MODULE(addon , init)
NODE_MODULE(NODE_GYP_MODULE_NAME , init)
} // namespace demo
} // namespace demo
```
```