Permalink
Browse files

Return reference to peristent rather than local objects from C++ obje…

…ct wrappers.
  • Loading branch information...
1 parent 11335bc commit 1efc4a6b7bc8a35483919d770d6123f3a42eea5b jpike committed Dec 11, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/vu8/Class.hpp
View
4 src/vu8/Class.hpp
@@ -144,7 +144,7 @@ class ClassSingleton
obj->SetPointerInInternalField(0, wrap);
obj.MakeWeak(wrap, &self::MadeWeak);
- return scope.Close(localObj);
+ return scope.Close(obj);
}
ClassSingleton()
@@ -239,7 +239,7 @@ struct Class {
obj->SetPointerInInternalField(0, ext);
obj.MakeWeak(ext, &singleton_t::MadeWeak);
- return scope.Close(localObj);
+ return scope.Close(obj);
}
template <class U, class V>

0 comments on commit 1efc4a6

Please sign in to comment.