From 0e9cae00ef660b51955c7c9abfa7eb148d8bfab0 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Sun, 28 Dec 2025 21:41:52 +0900 Subject: Remove TQ_INLINE_TEMPLATES define. inline' is redundant in function template definitions, except for specific template specialization Signed-off-by: Michele Calgaro --- src/kernel/tqobjectdefs.h | 2 +- src/kernel/tqscriptengine.cpp | 2 +- src/tools/tqglobal.h | 12 ----------- src/tools/tqmap.h | 46 +++++++++++++++++++++---------------------- src/tools/tqpair.h | 6 +++--- src/tools/tqtl.h | 10 +++++----- src/tools/tqvaluelist.h | 40 ++++++++++++++++++------------------- src/tools/tqvaluevector.h | 24 +++++++++++----------- 8 files changed, 65 insertions(+), 77 deletions(-) (limited to 'src') diff --git a/src/kernel/tqobjectdefs.h b/src/kernel/tqobjectdefs.h index 69d44d6bc..871ba47a3 100644 --- a/src/kernel/tqobjectdefs.h +++ b/src/kernel/tqobjectdefs.h @@ -169,6 +169,6 @@ TQ_EXPORT void *tqt_find_obj_child( TQObject *, const char *, const char * ); TQ_EXPORT void *tqt_inheritedBy( TQMetaObject *super, const TQObject *cls ); template -TQ_INLINE_TEMPLATES T tqt_cast(const TQObject *object) +T tqt_cast(const TQObject *object) { return (T)tqt_inheritedBy( ((T)0)->staticMetaObject(), object ); } #endif // TQOBJECTDEFS_H diff --git a/src/kernel/tqscriptengine.cpp b/src/kernel/tqscriptengine.cpp index 963d2bb3b..e9431463c 100644 --- a/src/kernel/tqscriptengine.cpp +++ b/src/kernel/tqscriptengine.cpp @@ -98,7 +98,7 @@ private: }; template -TQ_INLINE_TEMPLATES TQVarLengthArray::TQVarLengthArray(int asize) +TQVarLengthArray::TQVarLengthArray(int asize) : s(asize) { if (s > Prealloc) { ptr = reinterpret_cast(malloc(s * sizeof(T))); diff --git a/src/tools/tqglobal.h b/src/tools/tqglobal.h index 15c700058..6120dbf45 100644 --- a/src/tools/tqglobal.h +++ b/src/tools/tqglobal.h @@ -220,7 +220,6 @@ # define Q_CC_MSVC /* proper support of bool for _MSC_VER >= 1100 */ # define Q_CANNOT_DELETE_CONSTANT -# define TQ_INLINE_TEMPLATES inline /* Visual C++.Net issues for _MSC_VER >= 1300 */ # if _MSC_VER >= 1300 # define Q_CC_MSVC_NET @@ -314,7 +313,6 @@ # if __xlC__ < 0x400 # define Q_NO_USING_KEYWORD # define TQ_TYPENAME -# define TQ_INLINE_TEMPLATES inline # define Q_CANNOT_DELETE_CONSTANT # endif @@ -361,10 +359,6 @@ /* The UnixWare 7 UDK compiler is based on EDG and does define __EDG__ */ # elif defined(__USLC__) && defined(__SCO_VERSION__) # define Q_CC_USLC -/* The latest UDK 7.1.1b does not need this, but previous versions do */ -# if !defined(__SCO_VERSION__) || (__SCO_VERSION__ < 302200010) -# define TQ_INLINE_TEMPLATES inline -# endif # define Q_NO_USING_KEYWORD /* ### check "using" status */ /* Never tested! */ @@ -378,7 +372,6 @@ # define Q_CC_MIPS # if defined(_MIPS_SIM) && (_MIPS_SIM == _ABIO32) /* o32 ABI */ # define TQ_TYPENAME -# define TQ_INLINE_TEMPLATES inline # elif defined(_COMPILER_VERSION) && (_COMPILER_VERSION < 730) /* 7.2 */ # define TQ_TYPENAME # endif @@ -393,7 +386,6 @@ # define Q_CC_USLC # define TQ_TYPENAME # define Q_NO_USING_KEYWORD -# define TQ_INLINE_TEMPLATES inline /* Never tested! */ #elif defined(__HIGHC__) @@ -732,10 +724,6 @@ TQ_EXPORT int qWinVersion(); #define QT_WA_INLINE( uni, ansi ) ( uni ) #endif -#ifndef TQ_INLINE_TEMPLATES -# define TQ_INLINE_TEMPLATES -#endif - #ifndef TQ_TYPENAME # define TQ_TYPENAME typename #endif diff --git a/src/tools/tqmap.h b/src/tools/tqmap.h index 8689e17ee..5f594c068 100644 --- a/src/tools/tqmap.h +++ b/src/tools/tqmap.h @@ -167,7 +167,7 @@ public: }; template -TQ_INLINE_TEMPLATES int TQMapIterator::inc() +int TQMapIterator::inc() { TQMapNodeBase* tmp = node; if ( tmp->right ) { @@ -188,7 +188,7 @@ TQ_INLINE_TEMPLATES int TQMapIterator::inc() } template -TQ_INLINE_TEMPLATES int TQMapIterator::dec() +int TQMapIterator::dec() { TQMapNodeBase* tmp = node; if (tmp->color == TQMapNodeBase::Red && @@ -283,7 +283,7 @@ public: }; template -TQ_INLINE_TEMPLATES int TQMapConstIterator::inc() +int TQMapConstIterator::inc() { TQMapNodeBase* tmp = node; if ( tmp->right ) { @@ -304,7 +304,7 @@ TQ_INLINE_TEMPLATES int TQMapConstIterator::inc() } template -TQ_INLINE_TEMPLATES int TQMapConstIterator::dec() +int TQMapConstIterator::dec() { TQMapNodeBase* tmp = node; if (tmp->color == TQMapNodeBase::Red && @@ -432,14 +432,14 @@ protected: template -TQ_INLINE_TEMPLATES TQMapPrivate::TQMapPrivate() { +TQMapPrivate::TQMapPrivate() { header = new Node; header->color = TQMapNodeBase::Red; // Mark the header header->parent = 0; header->left = header->right = header; } template -TQ_INLINE_TEMPLATES TQMapPrivate::TQMapPrivate( const TQMapPrivate< Key, T >* _map ) : TQMapPrivateBase( _map ) { +TQMapPrivate::TQMapPrivate( const TQMapPrivate< Key, T >* _map ) : TQMapPrivateBase( _map ) { header = new Node; header->color = TQMapNodeBase::Red; // Mark the header if ( _map->header->parent == 0 ) { @@ -454,7 +454,7 @@ TQ_INLINE_TEMPLATES TQMapPrivate::TQMapPrivate( const TQMapPrivate< Key, } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::NodePtr TQMapPrivate::copy( TQ_TYPENAME TQMapPrivate::NodePtr p ) +TQ_TYPENAME TQMapPrivate::NodePtr TQMapPrivate::copy( TQ_TYPENAME TQMapPrivate::NodePtr p ) { if ( !p ) return 0; @@ -476,7 +476,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::NodePtr TQMapPrivate } template -TQ_INLINE_TEMPLATES void TQMapPrivate::clear() +void TQMapPrivate::clear() { clear( (NodePtr)(header->parent) ); header->color = TQMapNodeBase::Red; @@ -486,7 +486,7 @@ TQ_INLINE_TEMPLATES void TQMapPrivate::clear() } template -TQ_INLINE_TEMPLATES void TQMapPrivate::clear( TQ_TYPENAME TQMapPrivate::NodePtr p ) +void TQMapPrivate::clear( TQ_TYPENAME TQMapPrivate::NodePtr p ) { while ( p != 0 ) { clear( (NodePtr)p->right ); @@ -497,7 +497,7 @@ TQ_INLINE_TEMPLATES void TQMapPrivate::clear( TQ_TYPENAME TQMapPrivate -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::ConstIterator TQMapPrivate::find(const Key& k) const +TQ_TYPENAME TQMapPrivate::ConstIterator TQMapPrivate::find(const Key& k) const { TQMapNodeBase* y = header; // Last node TQMapNodeBase* x = header->parent; // Root node. @@ -520,7 +520,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::ConstIterator TQMapPrivate< } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::Iterator TQMapPrivate::insertSingle( const Key& k ) +TQ_TYPENAME TQMapPrivate::Iterator TQMapPrivate::insertSingle( const Key& k ) { // Search correct position in the tree TQMapNodeBase* y = header; @@ -551,7 +551,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::Iterator TQMapPrivate -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMapPrivate::Iterator TQMapPrivate::insert( TQMapNodeBase* x, TQMapNodeBase* y, const Key& k ) +TQ_TYPENAME TQMapPrivate::Iterator TQMapPrivate::insert( TQMapNodeBase* x, TQMapNodeBase* y, const Key& k ) { NodePtr z = new Node( k ); if (y == header || x != 0 || k < key(y) ) { @@ -754,7 +754,7 @@ private: }; template -TQ_INLINE_TEMPLATES TQMap& TQMap::operator= ( const TQMap& m ) +TQMap& TQMap::operator= ( const TQMap& m ) { m.sh->ref(); if ( sh->deref() ) @@ -764,7 +764,7 @@ TQ_INLINE_TEMPLATES TQMap& TQMap::operator= ( const TQMap& } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::insert_pair TQMap::insert( const TQ_TYPENAME TQMap::value_type& x ) +TQ_TYPENAME TQMap::insert_pair TQMap::insert( const TQ_TYPENAME TQMap::value_type& x ) { detach(); size_type n = size(); @@ -778,7 +778,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::insert_pair TQMap::insert( } template -TQ_INLINE_TEMPLATES void TQMap::erase( const Key& k ) +void TQMap::erase( const Key& k ) { detach(); iterator it( sh->find( k ).node ); @@ -787,7 +787,7 @@ TQ_INLINE_TEMPLATES void TQMap::erase( const Key& k ) } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::size_type TQMap::count( const Key& k ) const +TQ_TYPENAME TQMap::size_type TQMap::count( const Key& k ) const { const_iterator it( sh->find( k ).node ); if ( it != end() ) { @@ -802,7 +802,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::size_type TQMap::count( con } template -TQ_INLINE_TEMPLATES T& TQMap::operator[] ( const Key& k ) +T& TQMap::operator[] ( const Key& k ) { detach(); TQMapNode* p = sh->find( k ).node; @@ -812,7 +812,7 @@ TQ_INLINE_TEMPLATES T& TQMap::operator[] ( const Key& k ) } template -TQ_INLINE_TEMPLATES void TQMap::clear() +void TQMap::clear() { if ( sh->count == 1 ) sh->clear(); @@ -823,7 +823,7 @@ TQ_INLINE_TEMPLATES void TQMap::clear() } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::iterator TQMap::insert( const Key& key, const T& value, bool overwrite ) +TQ_TYPENAME TQMap::iterator TQMap::insert( const Key& key, const T& value, bool overwrite ) { detach(); size_type n = size(); @@ -834,7 +834,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQMap::iterator TQMap::insert( con } template -TQ_INLINE_TEMPLATES void TQMap::remove( const Key& k ) +void TQMap::remove( const Key& k ) { detach(); iterator it( sh->find( k ).node ); @@ -843,7 +843,7 @@ TQ_INLINE_TEMPLATES void TQMap::remove( const Key& k ) } template -TQ_INLINE_TEMPLATES void TQMap::detachInternal() +void TQMap::detachInternal() { sh->deref(); sh = new TQMapPrivate( sh ); } @@ -851,7 +851,7 @@ TQ_INLINE_TEMPLATES void TQMap::detachInternal() #ifndef TQT_NO_DATASTREAM template -TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQMap& m ) { +TQDataStream& operator>>( TQDataStream& s, TQMap& m ) { m.clear(); TQ_UINT32 c; s >> c; @@ -867,7 +867,7 @@ TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQMap& m ) template -TQ_INLINE_TEMPLATES TQDataStream& operator<<( TQDataStream& s, const TQMap& m ) { +TQDataStream& operator<<( TQDataStream& s, const TQMap& m ) { s << (TQ_UINT32)m.size(); TQMapConstIterator it = m.begin(); for( ; it != m.end(); ++it ) diff --git a/src/tools/tqpair.h b/src/tools/tqpair.h index 8d487e38b..588c809c2 100644 --- a/src/tools/tqpair.h +++ b/src/tools/tqpair.h @@ -72,20 +72,20 @@ struct TQPair }; template -TQ_INLINE_TEMPLATES bool operator==( const TQPair& x, const TQPair& y ) +bool operator==( const TQPair& x, const TQPair& y ) { return x.first == y.first && x.second == y.second; } template -TQ_INLINE_TEMPLATES bool operator<( const TQPair& x, const TQPair& y ) +bool operator<( const TQPair& x, const TQPair& y ) { return x.first < y.first || ( !( y.first < x.first ) && x.second < y.second ); } template -TQ_INLINE_TEMPLATES TQPair qMakePair( const T1& x, const T2& y ) +TQPair qMakePair( const T1& x, const T2& y ) { return TQPair( x, y ); } diff --git a/src/tools/tqtl.h b/src/tools/tqtl.h index 63da09080..858a48ce0 100644 --- a/src/tools/tqtl.h +++ b/src/tools/tqtl.h @@ -149,7 +149,7 @@ inline void tqSwap( T& _value1, T& _value2 ) template -TQ_INLINE_TEMPLATES void qBubbleSort( InputIterator b, InputIterator e ) +void qBubbleSort( InputIterator b, InputIterator e ) { // Goto last element; InputIterator last = e; @@ -190,7 +190,7 @@ inline void qBubbleSort( Container &c ) template -TQ_INLINE_TEMPLATES void qHeapSortPushDown( Value* heap, int first, int last ) +void qHeapSortPushDown( Value* heap, int first, int last ) { int r = first; while ( r <= last / 2 ) { @@ -219,7 +219,7 @@ TQ_INLINE_TEMPLATES void qHeapSortPushDown( Value* heap, int first, int last ) template -TQ_INLINE_TEMPLATES void qHeapSortHelper( InputIterator b, InputIterator e, Value, uint n ) +void qHeapSortHelper( InputIterator b, InputIterator e, Value, uint n ) { // Create the heap InputIterator insert = b; @@ -250,7 +250,7 @@ TQ_INLINE_TEMPLATES void qHeapSortHelper( InputIterator b, InputIterator e, Valu template -TQ_INLINE_TEMPLATES void qHeapSort( InputIterator b, InputIterator e ) +void qHeapSort( InputIterator b, InputIterator e ) { // Empty ? if ( b == e ) @@ -271,7 +271,7 @@ TQ_INLINE_TEMPLATES void qHeapSort( InputIterator b, InputIterator e ) template -TQ_INLINE_TEMPLATES void qHeapSort( Container &c ) +void qHeapSort( Container &c ) { if ( c.begin() == c.end() ) return; diff --git a/src/tools/tqvaluelist.h b/src/tools/tqvaluelist.h index d0beab5ed..f770214b7 100644 --- a/src/tools/tqvaluelist.h +++ b/src/tools/tqvaluelist.h @@ -250,13 +250,13 @@ public: }; template -TQ_INLINE_TEMPLATES TQValueListPrivate::TQValueListPrivate() +TQValueListPrivate::TQValueListPrivate() { node = new Node(); node->next = node->prev = node; nodes = 0; } template -TQ_INLINE_TEMPLATES TQValueListPrivate::TQValueListPrivate( const TQValueListPrivate& _p ) +TQValueListPrivate::TQValueListPrivate( const TQValueListPrivate& _p ) : TQShared() { node = new Node(); node->next = node->prev = node; nodes = 0; @@ -268,7 +268,7 @@ TQ_INLINE_TEMPLATES TQValueListPrivate::TQValueListPrivate( const TQValueList } template -TQ_INLINE_TEMPLATES TQValueListPrivate::~TQValueListPrivate() { +TQValueListPrivate::~TQValueListPrivate() { NodePtr p = node->next; while( p != node ) { NodePtr x = p->next; @@ -279,7 +279,7 @@ TQ_INLINE_TEMPLATES TQValueListPrivate::~TQValueListPrivate() { } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPrivate::insert( TQ_TYPENAME TQValueListPrivate::Iterator it, const T& x ) +TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPrivate::insert( TQ_TYPENAME TQValueListPrivate::Iterator it, const T& x ) { NodePtr p = new Node( x ); p->next = it.node; @@ -291,7 +291,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPriva } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPrivate::remove( TQ_TYPENAME TQValueListPrivate::Iterator it ) +TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPrivate::remove( TQ_TYPENAME TQValueListPrivate::Iterator it ) { Q_ASSERT ( it.node != node ); NodePtr next = it.node->next; @@ -304,7 +304,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::Iterator TQValueListPriva } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivate::find( TQ_TYPENAME TQValueListPrivate::NodePtr start, const T& x ) const +TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivate::find( TQ_TYPENAME TQValueListPrivate::NodePtr start, const T& x ) const { ConstIterator first( start ); ConstIterator last( node ); @@ -317,7 +317,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivat } template -TQ_INLINE_TEMPLATES int TQValueListPrivate::findIndex( TQ_TYPENAME TQValueListPrivate::NodePtr start, const T& x ) const +int TQValueListPrivate::findIndex( TQ_TYPENAME TQValueListPrivate::NodePtr start, const T& x ) const { ConstIterator first( start ); ConstIterator last( node ); @@ -332,7 +332,7 @@ TQ_INLINE_TEMPLATES int TQValueListPrivate::findIndex( TQ_TYPENAME TQValueLis } template -TQ_INLINE_TEMPLATES uint TQValueListPrivate::contains( const T& x ) const +uint TQValueListPrivate::contains( const T& x ) const { uint result = 0; Iterator first = Iterator( node->next ); @@ -346,7 +346,7 @@ TQ_INLINE_TEMPLATES uint TQValueListPrivate::contains( const T& x ) const } template -TQ_INLINE_TEMPLATES bool TQValueListPrivate::containsYesNo( const T& x ) const +bool TQValueListPrivate::containsYesNo( const T& x ) const { Iterator first = Iterator( node->next ); Iterator last = Iterator( node ); @@ -359,7 +359,7 @@ TQ_INLINE_TEMPLATES bool TQValueListPrivate::containsYesNo( const T& x ) cons } template -TQ_INLINE_TEMPLATES uint TQValueListPrivate::remove( const T& _x ) +uint TQValueListPrivate::remove( const T& _x ) { const T x = _x; uint result = 0; @@ -376,7 +376,7 @@ TQ_INLINE_TEMPLATES uint TQValueListPrivate::remove( const T& _x ) } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivate::at( size_type i ) const +TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivate::at( size_type i ) const { Q_ASSERT( i <= nodes ); NodePtr p = node->next; @@ -386,7 +386,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueListPrivate::NodePtr TQValueListPrivat } template -TQ_INLINE_TEMPLATES void TQValueListPrivate::clear() +void TQValueListPrivate::clear() { nodes = 0; NodePtr p = node->next; @@ -596,7 +596,7 @@ private: }; template -TQ_INLINE_TEMPLATES bool TQValueList::operator== ( const TQValueList& l ) const +bool TQValueList::operator== ( const TQValueList& l ) const { if ( size() != l.size() ) return false; @@ -609,13 +609,13 @@ TQ_INLINE_TEMPLATES bool TQValueList::operator== ( const TQValueList& l ) } template -TQ_INLINE_TEMPLATES void TQValueList::clear() +void TQValueList::clear() { if ( sh->count == 1 ) sh->clear(); else { sh->deref(); sh = new TQValueListPrivate(); } } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueList::iterator TQValueList::erase( TQ_TYPENAME TQValueList::iterator first, TQ_TYPENAME TQValueList::iterator last ) +TQ_TYPENAME TQValueList::iterator TQValueList::erase( TQ_TYPENAME TQValueList::iterator first, TQ_TYPENAME TQValueList::iterator last ) { while ( first != last ) erase( first++ ); @@ -624,14 +624,14 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueList::iterator TQValueList::erase( template -TQ_INLINE_TEMPLATES void TQValueList::insert( TQ_TYPENAME TQValueList::iterator pos, size_type n, const T& x ) +void TQValueList::insert( TQ_TYPENAME TQValueList::iterator pos, size_type n, const T& x ) { for ( ; n > 0; --n ) insert( pos, x ); } template -TQ_INLINE_TEMPLATES TQValueList TQValueList::operator+ ( const TQValueList& l ) const +TQValueList TQValueList::operator+ ( const TQValueList& l ) const { TQValueList l2( *this ); for( const_iterator it = l.begin(); it != l.end(); ++it ) @@ -640,7 +640,7 @@ TQ_INLINE_TEMPLATES TQValueList TQValueList::operator+ ( const TQValueList } template -TQ_INLINE_TEMPLATES TQValueList& TQValueList::operator+= ( const TQValueList& l ) +TQValueList& TQValueList::operator+= ( const TQValueList& l ) { TQValueList copy = l; for( const_iterator it = copy.begin(); it != copy.end(); ++it ) @@ -650,7 +650,7 @@ TQ_INLINE_TEMPLATES TQValueList& TQValueList::operator+= ( const TQValueLi #ifndef TQT_NO_DATASTREAM template -TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQValueList& l ) +TQDataStream& operator>>( TQDataStream& s, TQValueList& l ) { l.clear(); TQ_UINT32 c; @@ -665,7 +665,7 @@ TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQValueList& l } template -TQ_INLINE_TEMPLATES TQDataStream& operator<<( TQDataStream& s, const TQValueList& l ) +TQDataStream& operator<<( TQDataStream& s, const TQValueList& l ) { s << (TQ_UINT32)l.size(); TQValueListConstIterator it = l.begin(); diff --git a/src/tools/tqvaluevector.h b/src/tools/tqvaluevector.h index 3cae4b71d..791095b93 100644 --- a/src/tools/tqvaluevector.h +++ b/src/tools/tqvaluevector.h @@ -121,7 +121,7 @@ private: }; template -TQ_INLINE_TEMPLATES TQValueVectorPrivate::TQValueVectorPrivate( const TQValueVectorPrivate& x ) +TQValueVectorPrivate::TQValueVectorPrivate( const TQValueVectorPrivate& x ) : TQShared() { size_t i = x.size(); @@ -142,7 +142,7 @@ TQ_INLINE_TEMPLATES TQValueVectorPrivate::TQValueVectorPrivate( const TQValue } template -TQ_INLINE_TEMPLATES TQValueVectorPrivate::TQValueVectorPrivate( size_t size ) +TQValueVectorPrivate::TQValueVectorPrivate( size_t size ) { if ( size > 0 ) { start = new T[size]; @@ -156,7 +156,7 @@ TQ_INLINE_TEMPLATES TQValueVectorPrivate::TQValueVectorPrivate( size_t size ) } template -TQ_INLINE_TEMPLATES void TQValueVectorPrivate::insert( pointer pos, const T& x ) +void TQValueVectorPrivate::insert( pointer pos, const T& x ) { const size_t lastSize = size(); const size_t n = lastSize !=0 ? 2*lastSize : 1; @@ -173,7 +173,7 @@ TQ_INLINE_TEMPLATES void TQValueVectorPrivate::insert( pointer pos, const T& } template -TQ_INLINE_TEMPLATES void TQValueVectorPrivate::insert( pointer pos, size_t n, const T& x ) +void TQValueVectorPrivate::insert( pointer pos, size_t n, const T& x ) { if ( size_t( end - finish ) >= n ) { // enough room @@ -213,7 +213,7 @@ TQ_INLINE_TEMPLATES void TQValueVectorPrivate::insert( pointer pos, size_t n, } template -TQ_INLINE_TEMPLATES void TQValueVectorPrivate::reserve( size_t n ) +void TQValueVectorPrivate::reserve( size_t n ) { const size_t lastSize = size(); pointer tmp = growAndCopy( n, start, finish ); @@ -223,7 +223,7 @@ TQ_INLINE_TEMPLATES void TQValueVectorPrivate::reserve( size_t n ) } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueVectorPrivate::pointer TQValueVectorPrivate::growAndCopy( size_t n, pointer s, pointer f ) +TQ_TYPENAME TQValueVectorPrivate::pointer TQValueVectorPrivate::growAndCopy( size_t n, pointer s, pointer f ) { pointer newStart = new T[n]; tqCopy( s, f, newStart ); @@ -491,21 +491,21 @@ private: }; template -TQ_INLINE_TEMPLATES TQValueVector::TQValueVector( size_type n, const T& val ) +TQValueVector::TQValueVector( size_type n, const T& val ) { sh = new TQValueVectorPrivate( n ); tqFill( begin(), end(), val ); } template -TQ_INLINE_TEMPLATES void TQValueVector::detachInternal() +void TQValueVector::detachInternal() { sh->deref(); sh = new TQValueVectorPrivate( *sh ); } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueVector::iterator TQValueVector::insert( iterator pos, const T& x ) +TQ_TYPENAME TQValueVector::iterator TQValueVector::insert( iterator pos, const T& x ) { size_type offset = pos - sh->start; detach(); @@ -530,7 +530,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueVector::iterator TQValueVector::ins } template -TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueVector::iterator TQValueVector::insert( iterator pos, size_type n, const T& x ) +TQ_TYPENAME TQValueVector::iterator TQValueVector::insert( iterator pos, size_type n, const T& x ) { if ( n != 0 ) { size_type offset = pos - sh->start; @@ -544,7 +544,7 @@ TQ_INLINE_TEMPLATES TQ_TYPENAME TQValueVector::iterator TQValueVector::ins #ifndef TQT_NO_DATASTREAM template -TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQValueVector& v ) +TQDataStream& operator>>( TQDataStream& s, TQValueVector& v ) { v.clear(); TQ_UINT32 c; @@ -560,7 +560,7 @@ TQ_INLINE_TEMPLATES TQDataStream& operator>>( TQDataStream& s, TQValueVector& } template -TQ_INLINE_TEMPLATES TQDataStream& operator<<( TQDataStream& s, const TQValueVector& v ) +TQDataStream& operator<<( TQDataStream& s, const TQValueVector& v ) { s << (TQ_UINT32)v.size(); // ### use typename TQValueVector::const_iterator once all supported -- cgit v1.2.3