Closed jdm closed 7 years ago
r? @nox
It is currently not possible to initialize SpiderMonkey multiple times (that is, calling JS_Init, then other JSAPI methods, then JS_ShutDown in that order, then doing so again). This restriction may eventually be lifted.
https://developer.mozilla.org/en-US/docs/Mozilla/Projects/SpiderMonkey/JSAPI_reference/JS_ShutDown
Yes, this PR is made under the assumption that we do not create new Runtime objects after all existing Runtime objects have been dropped. I could make that explicit by panicking in Runtime::new or making it return a Result if you'd like.
Yeah, such assumptions are bad in safe code.
Fixed.
@bors-servo r+
@bors-servo: r=nox
:pushpin: Commit b991ef3 has been approved by nox
:hourglass: Testing commit b991ef317d6d5cbb5fc8ebbee3af04fd1439796f with merge 7f380abcbe02604cca5f28ff4175dff2a4f5555e...
:broken_heart: Test failed - status-travis
:sunny: Test successful - status-appveyor, status-travis Approved by: nox Pushing 7f380abcbe02604cca5f28ff4175dff2a4f5555e to master...
This PR introduced a breaking change to rust-mozjs api.
Is there any publishing model you use, to help lock projects on certain version?
Is there any publishing model you use, to help lock projects on certain version?
Not yet: mozjs shouldn't at all be considered stable at this point. Once it gets closer to 1.0, it'll start following semantic versioning.
that is good to know, thanks. Is there anyway to track your progress? How far away you are from 1.0?
I would not bet on 1.0 being declared this year.
I would not bet on 1.0 being declared this year.
Agreed, it's quite unlikely it'll get stabilized this year. The API is very likely to undergo substantial changes, with stabilization beginning late this year or in 2018.
This will enable better investigation of Servo's shutdown behaviour, since currently all of the JS helper threads just sit there until process exit.
This change is