Since we're just about to bump our (minor) revision number I thought
I'd use the opportunity to make some incompatible changes to the API.
They're pretty small changes but may still break your code.  Here's an
overview and some tips on how to fix code breakage.  And remember: if
you don't like us breaking your code like this you can use one of the
stable tags under tags/<revision>.

A WeakReferenceCallback now takes a Persistent<Value> where it used to
take a Persistent<Object>.  If you use WeakReferenceCallback this
change will cause your code to break.  It's easy to fix though: just
change the signature of your weak reference callback and insert a cast
anywhere you assume that the argument is an Object.

Message::GetScriptResourceName now returns a Handle<Value> rather than
a Handle<String>.  In most cases the returned value will be converted
to a C string for error reporting, for instance using a
String::Utf8Value which also works on non-string objects, so in that
case there shouldn't be a problem.  However, if you assume that the
returned value is a string you can just do an explicit check -- and if
your code already checks if the returned handle is empty then that
check can be replaced with the string check since the result will now
never be empty (except if the vm has crashed).

Message::GetSourceData() has been removed.  Use GetScriptResourceName
instead since it now behaves exactly like GetSourceData used to.

Message::GetUnderline() has been removed.  See the ReportException
function in samples/shell.cc for how to implement a replacement.


-- Christian

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

Reply via email to