aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/shared
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@qt.io>2020-02-27 10:49:14 +0100
committerSimon Hausmann <simon.hausmann@qt.io>2020-03-02 10:35:50 +0100
commit8ab237edf170f5b0482dccf5169868e5c7c47771 (patch)
treecca2d3faa0a8553a452d9139ac7442c3da25c0f8 /tests/auto/shared
parentd8f6f41c334d14c4712b1dc16554f80bb1290e24 (diff)
Restore offset/length in QQmlJS::DiagnosticMessage
This is needed in a few places outside of declarative, so this change restores the loc member in DiagnosticMessage and moves QQmlJS::AST::SourceLocation into common's QQmlJS namespace/directory. QQmlError is unaffected and retains only line/column. Amends d4d197d06279f9257647628f7e1ccc9ec763a6bb Change-Id: Ifb9d344228e3c6e9e26fc4fe112686f9336ea2b2 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'tests/auto/shared')
-rw-r--r--tests/auto/shared/qqmljsastdumper.cpp2
-rw-r--r--tests/auto/shared/qqmljsastdumper.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/shared/qqmljsastdumper.cpp b/tests/auto/shared/qqmljsastdumper.cpp
index 8a50e021f6..5da6be6bd0 100644
--- a/tests/auto/shared/qqmljsastdumper.cpp
+++ b/tests/auto/shared/qqmljsastdumper.cpp
@@ -216,7 +216,7 @@ QString AstDumper::qs(const QStringRef &s) {
return qs(s.toString());
}
-QString AstDumper::loc(const AST::SourceLocation &s) {
+QString AstDumper::loc(const SourceLocation &s) {
if (noLocations() || !s.isValid())
return QLatin1String("\"\"");
else {
diff --git a/tests/auto/shared/qqmljsastdumper.h b/tests/auto/shared/qqmljsastdumper.h
index d8d19e351d..5e46e516f0 100644
--- a/tests/auto/shared/qqmljsastdumper.h
+++ b/tests/auto/shared/qqmljsastdumper.h
@@ -91,7 +91,7 @@ public:
QString qs(const char *s);
QString qs(const QStringRef &s);
- QString loc(const AST::SourceLocation &s);
+ QString loc(const SourceLocation &s);
QString boolStr(bool v);