Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Won't compile under node 16 #11

Open
gotchoices opened this issue Mar 11, 2022 · 1 comment
Open

Won't compile under node 16 #11

gotchoices opened this issue Mar 11, 2022 · 1 comment

Comments

@gotchoices
Copy link

npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! ../src/function_origin.cc: In function ‘Nan::NAN_METHOD_RETURN_TYPE SetOrigin(Nan::NAN_METHOD_ARGS_TYPE)’:
npm ERR! ../src/function_origin.cc:11:14: error: no matching function for call to ‘v8::Object::Set(v8::Localv8::String, v8::Localv8::Value)’
npm ERR! 11 | target->Set(Nan::New("file").ToLocalChecked(), origin.ResourceName());
npm ERR! | ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! In file included from /home/kyle/.cache/node-gyp/16.13.2/include/node/node.h:63,
npm ERR! from ../src/function_origin.cc:1:
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, v8::Localv8::Value, v8::Localv8::Value)’
npm ERR! 3961 | V8_WARN_UNUSED_RESULT Maybe Set(Local context,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate expects 3 arguments, 2 provided
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, uint32_t, v8::Localv8::Value)’
npm ERR! 3964 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate expects 3 arguments, 2 provided
npm ERR! ../src/function_origin.cc:13:14: error: no matching function for call to ‘v8::Object::Set(v8::Localv8::String, Nan::imp::IntegerFactoryv8::Integer::return_t)’
npm ERR! 13 | target->Set(Nan::New("line").ToLocalChecked(),
npm ERR! | ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! 14 | Nan::New(fn->GetScriptLineNumber()));
npm ERR! | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! In file included from /home/kyle/.cache/node-gyp/16.13.2/include/node/node.h:63,
npm ERR! from ../src/function_origin.cc:1:
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, v8::Localv8::Value, v8::Localv8::Value)’
npm ERR! 3961 | V8_WARN_UNUSED_RESULT Maybe Set(Local context,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate expects 3 arguments, 2 provided
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, uint32_t, v8::Localv8::Value)’
npm ERR! 3964 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate expects 3 arguments, 2 provided
npm ERR! ../src/function_origin.cc:16:14: error: no matching function for call to ‘v8::Object::Set(v8::Localv8::String, Nan::imp::IntegerFactoryv8::Integer::return_t)’
npm ERR! 16 | target->Set(Nan::New("column").ToLocalChecked(),
npm ERR! | ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! 17 | Nan::New(fn->GetScriptColumnNumber()));
npm ERR! | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! In file included from /home/kyle/.cache/node-gyp/16.13.2/include/node/node.h:63,
npm ERR! from ../src/function_origin.cc:1:
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, v8::Localv8::Value, v8::Localv8::Value)’
npm ERR! 3961 | V8_WARN_UNUSED_RESULT Maybe Set(Local context,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate expects 3 arguments, 2 provided
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, uint32_t, v8::Localv8::Value)’
npm ERR! 3964 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate expects 3 arguments, 2 provided
npm ERR! ../src/function_origin.cc:19:14: error: no matching function for call to ‘v8::Object::Set(v8::Localv8::String, v8::Localv8::Value)’
npm ERR! 19 | target->Set(Nan::New("inferredName").ToLocalChecked(), fn->GetInferredName());
npm ERR! | ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! In file included from /home/kyle/.cache/node-gyp/16.13.2/include/node/node.h:63,
npm ERR! from ../src/function_origin.cc:1:
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, v8::Localv8::Value, v8::Localv8::Value)’
npm ERR! 3961 | V8_WARN_UNUSED_RESULT Maybe Set(Local context,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3961:37: note: candidate expects 3 arguments, 2 provided
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate: ‘v8::Maybe v8::Object::Set(v8::Localv8::Context, uint32_t, v8::Localv8::Value)’
npm ERR! 3964 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index,
npm ERR! | ^~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/v8.h:3964:37: note: candidate expects 3 arguments, 2 provided
npm ERR! ../src/function_origin.cc: At global scope:
npm ERR! ../src/function_origin.cc:22:13: error: variable or field ‘Init’ declared void
npm ERR! 22 | static void Init(Handle exports) {
npm ERR! | ^~~~
npm ERR! ../src/function_origin.cc:22:18: error: ‘Handle’ was not declared in this scope
npm ERR! 22 | static void Init(Handle exports) {
npm ERR! | ^~~~~~
npm ERR! ../src/function_origin.cc:22:31: error: expected primary-expression before ‘>’ token
npm ERR! 22 | static void Init(Handle exports) {
npm ERR! | ^
npm ERR! ../src/function_origin.cc:22:33: error: ‘exports’ was not declared in this scope
npm ERR! 22 | static void Init(Handle exports) {
npm ERR! | ^~~~~~~
npm ERR! In file included from ../src/function_origin.cc:1:
npm ERR! ../src/function_origin.cc:27:30: error: ‘Init’ was not declared in this scope
npm ERR! 27 | NODE_MODULE(function_origin, Init)
npm ERR! | ^~~~
npm ERR! /home/kyle/.cache/node-gyp/16.13.2/include/node/node.h:821:36: note: in definition of macro ‘NODE_MODULE_X’
npm ERR! 821 | (node::addon_register_func) (regfunc),
npm ERR! | ^~~~~~~
npm ERR! ../src/function_origin.cc:27:1: note: in expansion of macro ‘NODE_MODULE’
npm ERR! 27 | NODE_MODULE(function_origin, Init)
npm ERR! | ^~~~~~~~~~~
npm ERR! make: *** [function_origin.target.mk:111: Release/obj.target/function_origin/src/function_origin.o] Error 1

@gotchoices
Copy link
Author

Are you still maintaining this package?

Know how to update this to Node-API? That would version-proof it into the future!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant