summaryrefslogtreecommitdiffstats
path: root/tests/auto/linguist
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-09-09 18:34:18 +0200
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2010-09-10 16:31:24 +0200
commitc2d6eb9dca7546bbe8d9c6c62db683615e4b23a7 (patch)
treec3620e8161ef6afd38c0f9eb01271587c667fe8f /tests/auto/linguist
parent94584dcdd02e2c08e05ca75f6f8b460c0c320947 (diff)
don't let operator overloads confuse us
Task-number: QTBUG-11426
Diffstat (limited to 'tests/auto/linguist')
-rw-r--r--tests/auto/linguist/lupdate/testdata/good/parsecpp/main.cpp16
-rw-r--r--tests/auto/linguist/lupdate/testdata/good/parsecpp/project.ts.result8
2 files changed, 24 insertions, 0 deletions
diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp/main.cpp b/tests/auto/linguist/lupdate/testdata/good/parsecpp/main.cpp
index f58f932391..c56ba7cb36 100644
--- a/tests/auto/linguist/lupdate/testdata/good/parsecpp/main.cpp
+++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp/main.cpp
@@ -302,3 +302,19 @@ static inline QString message2()
}
}
+
+
+
+// QTBUG-11426: operator overloads
+class LotsaFun : public QObject
+{
+ Q_OBJECT
+public:
+ int operator<<(int left, int right);
+};
+
+int LotsaFun::operator<<(int left, int right)
+{
+ tr("this is inside operator<<");
+ return left << right;
+}
diff --git a/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.ts.result b/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.ts.result
index 7ac318e685..1a6d551a1e 100644
--- a/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.ts.result
+++ b/tests/auto/linguist/lupdate/testdata/good/parsecpp/project.ts.result
@@ -141,6 +141,14 @@ backslashed \ stuff.</source>
</message>
</context>
<context>
+ <name>LotsaFun</name>
+ <message>
+ <location filename="main.cpp" line="318"/>
+ <source>this is inside operator&lt;&lt;</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
<name>Plurals, QCoreApplication</name>
<message numerus="yes">
<location filename="main.cpp" line="81"/>