Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-28487

ErrAliasReferRoot and WarnAliasReferRootHierarchy are only shown when code has correct order

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P4: Low
    • None
    • Qt Creator 9.0.0-rc1
    • Quick / QML Support
    • None

    Description

      This is throwing the ErrAliasReferRoot error

      Item {
          id: root
          property alias test: root
      }
      

      but this isn't

      Item {
          property alias test: root
          id: root
      }
      

      The error check in qmljscheck currently depends on the order in which property and id definitions are. If the Item doesn't start with an id the check for alias referencing root id isn't working as the id stack is empty at the point of checking.

      Attachments

        Issue Links

          Activity

            People

              qtqmlteam Qt Qml Team User
              henning Henning Gründl
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: