Closed hafeyang closed 6 years ago
You may try it like this: var Test = ffi.Library('test',{ 'init': ['void',['string','int']], 'hello': ['string', ['int']] }); good luck!
tried string but failed ;(
FFI generally doesn't work great with C++ functions. You should write a C wrapper around that function and invoke that through FFI.
how to ref c++ std::string type?
i have cpp code:
how to ref std::string