File tree Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -329,6 +329,11 @@ JLCXX_MODULE init_test_module(jlcxx::Module& mod)
329329 mod.method (" unmark_boxed" , [&] () { jlcxx::unprotect_from_gc (marked_value); });
330330
331331 mod.method (" open" , [] (const std::string& s) { return s; });
332- }
332+
333+ mod.method (" boolref" , [] (bool & b)
334+ {
335+ b = !b;
336+ });
337+ }
333338
334339}
Original file line number Diff line number Diff line change 1515
1616#define JLCXX_VERSION_MAJOR 0
1717#define JLCXX_VERSION_MINOR 7
18- #define JLCXX_VERSION_PATCH 1
18+ #define JLCXX_VERSION_PATCH 2
1919
2020// From https://stackoverflow.com/questions/5459868/concatenate-int-to-string-using-c-preprocessor
2121#define __JLCXX_STR_HELPER (x ) #x
Original file line number Diff line number Diff line change @@ -172,7 +172,9 @@ inline CppT* extract_pointer_nonull(const WrappedCppPtr& p)
172172{
173173 if (p.voidptr == nullptr )
174174 {
175- throw std::runtime_error (" C++ object was deleted" );
175+ std::stringstream errorstr;
176+ errorstr << " C++ object of type " << typeid (CppT).name () << " was deleted" ;
177+ throw std::runtime_error (errorstr.str ());
176178 }
177179 return extract_pointer<CppT>(p);
178180}
@@ -667,7 +669,6 @@ BoxedValue<T> julia_owned(T* cpp_ptr)
667669// / Base class to specialize for conversion to Julia
668670// C++ wrapped types are in fact always returned as a pointer wrapped in a struct, so to avoid memory management issues with the wrapper itself
669671// we always return the wrapping struct by value
670- // template<typename T, typename TraitT=mapping_trait<typename std::remove_pointer<typename std::remove_reference<T>::type>::type>>
671672template <typename T, typename TraitT=mapping_trait<T>>
672673struct ConvertToJulia
673674{
You can’t perform that action at this time.
0 commit comments