diff options
author | Stephen Kelly <stephen.kelly@kdab.com> | 2013-12-12 17:30:44 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-12-12 19:12:28 +0100 |
commit | 444914839541154b0927cd1d49890677b8368148 (patch) | |
tree | c5645ed127f9266d5344b35c5dd9f5f7daddd424 /src | |
parent | 70c70aef7ee35009bb00614fdd6d4d282f9c4e57 (diff) |
QMetaType: Rename template type of type-erased iterator operations.
This struct is a specialization for the case that the const_iterator
is a pointer to the value type. Reflect that in the type name.
Change-Id: I0a4ac03840658056285080860baec8313746c71c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/kernel/qmetatype.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/corelib/kernel/qmetatype.h b/src/corelib/kernel/qmetatype.h index a2e6960949..06adf7cffd 100644 --- a/src/corelib/kernel/qmetatype.h +++ b/src/corelib/kernel/qmetatype.h @@ -805,17 +805,17 @@ struct IteratorOwner return &*it; } }; -template<typename const_iterator> -struct IteratorOwner<const const_iterator*> +template<typename value_type> +struct IteratorOwner<const value_type*> { - static void assign(void **ptr, const const_iterator *iterator ) + static void assign(void **ptr, const value_type *iterator ) { - *ptr = const_cast<const_iterator*>(iterator); + *ptr = const_cast<value_type*>(iterator); } static void advance(void **iterator, int step) { - const_iterator *it = static_cast<const_iterator*>(*iterator); + value_type *it = static_cast<value_type*>(*iterator); std::advance(it, step); *iterator = it; } @@ -829,7 +829,7 @@ struct IteratorOwner<const const_iterator*> return *iterator; } - static const void *getData(const const_iterator *it) + static const void *getData(const value_type *it) { return it; } |