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

qmllint crashes in a combination with ListModel

    XMLWordPrintable

    Details

    • Commits:
      a350af2eb675b8a9fd1489437b3c465b6fa51701 (qt/qtdeclarative/dev)

      Description

      Issue case:

      test.qml
      import QtQuick
      
      ListModel {
          id: listModel
      
          property var test: UnknownType {
              property int test2: Unknown.value;
          }
      }
      
      $ qtbase/bin/qmllint qmllint-issue/test.qml
      Warning: qmllint-issue/test.qml: UnknownType was not found. Did you add all import paths?
      ASSERT: "!m_currentScope->baseType().isNull()" in file /home/noelma/work/qt-git/qtdeclarative/src/qmlcompiler/qqmljstypepropagator.cpp, line 276
      Aborted (core dumped)
      

      Other cases for reference (no crashes):

      test2.qml
      import QtQuick
      
      Item {
          ListModel {
              id: listModel
          }
      
          property var test: UnknownType {
              property int test2: Unknown.value;
          }
      }
      
      $ qtbase/bin/qmllint qmllint-issue/test2.qml
      Warning: qmllint-issue/test2.qml: UnknownType was not found. Did you add all import paths?
      Warning: qmllint-issue/test2.qml:9:29: Unqualified access
              property int test2: Unknown.value;
                                  ^^^^^^^
      
      test3.qml
      import QtQuick
      
      Item {
          id: item
      
          property var test: UnknownType {
              property int test2: Unknown.value;
          }
      }
      
      $ qtbase/bin/qmllint qmllint-issue/test3.qml
      Warning: qmllint-issue/test3.qml: UnknownType was not found. Did you add all import paths?
      Warning: qmllint-issue/test3.qml:7:29: Unqualified access
              property int test2: Unknown.value;
                                  ^^^^^^^
      

        Attachments

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

          Activity

            People

            Assignee:
            max.goldstein Maximilian Goldstein
            Reporter:
            jaeyoon.jung Jaeyoon Jung
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes