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

REG: Local types in QML no longer take precedence

    XMLWordPrintable

Details

    • All

    Description

      Found when testing pure-qml example in Qt Wayland. The example has a local type called "Screen" and instantiates this in main.qml. In Qt 5, this worked fine, but in Qt 6, it now gives the error

      qrc:/qml/main.qml:57:5: Screen can only be used via the attached property.
      

      Changing the name to "CompositorScreen" fixes the issue, so it is probably resolving to the built-in type instead of the local type.

      Attachments

        Issue Links

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

          Activity

            People

              ulherman Ulf Hermann
              esabraha Eskil Abrahamsen Blomfeldt
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes