From 5860c9c12c1c948ce1498da30581bfd5b9c05988 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Olivier=20De=20Canni=C3=A8re?= Date: Thu, 11 May 2023 09:52:24 +0200 Subject: qmllint: Separate logic by import type in QQmlJSImportVisitor::visit This patch reorganizes the logic of the import visitor to deal with each import type (paths, qrc: urls, file: urls) separately. This reorganisation fixes QTBUG-108803 which happened because "qrc:" imports were being treated as paths leading to things like ":/untitled/qrc:/untitled/components". Fixes: QTBUG-108803 Pick-to: 6.5 Change-Id: I5af20d10c533455215895be66b5cd98a977fd18a Reviewed-by: Ulf Hermann --- tests/auto/qml/qmllint/data/untitled/main.qml | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 tests/auto/qml/qmllint/data/untitled/main.qml (limited to 'tests/auto/qml/qmllint/data/untitled/main.qml') diff --git a/tests/auto/qml/qmllint/data/untitled/main.qml b/tests/auto/qml/qmllint/data/untitled/main.qml new file mode 100644 index 0000000000..cf8980ab55 --- /dev/null +++ b/tests/auto/qml/qmllint/data/untitled/main.qml @@ -0,0 +1,9 @@ +pragma Strict + +import QtQuick +import 'qrc:/untitled/components' as C + +Window { + id: root + C.Foo {} +} -- cgit v1.2.1