Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-15571

QtScript: Deprecate APIs that reflect implementation of old ("classic") back-end

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Invalid
    • Affects Version/s: None
    • Fix Version/s: 4.8.0
    • Component/s: Qt Script
    • Labels:
      None
    • Technical Risk:
      Normal

      Description

      Parts of the QtScript API unfortunately reflect the implementation of the old (Qt 4.5) back-end.
      This makes it difficult to implement the complete API (and behavior) on top of other JavaScript engines, such as JavaScriptCore (JSC) and V8.

      Currently we are in the situation that we have to maintain our own patches on top of JSC (see QTBUG-11467) in order to fully support our API, and it will not be possible to upstream all these patches.
      Therefore, we should start deprecating the relevant API, and, where applicable, propose the "right" way to do it with existing API, or introduce new API that isn't bound to a particular implementation/back-end.

      In many cases, API can't be obsoleted (as in adding a qdoc \obsolete tag) until a replacement API is available. Until that happens, the deprecated API should at least be clearly marked in the docs, advising users to refrain from using it in new code.

        Attachments

          Issue Links

          1.
          Deprecate QScriptEngine::setAgent() and QScriptEngineAgent Sub-task Closed Kent Hansen (Inactive)
          2.
          Deprecate QScriptEngine::setProcessEventsInterval() Sub-task Closed Kent Hansen (Inactive)
          3.
          Deprecate QScriptContext::activationObject()/setActivationObject() Sub-task Closed Kent Hansen (Inactive)
          4.
          Deprecate QScriptEngine::setGlobalObject() Sub-task Closed Kent Hansen (Inactive)
          5.
          Deprecate QScriptEngine::newQObject() overload that takes existing script object as argument Sub-task Closed Kent Hansen (Inactive)
          6.
          Deprecate QScriptEngine::newVariant() overload that takes existing script object as argument Sub-task Closed Kent Hansen (Inactive)
          7.
          Deprecate QScriptEngine::currentContext() Sub-task Closed Kent Hansen (Inactive)
          8.
          Deprecate QScriptEngine::{push,pop}Context() Sub-task Closed Kent Hansen (Inactive)
          9.
          Deprecate QScriptValue::toUInt16() Sub-task Closed Kent Hansen (Inactive)
          10.
          Deprecate QScriptValue::setScriptClass() Sub-task Closed Kent Hansen (Inactive)
          11.
          Deprecate QScriptContextInfo Sub-task Closed Kent Hansen (Inactive)
          12.
          Deprecate QScriptContext::argumentsObject() Sub-task Closed Kent Hansen (Inactive)
          13.
          Deprecate QScriptEngine::isEvaluating() Sub-task Closed Kent Hansen (Inactive)
          14.
          Deprecate QScriptContext::setThisObject() Sub-task Closed Kent Hansen (Inactive)
          15.
          Deprecate script syntax checking API Sub-task Closed Kent Hansen (Inactive)
          16.
          Consider deprecating QScriptEngine::reportAdditionalMemoryCost() Sub-task Closed Kent Hansen (Inactive)
          17.
          Deprecate QScriptValue::UserRange Sub-task Closed Kent Hansen (Inactive)
          18.
          Deprecate QScriptValue::QObjectMember Sub-task Closed Kent Hansen (Inactive)
          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              Assignee:
              kenthans Kent Hansen (Inactive)
              Reporter:
              kenthans Kent Hansen (Inactive)
              Votes:
              4 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes