[v8-users] Re: Using Context::Scope with new Persistent

2013-09-03 Thread Dan Carney


 1st question is why?  It's seems like needless complexity.


It's fundamentally unsafe to pass a persistent to a v8 api call.  This is 
why Persistent no longer extends Handle.
 

 2nd question is what is the correct way to do this?


LocalWhateverType::New(isolate, persistent);

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


[v8-users] Re: New feature: handle eternalization

2013-09-03 Thread Mike Moening
Found another bug in Eternal.

The IsEmpty() method is returning an inverted value.

Broken code:
V8_INLINE(bool IsEmpty()) { return index_ != kInitialValue; }

Should be:
V8_INLINE(bool IsEmpty()) { return index_ == kInitialValue; }

Here is the bug report:
https://code.google.com/p/v8/issues/detail?id=2870

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


[v8-users] Re: Using Context::Scope with new Persistent

2013-09-03 Thread Bit Cortex
Hi Dan,

In the latest stable source, that Local::New method is marked // 
TODO(dcarney): remove before cutover. Does that mean the new API is still 
not finalized and the method is likely to go away?

Thanks!

On Tuesday, September 3, 2013 2:56:12 AM UTC-4, Dan Carney wrote:


 1st question is why?  It's seems like needless complexity.


 It's fundamentally unsafe to pass a persistent to a v8 api call.  This is 
 why Persistent no longer extends Handle.
  

 2nd question is what is the correct way to do this?


 LocalWhateverType::New(isolate, persistent);



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