You can find an example for this in d8.cc, refer to 
Shell::CreateEvaluationContext. I hope this helps for what you are trying 
to accomplish.

Yang

On Wednesday, July 25, 2012 4:25:40 PM UTC+2, beachdog wrote:
>
> I have a v8 program that will create a global object and a context, 
> creating a bunch of variables for functions and the like in the global 
> object.  Then, I will run some scripts in the context, which is going to 
> populate some more stuff into the global object.  Later, when I am done, I 
> would like to "reset" the state of the global back to just before I ran the 
> scripts, but after I hand-crafted it with the original set of global 
> objects.  I'm doing this because I will be running the same scripts over 
> and over, and I want to start from the same starting point, if you will.  
> Are there suggested ways of accomplishing this?
>

-- 
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users

Reply via email to