This PR contains a few updates that will be required for V8 11.x but should be harmless to apply before the migration. (It should not be very risky to apply them to main, as well.)
Switch from CreationContext to GetCreationContextChecked: the CreationContext API goes away in 11.x, but the replacement already exists in 10.x, so we can go ahead and use it.
Set V8 flags before initializing V8: setting the flags after initialization will crash in 11.x. In 10.x the flags can be set either before or after.
Use CPPGC-compatible platform: we'll be migrating ObjectManager to use CPPGC, which requires changing the V8 Platform to use the CPPGC default platform. This already works fine in 10.x and should be harmless.
Description
This PR contains a few updates that will be required for V8 11.x but should be harmless to apply before the migration. (It should not be very risky to apply them to
main
, as well.)CreationContext
toGetCreationContextChecked
: theCreationContext
API goes away in 11.x, but the replacement already exists in 10.x, so we can go ahead and use it.More details in the individual commit messages.
Does your pull request have unit tests?
No tests. The PR doesn't introduce any new functionality so the existing tests should all continue passing.