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

Rewrite binding handling in QQmlJSScope and friends

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Reported
    • Priority: P2: Important
    • Resolution: Unresolved
    • Affects Version/s: 6.3
    • Fix Version/s: None
    • Component/s: QML: Tooling
    • Labels:

      Description

      The way we treat bindings is just wrong.

      1. QQmlJSMetaPropertyBinding must really be a union of different things. This should be done this way at least for the sake of data separation (it might be hard to do it nicely, so let's leave it as is for now)
      2. QQmlJSScope::ownPropertyBinding() must be plural and return an equal_range from QMultiHash: we can have multiple bindings on the same property. Exactly one binding is a corner case, do not make it the default case
      3. QQmlJSMetaPropertyBinding must really not be copied:
      • we can leave copy semantics for the sake of simplicity
      • the point is to never construct a new binding from an existing one, this leads (at present) to weird side effects (e.g. a binding has both an interceptor and a value source set). [1] partially addresses this

      [1]: https://codereview.qt-project.org/c/qt/qtdeclarative/+/381555

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            qtqmlteam Qt Qml Team User
            Reporter:
            agolubev Andrei Golubev
            PM Owner:
            Vladimir Minenko Vladimir Minenko
            RnD Owner:
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:

                Gerrit Reviews

                There are no open Gerrit changes