diff options
author | rpaulo <rpaulo@FreeBSD.org> | 2010-08-24 13:38:53 +0000 |
---|---|---|
committer | rpaulo <rpaulo@FreeBSD.org> | 2010-08-24 13:38:53 +0000 |
commit | e94d012481f51b1c96ec6db586b9c5d154b19f91 (patch) | |
tree | 25f64dc547d9d52d9b701076b106e04018a96ac0 /contrib | |
parent | 93070b866313c9d08ab63526856e47819889c964 (diff) | |
download | FreeBSD-src-e94d012481f51b1c96ec6db586b9c5d154b19f91.zip FreeBSD-src-e94d012481f51b1c96ec6db586b9c5d154b19f91.tar.gz |
Some fixes so we can build libstdc++ with clang:
o Make the value_type, vector_type, iterator, __mutex_type types of
free_list class so we can access them
o In some cases template keywords must be inserted to treat classes as
dependent template names
o Remove two 'inline' keywords where they do not make sense
Submitted by: Dimitry Andric <dimitry at andric.com>
Reviewed by: trema
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/libstdc++/include/ext/bitmap_allocator.h | 2 | ||||
-rw-r--r-- | contrib/libstdc++/include/ext/ropeimpl.h | 12 | ||||
-rw-r--r-- | contrib/libstdc++/src/locale-inst.cc | 4 |
3 files changed, 10 insertions, 8 deletions
diff --git a/contrib/libstdc++/include/ext/bitmap_allocator.h b/contrib/libstdc++/include/ext/bitmap_allocator.h index 93fa8e6..ef253fa 100644 --- a/contrib/libstdc++/include/ext/bitmap_allocator.h +++ b/contrib/libstdc++/include/ext/bitmap_allocator.h @@ -549,11 +549,13 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) */ class free_list { + public: typedef size_t* value_type; typedef __detail::__mini_vector<value_type> vector_type; typedef vector_type::iterator iterator; typedef __mutex __mutex_type; + private: struct _LT_pointer_compare { bool diff --git a/contrib/libstdc++/include/ext/ropeimpl.h b/contrib/libstdc++/include/ext/ropeimpl.h index bbe6b99..28c0b1f 100644 --- a/contrib/libstdc++/include/ext/ropeimpl.h +++ b/contrib/libstdc++/include/ext/ropeimpl.h @@ -382,7 +382,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) { _Rope_RopeLeaf<_CharT, _Alloc>* __l = (_Rope_RopeLeaf<_CharT, _Alloc>*)this; - __l->_Rope_RopeLeaf<_CharT, _Alloc>::~_Rope_RopeLeaf(); + __l->template _Rope_RopeLeaf<_CharT, _Alloc>::~_Rope_RopeLeaf(); _L_deallocate(__l, 1); break; } @@ -390,7 +390,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) { _Rope_RopeConcatenation<_CharT,_Alloc>* __c = (_Rope_RopeConcatenation<_CharT, _Alloc>*)this; - __c->_Rope_RopeConcatenation<_CharT, _Alloc>:: + __c->template _Rope_RopeConcatenation<_CharT, _Alloc>:: ~_Rope_RopeConcatenation(); _C_deallocate(__c, 1); break; @@ -399,7 +399,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) { _Rope_RopeFunction<_CharT, _Alloc>* __f = (_Rope_RopeFunction<_CharT, _Alloc>*)this; - __f->_Rope_RopeFunction<_CharT, _Alloc>::~_Rope_RopeFunction(); + __f->template _Rope_RopeFunction<_CharT, _Alloc>::~_Rope_RopeFunction(); _F_deallocate(__f, 1); break; } @@ -407,7 +407,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) { _Rope_RopeSubstring<_CharT, _Alloc>* __ss = (_Rope_RopeSubstring<_CharT, _Alloc>*)this; - __ss->_Rope_RopeSubstring<_CharT, _Alloc>:: + __ss->template _Rope_RopeSubstring<_CharT, _Alloc>:: ~_Rope_RopeSubstring(); _S_deallocate(__ss, 1); break; @@ -433,7 +433,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) { size_t __old_len = __r->_M_size; _CharT* __new_data = (_CharT*) - _Data_allocate(_S_rounded_up_size(__old_len + __len)); + _Rope_rep_base<_CharT, _Alloc>::_Data_allocate(_S_rounded_up_size(__old_len + __len)); _RopeLeaf* __result; uninitialized_copy_n(__r->_M_data, __old_len, __new_data); @@ -817,7 +817,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) if (__result_len > __lazy_threshold) goto lazy; __section = (_CharT*) - _Data_allocate(_S_rounded_up_size(__result_len)); + _Rope_rep_base<_CharT, _Alloc>::_Data_allocate(_S_rounded_up_size(__result_len)); try { (*(__f->_M_fn))(__start, __result_len, __section); } catch(...) diff --git a/contrib/libstdc++/src/locale-inst.cc b/contrib/libstdc++/src/locale-inst.cc index 790e614..c6ab9a4 100644 --- a/contrib/libstdc++/src/locale-inst.cc +++ b/contrib/libstdc++/src/locale-inst.cc @@ -180,11 +180,11 @@ _GLIBCXX_END_LDBL_NAMESPACE template class messages_byname<C>; // ctype - inline template class __ctype_abstract_base<C>; + template class __ctype_abstract_base<C>; template class ctype_byname<C>; // codecvt - inline template class __codecvt_abstract_base<C, char, mbstate_t>; + template class __codecvt_abstract_base<C, char, mbstate_t>; template class codecvt_byname<C, char, mbstate_t>; // collate |