aboutsummaryrefslogtreecommitdiffstats
path: root/src/qmlcompiler/qqmljsimportvisitor.cpp
diff options
context:
space:
mode:
authorSami Shalayel <sami.shalayel@qt.io>2024-07-26 15:16:20 +0200
committerSami Shalayel <sami.shalayel@qt.io>2024-07-30 17:06:43 +0200
commit85e47ec482072531d59c40555dea4bd5df5e63dc (patch)
treeebaacd528e59073789ad388e8cd98ae7a7b1e1b3 /src/qmlcompiler/qqmljsimportvisitor.cpp
parent698110b42fccbb75943f5972cff415d1502f85cd (diff)
qmllint: unify missing property warning
Currently, there are two different warning formulations when binding something to a property that does not exist. Unify them so that they don't need to be documented twice by replacing ``` Binding assigned to XXX, but no property XXX exists in the current element. ``` with the warning ``` Property X does not exist ``` Also, from a user perspective it does not make sense to have different warnings for "assigning an object to a property that does not exist" and "assigning a script expression to a property that does not exist". Pick-to: 6.7 6.8 Task-number: QTBUG-118112 Change-Id: Iec2b5717709239d4b8fa45793ee16c6e1cc39a24 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qmlcompiler/qqmljsimportvisitor.cpp')
-rw-r--r--src/qmlcompiler/qqmljsimportvisitor.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/qmlcompiler/qqmljsimportvisitor.cpp b/src/qmlcompiler/qqmljsimportvisitor.cpp
index 2b4687da77..e52a1c9a1e 100644
--- a/src/qmlcompiler/qqmljsimportvisitor.cpp
+++ b/src/qmlcompiler/qqmljsimportvisitor.cpp
@@ -951,8 +951,7 @@ void QQmlJSImportVisitor::processPropertyBindings()
}
}
- m_logger->log(QStringLiteral("Binding assigned to \"%1\", but no property \"%1\" "
- "exists in the current element.")
+ m_logger->log(QStringLiteral("Property \"%1\" does not exist.")
.arg(name),
qmlMissingProperty, location, true, true, fixSuggestion);
continue;