diff options
author | Zeno Albisser <zeno.albisser@nokia.com> | 2010-02-18 10:16:26 (GMT) |
---|---|---|
committer | Zeno Albisser <zeno.albisser@nokia.com> | 2010-02-18 10:17:08 (GMT) |
commit | 4971430290ecb11012ef5cbf8ef041da0ec3a824 (patch) | |
tree | 69c1ddb4ef26079e1a0a44446fa3cdecc24c68ef | |
parent | cdf4701f442149546043b155cddcc53116875f1c (diff) | |
download | Qt-4971430290ecb11012ef5cbf8ef041da0ec3a824.zip Qt-4971430290ecb11012ef5cbf8ef041da0ec3a824.tar.gz Qt-4971430290ecb11012ef5cbf8ef041da0ec3a824.tar.bz2 |
Revert "Added note to make QList destructor virtual in version 5"
Virtual functions should not be used with copyable types due to
slicing.
This reverts commit c1db6c2c5a3bbe96a628207af169a032d535426f.
-rw-r--r-- | src/corelib/tools/qlist.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/tools/qlist.h b/src/corelib/tools/qlist.h index a549f2f..1ad7528 100644 --- a/src/corelib/tools/qlist.h +++ b/src/corelib/tools/qlist.h @@ -112,7 +112,7 @@ class QList public: inline QList() : d(&QListData::shared_null) { d->ref.ref(); } inline QList(const QList<T> &l) : d(l.d) { d->ref.ref(); if (!d->sharable) detach_helper(); } - ~QList(); // ### Qt5: make this destructor virtual + ~QList(); QList<T> &operator=(const QList<T> &l); bool operator==(const QList<T> &l) const; inline bool operator!=(const QList<T> &l) const { return !(*this == l); } |