Reviewers: dcarney, Sven Panne,

Message:
dcarney@, ptal. I was under the impression that v8 is already
post-handlepocalyptic, but doesn't seem so. Maybe this was missed because the
code is inside a template which was not instantiated by tests?

Description:
Fix ReturnValue::Set.

It was using Persistent::operator* which will be removed.

BUG=

Please review this at https://codereview.chromium.org/15848010/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files:
  M include/v8.h


Index: include/v8.h
diff --git a/include/v8.h b/include/v8.h
index 5526705c84269523ab7eafd144ab26dd12aa594e..0c5e63e5691e828311e88cc37459aea16b3dad08 100644
--- a/include/v8.h
+++ b/include/v8.h
@@ -5641,7 +5641,9 @@ void ReturnValue<T>::Set(const Persistent<S>& handle) {
   if (V8_UNLIKELY(handle.IsEmpty())) {
     SetUndefined();
   } else {
-    *value_ = *reinterpret_cast<internal::Object**>(*handle);
+    const Handle<S>* handlePointer =
+        reinterpret_cast<const Handle<S>*>(&handle);
+    *value_ = *reinterpret_cast<internal::Object**>(**handlePointer);
   }
 }



--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to