How to create a Handle<String> that contains the code to compile in compiler.cc ?

13 views
Skip to first unread message

belgia...@gmail.com

unread,
Jan 25, 2013, 9:47:02 AM1/25/13
to v8-u...@googlegroups.com
Hello,

I am doing some work in compiler.cc, I have modified the code that needs to be compile by creating a new char* variable that contains the changed code.


I am having problems compiling the new code instead of the old one, this is what I tried:

I am currently trying to create a new Handle<String> that contains the original piece of code (so the problem isn't how I change the code),

I'm doing this with the code: Handle<String> testing = isolate->factory()->NewStringFromAscii(CStrVector(JSCodeAsCharArray));


I am working with V8 as part of chromium, and when I recompiled chromium with the modified compiler.cc file it compiled without problems,

but when I entered chromium I got an error on every page (including the new tab window).


Can someone please help me out ? I failed to understand how to take the JS code in the form of char* and create the Handle<String> that contains this code.


Any help is greatly appreciated!

Regards,

Belgi

Yang Guo

unread,
Feb 7, 2013, 9:44:20 AM2/7/13
to v8-u...@googlegroups.com
It would help a lot if you attached the error message, debug outputs if available and maybe the diff of what you changed.
Reply all
Reply to author
Forward
0 new messages