summaryrefslogtreecommitdiffstats
path: root/tests/auto/qsharedpointer/qsharedpointer.pro
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-06-25 19:01:24 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-07-02 11:48:20 (GMT)
commit6f673e2cf55755a97aeb8971994ab9fc62fb794e (patch)
treef075a45e9fd6a18cfde96fd28069b719be743532 /tests/auto/qsharedpointer/qsharedpointer.pro
parentfb51a10ee0451274a430227566ae26efb2ac4474 (diff)
downloadQt-6f673e2cf55755a97aeb8971994ab9fc62fb794e.zip
Qt-6f673e2cf55755a97aeb8971994ab9fc62fb794e.tar.gz
Qt-6f673e2cf55755a97aeb8971994ab9fc62fb794e.tar.bz2
Experimental: allow QSharedPointer to be used with forward declarations that are declared in this file.
The one-definition rule allows the forward declaration appearing below to apply to code that was earlier. Therefore, if the compiler finds out how to delete the object, we can allow a QSharedPointer of a forward- declared-type. This means the actual problem is just a warning with g++. To catch the error, we need a separate .cpp file and I'd rather run this as an external test.
Diffstat (limited to 'tests/auto/qsharedpointer/qsharedpointer.pro')
-rw-r--r--tests/auto/qsharedpointer/qsharedpointer.pro9
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/auto/qsharedpointer/qsharedpointer.pro b/tests/auto/qsharedpointer/qsharedpointer.pro
index e329803..30c81cb 100644
--- a/tests/auto/qsharedpointer/qsharedpointer.pro
+++ b/tests/auto/qsharedpointer/qsharedpointer.pro
@@ -1,7 +1,8 @@
load(qttest_p4)
-
-SOURCES += tst_qsharedpointer.cpp
+SOURCES += tst_qsharedpointer.cpp \
+ forwarddeclaration.cpp \
+ forwarddeclared.cpp
QT = core
-DEFINES += SRCDIR=\\\"$$PWD\\\"
-
+DEFINES += SRCDIR=\\\"$$PWD/\\\"
include(externaltests.pri)
+HEADERS += forwarddeclared.h