Details
-
Bug
-
Resolution: Done
-
P2: Important
-
6.3, 6.2
-
096a1c4f6e (qt/qtdeclarative/dev) 096a1c4f6e (qt/tqtc-qtdeclarative/dev)
Description
Consider
import QtQuick
Item {
id: root
Item {
id: root
}
}
qmllint will not warn about the duplicate id. Furthermore, when accessing properties that exist only one one of the types (and the "wrong" type is picked internally), we end up with rather confusing error messages:
import Qt QuickItem { id: root property var s Rectangle { id: root property var t: root.s } }
will result in the not so obvious
Warning: test.qml:9:30: Property "s" not found on type "Rectangle"
{{ property var t: root.s}}