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

Inline component causes stack overflow with QQuickTest (endless recursion)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Duplicate
    • Affects Version/s: 5.15.2
    • Fix Version/s: 5.15.4, 6.1.1, 6.2
    • Component/s: Testing: QuickTest
    • Labels:
    • Environment:
      Windows 10 x64
    • Platform/s:
      All

      Description

      The following code causes endless recursion stack overflow crash. This only happens testing QML in QtQuickTest. Attached is a example project of the crash.

      import QtQuick 2.15
      import QtTest 1.0
      
      Item {
          width: 300
          height: 300
      
          component MyItem : Rectangle {
              width: 100
              height: 100
              color: "red"
          }
      
          MyItem {
      
          }
      
          TestCase {
              name: "my_test_3000"
      
              function test_case1() {
                  compare(1 + 1, 2, "sanity check");
                  verify(true);
              }
          }
      }
      
      

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              qt.team.quick.subscriptions Qt Quick and Widgets Team
              Reporter:
              vpicaver Philip Schuchardt
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes