Releases: pmed/v8pp
Version 2.1.1
Version 2.1.0
- C++17 required
- explicit binding methods:
var
,function
,const_
- more standard types support:
std::tuple
,std::variant
- fix tests for the recent V8 versions
Version 1.8.1
Version 1.7.0
Version 1.6.0 with Node.js >= 8.X support
V8 5.9 support
Before dropping support of old V8 versions with deprecated API
v1.5.1
Allow to store wrapped C++ objects in `std::shared_ptr`
- Wrapped C++ class now can be bound to store objects in
std::shared_ptr
:
class MyClass {};
v8pp::class_<MyClass, true> MyClass_binding(isolate);
v8::Handle<v8::Object> v8_obj = v8pp::class_<MyClass, true>::create_object(isolate);
std::shared_ptr<MyClass> obj = v8pp::class_<MyClass, true>::unwrap_object(isolate, v8_obj);
- Added compile-time
type_id()
function instead of RTTI usage. - Fixed an issue #62
Fixed issue with deleting referenced C++ objects
See #60: C++ objects referenced with reference_external are still deleted when class_::destroy() is called
Custom RTTI, do not use V8 isolate by default
Custom type_info
and type_id<T>
are used in C++ class binder implementation. This allows to not force standard RTTI usage, which is turned off on many projects and in default Node.js addon configuration. Many thanks to @Manu343726 and @foonathan for their idea in https://github.com/Manu343726/ctti library.
A registery of bound classes is not stored in a V8 isolate by default from now. This is fine for typical use case, until we bind classes in multiple shared libraries (see #26). For the scenario with multiple shared libraries, define in all projects # V8PP_ISOLATE_DATA_SLOT
with V8 slot number to store the classes registry there.
Fixed an issue with destroy of weak references to v8::External
. They are used to store data with sizeof(data) > sizeof(void*)
, like lambda bindings (see #30).