Details
-
Sub-task
-
Resolution: Done
-
P2: Important
-
None
-
None
Description
This is a very intrusive change that obviously stands no chance of being upstreamed as-is.
Changing JavaScriptCore to being able to customize the type of object that's constructed by the new operator is technically feasible, but is likely to have performance impact.
If the patch is dropped, the impact will be that it's no longer possible to change the class (QScriptValue::setClass()) of objects created by "new Object" from JS, only those created by QScriptEngine::newObject().
This will impact the QtScript bindings generator examples, but we can change those. I don't know if any customers rely on it. They would have to switch to e.g. calling a "Qt.newObject" function from JS that creates an object of type QScriptObject.