diff options
author | Harald Fernengel <harald@trolltech.com> | 2009-08-20 13:35:04 (GMT) |
---|---|---|
committer | Harald Fernengel <harald@trolltech.com> | 2009-08-20 15:10:33 (GMT) |
commit | ec32395d96ffc90f775bbadb1e9ef6e64c69b5cd (patch) | |
tree | 69eac053cacf6212d33944eb8587b16db087337d /src | |
parent | 9af586d358f38817b62b621a40685aed4d9352b1 (diff) | |
download | Qt-ec32395d96ffc90f775bbadb1e9ef6e64c69b5cd.zip Qt-ec32395d96ffc90f775bbadb1e9ef6e64c69b5cd.tar.gz Qt-ec32395d96ffc90f775bbadb1e9ef6e64c69b5cd.tar.bz2 |
Add missing template typedefs
Reviewed-by: Thiago
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/tools/qshareddata.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/corelib/tools/qshareddata.h b/src/corelib/tools/qshareddata.h index dde6e88..8aace0f 100644 --- a/src/corelib/tools/qshareddata.h +++ b/src/corelib/tools/qshareddata.h @@ -69,6 +69,9 @@ private: template <class T> class QSharedDataPointer { public: + typedef T Type; + typedef T *pointer; + inline void detach() { if (d && d->ref != 1) detach_helper(); } inline T &operator*() { detach(); return *d; } inline const T &operator*() const { return *d; } @@ -127,6 +130,7 @@ template <class T> class QExplicitlySharedDataPointer { public: typedef T Type; + typedef T *pointer; inline T &operator*() const { return *d; } inline T *operator->() { return d; } |