diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-04-13 17:12:02 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-04-13 17:12:02 -0600 |
commit | 2a815aa47083c49b9a809056004bd9a01e87221c (patch) | |
tree | e41801257e0cd4e27dc3516d8fd8216104a4c648 /misc/uClibc++/include | |
parent | 638c1a6dc07b438efa220c5345e94c3a963505ca (diff) | |
download | px4-nuttx-2a815aa47083c49b9a809056004bd9a01e87221c.tar.gz px4-nuttx-2a815aa47083c49b9a809056004bd9a01e87221c.tar.bz2 px4-nuttx-2a815aa47083c49b9a809056004bd9a01e87221c.zip |
Restore trainling whitespace in .patch and .diff files wehre required
Diffstat (limited to 'misc/uClibc++/include')
28 files changed, 343 insertions, 343 deletions
diff --git a/misc/uClibc++/include/uClibc++/algorithm b/misc/uClibc++/include/uClibc++/algorithm index e13713cfc..5c62ffeaf 100644 --- a/misc/uClibc++/include/uClibc++/algorithm +++ b/misc/uClibc++/include/uClibc++/algorithm @@ -429,10 +429,10 @@ namespace std return first; } } - + ++first; } - + return first; } diff --git a/misc/uClibc++/include/uClibc++/associative_base b/misc/uClibc++/include/uClibc++/associative_base index 67122691b..dbf4ddbbb 100644 --- a/misc/uClibc++/include/uClibc++/associative_base +++ b/misc/uClibc++/include/uClibc++/associative_base @@ -340,7 +340,7 @@ public: { // The following approach ensures that we only need to // provide code for ++ in one place (above) - + _associative_citer temp(base_iter); ++base_iter; return temp; @@ -609,7 +609,7 @@ public: const Compare& comp, const Allocator& A, const key_type (*v_to_k)(const value_type) - ) : base(comp, A, v_to_k) + ) : base(comp, A, v_to_k) { insert(first, last); } diff --git a/misc/uClibc++/include/uClibc++/bitset b/misc/uClibc++/include/uClibc++/bitset index 92243b208..2ef66b501 100644 --- a/misc/uClibc++/include/uClibc++/bitset +++ b/misc/uClibc++/include/uClibc++/bitset @@ -38,12 +38,12 @@ namespace std template <size_t N> bitset<N> operator&(const bitset<N>&, const bitset<N>&); template <size_t N> bitset<N> operator|(const bitset<N>&, const bitset<N>&); template <size_t N> bitset<N> operator^(const bitset<N>&, const bitset<N>&); - template <class charT, class traits, size_t N> basic_istream<charT, traits>& + template <class charT, class traits, size_t N> basic_istream<charT, traits>& operator>>(basic_istream<charT, traits>& is, bitset<N>& x); - template <class charT, class traits, size_t N> basic_ostream<charT, traits>& + template <class charT, class traits, size_t N> basic_ostream<charT, traits>& operator<<(basic_ostream<charT, traits>& os, const bitset<N>& x); - + // Actual Code template<size_t N> class _UCXXEXPORT bitset { @@ -56,7 +56,7 @@ namespace std //From the bit number, figure out which byte we are working with size_t byte_num(size_t bit_num) const - { + { if (WORD_SIZE == 8) { return (bit_num >> 3); @@ -93,7 +93,7 @@ namespace std public: - class _UCXXEXPORT reference + class _UCXXEXPORT reference { friend class bitset; reference() : bit_num(0), parent(0) { } @@ -176,7 +176,7 @@ namespace std typename basic_string<charT,traits,Allocator>::size_type pos = 0, typename basic_string<charT,traits,Allocator>::size_type n = basic_string<charT>::npos - + ) { reset(); @@ -526,7 +526,7 @@ namespace std return retval; } - template <class charT, class traits, size_t N> _UCXXEXPORT basic_istream<charT, traits>& + template <class charT, class traits, size_t N> _UCXXEXPORT basic_istream<charT, traits>& operator>>(basic_istream<charT, traits>& is, bitset<N>& x) { string s; @@ -553,7 +553,7 @@ namespace std return is; } - template <class charT, class traits, size_t N> _UCXXEXPORT basic_ostream<charT, traits>& + template <class charT, class traits, size_t N> _UCXXEXPORT basic_ostream<charT, traits>& operator<<(basic_ostream<charT, traits>& os, const bitset<N>& x) { for (size_t i = N ; i > 0; --i) diff --git a/misc/uClibc++/include/uClibc++/char_traits b/misc/uClibc++/include/uClibc++/char_traits index ec2900ba7..ee05be24d 100644 --- a/misc/uClibc++/include/uClibc++/char_traits +++ b/misc/uClibc++/include/uClibc++/char_traits @@ -62,14 +62,14 @@ namespace std // Specialize for char - template<> struct _UCXXEXPORT char_traits<char> + template<> struct _UCXXEXPORT char_traits<char> { typedef char char_type; typedef short int int_type; typedef char_traits_off_type off_type; typedef char_traits_off_type pos_type; typedef char state_type; - + inline static void assign(char_type & c, const char_type & d) { c = d; } static bool eq(const char_type& c1, const char_type& c2); @@ -142,7 +142,7 @@ namespace std { return 0; } - else + else { return i; } @@ -157,7 +157,7 @@ namespace std }; #ifdef __UCLIBCXX_HAS_WCHAR__ - template<> struct _UCXXEXPORT char_traits<wchar_t> + template<> struct _UCXXEXPORT char_traits<wchar_t> { typedef wchar_t char_type; typedef wint_t int_type; @@ -242,7 +242,7 @@ namespace std inline static char_type eos() { return 0; } inline static int_type eof() { return WEOF; } - inline static int_type not_eof(const int_type & i) + inline static int_type not_eof(const int_type & i) { if (i == WEOF) { diff --git a/misc/uClibc++/include/uClibc++/cwctype b/misc/uClibc++/include/uClibc++/cwctype index 5e4b60538..6901545d8 100644 --- a/misc/uClibc++/include/uClibc++/cwctype +++ b/misc/uClibc++/include/uClibc++/cwctype @@ -66,7 +66,7 @@ #undef iswspace #undef iswupper #undef iswxdigit -#undef iswctype +#undef iswctype #undef towlower #undef towupper #undef towctrans @@ -103,4 +103,4 @@ namespace std } #endif //__ULIBCXX_HAS_WCHAR__ -#endif +#endif diff --git a/misc/uClibc++/include/uClibc++/deque b/misc/uClibc++/include/uClibc++/deque index 48b5db3b3..08261e089 100644 --- a/misc/uClibc++/include/uClibc++/deque +++ b/misc/uClibc++/include/uClibc++/deque @@ -558,7 +558,7 @@ namespace std }; template<class T, class Allocator> deque<T, Allocator>::deque(const Allocator& al) - : data(0), + : data(0), data_size(0), elements(0), first_element(0), last_element(0), a(al) { data_size = __UCLIBCXX_STL_BUFFER_SIZE__; @@ -585,7 +585,7 @@ namespace std } - template<class T, class Allocator> template <class InputIterator> + template<class T, class Allocator> template <class InputIterator> deque<T, Allocator>::deque(InputIterator first, InputIterator last, const Allocator& al) : data(0), data_size(0), elements(0), first_element(0), last_element(0), a(al) @@ -665,7 +665,7 @@ namespace std } } - template<class T, class Allocator> typename deque<T, Allocator>::allocator_type + template<class T, class Allocator> typename deque<T, Allocator>::allocator_type deque<T, Allocator>::get_allocator() const { return a; @@ -694,7 +694,7 @@ namespace std { return deque_citer(this, elements); } - + template<class T, class Allocator> typename deque<T, Allocator>::reverse_iterator deque<T, Allocator>::rbegin() { @@ -813,7 +813,7 @@ namespace std { return data[array_element(elements-1)]; } - + template<class T, class Allocator> void deque<T, Allocator>::push_front(const T& x) { reserve(elements + 1); @@ -867,7 +867,7 @@ namespace std } } - template<class T, class Allocator> template <class InputIterator> + template<class T, class Allocator> template <class InputIterator> void deque<T, Allocator>::insert (iterator position, InputIterator first, InputIterator last) { while (first != last){ @@ -920,7 +920,7 @@ namespace std return deque_iter(this, position.element); } - template<class T, class Allocator> typename deque<T, Allocator>::iterator + template<class T, class Allocator> typename deque<T, Allocator>::iterator deque<T, Allocator>:: erase(typename deque<T, Allocator>::iterator first, typename deque<T, Allocator>::iterator last) { @@ -1010,7 +1010,7 @@ namespace std T * data_temp; size_temp = n + __UCLIBCXX_STL_BUFFER_SIZE__; //Reserve extra 'cause we can data_temp = a.allocate(size_temp); - + first_temp = (size_temp - elements) / 2; for (size_type i = 0; i < elements; ++i) { @@ -1027,7 +1027,7 @@ namespace std last_element = first_element + elements; } - template <class T, class Allocator> _UCXXEXPORT + template <class T, class Allocator> _UCXXEXPORT bool operator==(const deque<T,Allocator>& x, const deque<T,Allocator>& y) { diff --git a/misc/uClibc++/include/uClibc++/exception b/misc/uClibc++/include/uClibc++/exception index 6d91207b8..23b7e0caa 100644 --- a/misc/uClibc++/include/uClibc++/exception +++ b/misc/uClibc++/include/uClibc++/exception @@ -106,7 +106,7 @@ namespace std /** The runtime will call this function if an %exception is thrown which * violates the function's %exception specification. */ - + void unexpected() noreturn_function; /** [18.6.4]/1: "Returns true after completing evaluation of a @@ -119,7 +119,7 @@ namespace std * 2: "When @c uncaught_exception() is true, throwing an %exception can * result in a call of @c terminate() (15.5.1)." */ - + bool uncaught_exception() throw(); } // namespace std diff --git a/misc/uClibc++/include/uClibc++/fstream b/misc/uClibc++/include/uClibc++/fstream index acc3a0308..3ea05f9f8 100644 --- a/misc/uClibc++/include/uClibc++/fstream +++ b/misc/uClibc++/include/uClibc++/fstream @@ -16,7 +16,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifndef __STD_HEADER_FSTREAM +#ifndef __STD_HEADER_FSTREAM #define __STD_HEADER_FSTREAM 1 #include<basic_definitions> @@ -312,7 +312,7 @@ namespace std // Fill rest of buffer - retval = fread(basic_streambuf<charT,traits>::egptr() - + retval = fread(basic_streambuf<charT,traits>::egptr() - basic_streambuf<charT,traits>::gptr() + basic_streambuf<charT,traits>::eback(), sizeof(charT), offset, @@ -336,7 +336,7 @@ namespace std // Read one element of size sizeof(charT) - retval = fread(basic_streambuf<charT,traits>::egptr() - + retval = fread(basic_streambuf<charT,traits>::egptr() - basic_streambuf<charT,traits>::gptr() + basic_streambuf<charT,traits>::eback(), sizeof(charT), 1, @@ -384,7 +384,7 @@ namespace std virtual _UCXXEXPORT int_type pbackfail(int_type c = traits::eof()) { - if (is_open() == false || + if (is_open() == false || basic_streambuf<charT,traits>::gptr() == basic_streambuf<charT,traits>::eback()) { return traits::eof(); @@ -513,7 +513,7 @@ namespace std pbuffer = 0; gbuffer = 0; } - else if (basic_streambuf<charT,traits>::gptr() !=0 && + else if (basic_streambuf<charT,traits>::gptr() !=0 && basic_streambuf<charT,traits>::gptr()==basic_streambuf<charT,traits>::egptr()) { delete [] pbuffer; @@ -523,7 +523,7 @@ namespace std return this; } - virtual _UCXXEXPORT pos_type seekoff(off_type off, ios_base::seekdir way, + virtual _UCXXEXPORT pos_type seekoff(off_type off, ios_base::seekdir way, ios_base::openmode = ios_base::in | ios_base::out) { if (is_open() == false) diff --git a/misc/uClibc++/include/uClibc++/ios b/misc/uClibc++/include/uClibc++/ios index 6b49921ed..1e92643e2 100644 --- a/misc/uClibc++/include/uClibc++/ios +++ b/misc/uClibc++/include/uClibc++/ios @@ -40,7 +40,7 @@ namespace std public: class failure; #ifdef CONFIG_UCLIBCXX_EXCEPTION - class failure : public exception + class failure : public exception { public: explicit failure(const std::string&) { } diff --git a/misc/uClibc++/include/uClibc++/iosfwd b/misc/uClibc++/include/uClibc++/iosfwd index c322b64d3..de9b77e29 100644 --- a/misc/uClibc++/include/uClibc++/iosfwd +++ b/misc/uClibc++/include/uClibc++/iosfwd @@ -29,7 +29,7 @@ extern "C++" { -namespace std +namespace std { class ios_base; template<> class char_traits<char>; @@ -45,10 +45,10 @@ namespace std template <class charT, class traits = char_traits<charT> > class basic_ostream; template <class charT, class traits = char_traits<charT> > class basic_iostream; - template <class charT, class traits = char_traits<charT>, + template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> > class basic_stringbuf; - template <class charT, class traits = char_traits<charT>, + template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> > class basic_istringstream; template <class charT, class traits = char_traits<charT>, @@ -104,7 +104,7 @@ namespace std typedef basic_ofstream<wchar_t> wofstream; typedef basic_fstream<wchar_t> wfstream; #endif - + template <class state> class fpos; typedef fpos<char_traits<char>::state_type> streampos; #ifdef __UCLIBCXX_HAS_WCHAR__ diff --git a/misc/uClibc++/include/uClibc++/iostream b/misc/uClibc++/include/uClibc++/iostream index 3a2f5c09e..1448793a9 100644 --- a/misc/uClibc++/include/uClibc++/iostream +++ b/misc/uClibc++/include/uClibc++/iostream @@ -62,7 +62,7 @@ namespace std #endif template <class charT, class traits> class _UCXXEXPORT basic_iostream : - public basic_istream<charT,traits>, public basic_ostream<charT,traits> + public basic_istream<charT,traits>, public basic_ostream<charT,traits> { public: // constructor/destructor @@ -70,7 +70,7 @@ namespace std virtual _UCXXEXPORT ~basic_iostream(); //Below }; - template <class charT, class traits> _UCXXEXPORT + template <class charT, class traits> _UCXXEXPORT basic_iostream<charT, traits>:: basic_iostream(basic_streambuf<charT,traits>* sb) : basic_ios<charT, traits>(sb), basic_istream<charT,traits>(sb), basic_ostream<charT,traits>(sb) { diff --git a/misc/uClibc++/include/uClibc++/istream b/misc/uClibc++/include/uClibc++/istream index faedcc1c8..742de59d5 100644 --- a/misc/uClibc++/include/uClibc++/istream +++ b/misc/uClibc++/include/uClibc++/istream @@ -351,7 +351,7 @@ namespace std } if (basic_ios<charT, traits>::mstreambuf == 0){ - + basic_ios<charT,traits>::setstate(ios_base::badbit); return *this; } diff --git a/misc/uClibc++/include/uClibc++/limits b/misc/uClibc++/include/uClibc++/limits index 0b5b159e9..5915012ef 100644 --- a/misc/uClibc++/include/uClibc++/limits +++ b/misc/uClibc++/include/uClibc++/limits @@ -184,7 +184,7 @@ public: static T signaling_NaN(); }; -template <> class numeric_limits<bool> +template <> class numeric_limits<bool> { public: typedef bool T; diff --git a/misc/uClibc++/include/uClibc++/map b/misc/uClibc++/include/uClibc++/map index 6816116bb..afc4689eb 100644 --- a/misc/uClibc++/include/uClibc++/map +++ b/misc/uClibc++/include/uClibc++/map @@ -35,7 +35,7 @@ template<class Key, class T, class Compare = less<Key>, class Allocator = alloca //Compare the keys of the two items - /* template<class Key, class T, class Compare, class Allocator> class _UCXXEXPORT + /* template<class Key, class T, class Compare, class Allocator> class _UCXXEXPORT __base_map<Key, T, Compare, Allocator>::value_compare : public binary_function< typename map<Key, T, Compare, Allocator>::value_type, typename map<Key, T, Compare, Allocator>::value_type, @@ -216,11 +216,11 @@ protected: }; /* Non-member functions. These are at the end because they are not associated with any - * particular class. These will be implemented as I figure out exactly what all of + * particular class. These will be implemented as I figure out exactly what all of * them are supposed to do, and I have time. */ - template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator< + template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator< (const map<Key,T,Compare,Allocator>& x, const map<Key,T,Compare,Allocator>& y); template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator!= @@ -241,13 +241,13 @@ protected: template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator== (const multimap<Key,T,Compare,Allocator>& x, const multimap<Key,T,Compare,Allocator>& y); - template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator< + template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator< (const multimap<Key,T,Compare,Allocator>& x, const multimap<Key,T,Compare,Allocator>& y); template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator!= (const multimap<Key,T,Compare,Allocator>& x, const multimap<Key,T,Compare,Allocator>& y); - template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator> + template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator> (const multimap<Key,T,Compare,Allocator>& x, const multimap<Key,T,Compare,Allocator>& y); template <class Key, class T, class Compare, class Allocator> _UCXXEXPORT bool operator>= @@ -266,4 +266,4 @@ protected: #endif - + diff --git a/misc/uClibc++/include/uClibc++/memory b/misc/uClibc++/include/uClibc++/memory index cd3956f18..f01f97717 100644 --- a/misc/uClibc++/include/uClibc++/memory +++ b/misc/uClibc++/include/uClibc++/memory @@ -38,7 +38,7 @@ namespace std template <class T> class allocator; // Specialize for void: -template <> class _UCXXEXPORT allocator<void> +template <> class _UCXXEXPORT allocator<void> { public: typedef void* pointer; @@ -53,7 +53,7 @@ public: typedef T value_type; typedef size_t size_type; typedef ptrdiff_t difference_type; - + typedef T* pointer; typedef const T* const_pointer; @@ -62,7 +62,7 @@ public: pointer address(reference r) const { return &r; } const_pointer address(const_reference r) const { return &r; } - + allocator() throw(){} template <class U> allocator(const allocator<U>& ) throw(); ~allocator() throw(){} diff --git a/misc/uClibc++/include/uClibc++/new b/misc/uClibc++/include/uClibc++/new index 29baba6af..75dcbf1c3 100644 --- a/misc/uClibc++/include/uClibc++/new +++ b/misc/uClibc++/include/uClibc++/new @@ -58,7 +58,7 @@ _UCXXEXPORT void operator delete[](void* ptr, const std::nothrow_t& ) throw(); inline void* operator new(std::size_t, void* ptr) throw() {return ptr; } inline void operator delete(void* , void *) throw() { } - + inline void* operator new[](std::size_t, void *p) throw() { return p; } inline void operator delete[](void* , void *) throw() {} diff --git a/misc/uClibc++/include/uClibc++/numeric b/misc/uClibc++/include/uClibc++/numeric index 880eb79f7..aceed3e3e 100644 --- a/misc/uClibc++/include/uClibc++/numeric +++ b/misc/uClibc++/include/uClibc++/numeric @@ -29,7 +29,7 @@ extern "C++" { namespace std { - template <class InputIterator, class T> _UCXXEXPORT + template <class InputIterator, class T> _UCXXEXPORT T accumulate(InputIterator first, InputIterator last, T init) { while (first != last) @@ -41,7 +41,7 @@ namespace std return init; } - template <class InputIterator, class T, class BinaryOperation> _UCXXEXPORT + template <class InputIterator, class T, class BinaryOperation> _UCXXEXPORT T accumulate(InputIterator first, InputIterator last, T init, BinaryOperation binary_op) { while (first != last) @@ -53,7 +53,7 @@ namespace std return init; } - template <class InputIterator1, class InputIterator2, class T> _UCXXEXPORT + template <class InputIterator1, class InputIterator2, class T> _UCXXEXPORT T inner_product(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, T init) { @@ -68,7 +68,7 @@ namespace std } template <class InputIterator1, class InputIterator2, class T, - class BinaryOperation1, class BinaryOperation2> _UCXXEXPORT + class BinaryOperation1, class BinaryOperation2> _UCXXEXPORT T inner_product(InputIterator1 first1, InputIterator1 last1, InputIterator2 first2, T init, BinaryOperation1 binary_op1, @@ -84,7 +84,7 @@ namespace std return init; } - template <class InputIterator, class OutputIterator> _UCXXEXPORT + template <class InputIterator, class OutputIterator> _UCXXEXPORT OutputIterator partial_sum(InputIterator first, InputIterator last, OutputIterator result) { @@ -104,7 +104,7 @@ namespace std return result; } - template <class InputIterator, class OutputIterator, class BinaryOperation> _UCXXEXPORT + template <class InputIterator, class OutputIterator, class BinaryOperation> _UCXXEXPORT OutputIterator partial_sum(InputIterator first, InputIterator last, OutputIterator result, BinaryOperation binary_op) { @@ -124,7 +124,7 @@ namespace std return result; } - template <class InputIterator, class OutputIterator> _UCXXEXPORT + template <class InputIterator, class OutputIterator> _UCXXEXPORT OutputIterator adjacent_difference(InputIterator first, InputIterator last, OutputIterator result) @@ -146,7 +146,7 @@ namespace std } - template <class InputIterator, class OutputIterator, class BinaryOperation> _UCXXEXPORT + template <class InputIterator, class OutputIterator, class BinaryOperation> _UCXXEXPORT OutputIterator adjacent_difference(InputIterator first, InputIterator last, OutputIterator result, BinaryOperation binary_op) diff --git a/misc/uClibc++/include/uClibc++/ostream b/misc/uClibc++/include/uClibc++/ostream index c62b4c92d..0965fa8a1 100644 --- a/misc/uClibc++/include/uClibc++/ostream +++ b/misc/uClibc++/include/uClibc++/ostream @@ -111,7 +111,7 @@ namespace std _UCXXEXPORT basic_ostream<charT,traits>& write(const char_type* s, streamsize n) { if (basic_ostream<charT,traits>::traits_type::eq_int_type( - basic_ios<charT, traits>::mstreambuf->sputn(s, n), + basic_ios<charT, traits>::mstreambuf->sputn(s, n), basic_ostream<charT,traits>::traits_type::eof()) ) { @@ -167,7 +167,7 @@ namespace std streamsize extra = ios::width() - n; if ((ios::flags()&ios::adjustfield) == ios::right) { - while (extra > 0) + while (extra > 0) { --extra; put(ios::fill()); @@ -197,7 +197,7 @@ namespace std // Implementations of template functions. To allow for partial specialization template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>::~basic_ostream(){ } - + template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& basic_ostream<charT, traits>::operator<<(bool n) { sentry s(*this); @@ -232,7 +232,7 @@ namespace std return *this; } - template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& + template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& basic_ostream<charT, traits>::operator<<(unsigned short n) { sentry s(*this); @@ -268,7 +268,7 @@ namespace std return *this; } - template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& + template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& basic_ostream<charT, traits>::operator<<(unsigned long n) { sentry s(*this); @@ -310,7 +310,7 @@ namespace std return *this; } - template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& + template <class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& basic_ostream<charT, traits>::operator<<(basic_streambuf<charT,traits>* sb) { sentry s(*this); @@ -385,7 +385,7 @@ namespace std _UCXXEXPORT ~sentry() { } - _UCXXEXPORT operator bool() + _UCXXEXPORT operator bool() { return ok; } @@ -411,7 +411,7 @@ namespace std out.put(c); return out; } - + template<class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>& out, char c) { @@ -419,7 +419,7 @@ namespace std out.put(c); return out; } - + template<class traits> _UCXXEXPORT basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>& out, char c) { @@ -427,7 +427,7 @@ namespace std out.put(c); return out; } - + // signed and unsigned template<class traits> _UCXXEXPORT basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>& out, signed char c) @@ -436,7 +436,7 @@ namespace std out.put(c); return out; } - + template<class traits> _UCXXEXPORT basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>& out, unsigned char c) { @@ -444,7 +444,7 @@ namespace std out.put(c); return out; } - + template<class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>& out, const charT* c) { @@ -452,7 +452,7 @@ namespace std out.printout(c, traits::length(c)); return out; } - + template<class charT, class traits> _UCXXEXPORT basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>& out, const char* c) { @@ -488,7 +488,7 @@ namespace std return out; } #endif - + // Signed and unsigned template<class traits> _UCXXEXPORT basic_ostream<char,traits>& @@ -498,7 +498,7 @@ namespace std out.printout(reinterpret_cast<const char *>(c), traits::length(reinterpret_cast<const char *>(c))); return out; } - + template<class traits> _UCXXEXPORT basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>& out, const unsigned char* c) { @@ -546,7 +546,7 @@ namespace std // Support for output of long long data types -template<class Ch, class Tr> _UCXXEXPORT basic_ostream<Ch, Tr>& +template<class Ch, class Tr> _UCXXEXPORT basic_ostream<Ch, Tr>& operator<<(basic_ostream<Ch, Tr>& os, signed long long int i) { typename basic_ostream<Ch, Tr>::sentry s(os); @@ -554,7 +554,7 @@ template<class Ch, class Tr> _UCXXEXPORT basic_ostream<Ch, Tr>& return os; } -template<class Ch, class Tr> _UCXXEXPORT basic_ostream<Ch, Tr>& +template<class Ch, class Tr> _UCXXEXPORT basic_ostream<Ch, Tr>& operator<<(basic_ostream<Ch, Tr>& os, unsigned long long int i) { typename basic_ostream<Ch, Tr>::sentry s(os); diff --git a/misc/uClibc++/include/uClibc++/ostream_helpers b/misc/uClibc++/include/uClibc++/ostream_helpers index 214ec259d..559e5ccf6 100644 --- a/misc/uClibc++/include/uClibc++/ostream_helpers +++ b/misc/uClibc++/include/uClibc++/ostream_helpers @@ -338,7 +338,7 @@ namespace std { length = snprintf(buffer, 32, "%*.*f",static_cast<int>(stream.width()),static_cast<int>(stream.precision()), f); } - else + else { length = snprintf(buffer, 32, "%*.*g",static_cast<int>(stream.width()),static_cast<int>(stream.precision()), f); } diff --git a/misc/uClibc++/include/uClibc++/queue b/misc/uClibc++/include/uClibc++/queue index 51fe35cbe..851f1c02a 100644 --- a/misc/uClibc++/include/uClibc++/queue +++ b/misc/uClibc++/include/uClibc++/queue @@ -91,7 +91,7 @@ namespace std template <class T, class Container = vector<T>, class Compare = less<typename Container::value_type> - > class _UCXXEXPORT priority_queue + > class _UCXXEXPORT priority_queue { protected: Container c; @@ -109,7 +109,7 @@ namespace std const Compare& x = Compare(), const Container& y= Container()) : c(y), comp(c) - { + { c.insert(c.end(), first, last); make_heap(c.begin(), c.end(), comp); } diff --git a/misc/uClibc++/include/uClibc++/sstream b/misc/uClibc++/include/uClibc++/sstream index d06d1874f..ff45b144d 100644 --- a/misc/uClibc++/include/uClibc++/sstream +++ b/misc/uClibc++/include/uClibc++/sstream @@ -108,7 +108,7 @@ namespace std ++ielement; } - return retval; + return retval; } virtual _UCXXEXPORT int_type pbackfail(int_type c = traits::eof()) @@ -241,7 +241,7 @@ namespace std if (which & ios_base::in) { newpos = ielement + off; - } + } } else { @@ -274,8 +274,8 @@ namespace std return newpos; } - - virtual _UCXXEXPORT pos_type seekpos(pos_type sp, + + virtual _UCXXEXPORT pos_type seekpos(pos_type sp, ios_base::openmode which = ios_base::in | ios_base::out) { return seekoff(sp, ios_base::beg, which); @@ -295,13 +295,13 @@ namespace std typedef typename traits::pos_type pos_type; typedef typename traits::off_type off_type; - explicit _UCXXEXPORT basic_istringstream(ios_base::openmode m = ios_base::in) + explicit _UCXXEXPORT basic_istringstream(ios_base::openmode m = ios_base::in) : basic_ios<charT, traits>(&sb), basic_istream<charT,traits>(&sb), sb(m) { } - explicit _UCXXEXPORT basic_istringstream(const basic_string<charT,traits,Allocator>& str, - ios_base::openmode which = ios_base::in) + explicit _UCXXEXPORT basic_istringstream(const basic_string<charT,traits,Allocator>& str, + ios_base::openmode which = ios_base::in) : basic_ios<charT, traits>(&sb), basic_istream<charT,traits>(&sb), sb(str, which) { } @@ -341,7 +341,7 @@ namespace std { } - explicit _UCXXEXPORT basic_ostringstream(const basic_string<charT,traits,Allocator>& str, + explicit _UCXXEXPORT basic_ostringstream(const basic_string<charT,traits,Allocator>& str, ios_base::openmode which = ios_base::out) : basic_ios<charT, traits>(&sb), basic_ostream<charT,traits>(&sb), sb(str, which) { diff --git a/misc/uClibc++/include/uClibc++/streambuf b/misc/uClibc++/include/uClibc++/streambuf index 2dfa213d0..2a8ce1491 100644 --- a/misc/uClibc++/include/uClibc++/streambuf +++ b/misc/uClibc++/include/uClibc++/streambuf @@ -60,8 +60,8 @@ namespace std return setbuf(s,n); } - pos_type pubseekoff(off_type off, - typename ios_base::seekdir way, + pos_type pubseekoff(off_type off, + typename ios_base::seekdir way, ios_base::openmode which = ios_base::in | ios_base::out) { @@ -116,7 +116,7 @@ namespace std charT * mgnext; charT * mgend; - // Pointers for the "put" buffers + // Pointers for the "put" buffers charT * mpbeg; charT * mpnext; @@ -125,7 +125,7 @@ namespace std // In the event of null buffers Lets us know what the buffer is opened for ios_base::openmode openedFor; - + basic_streambuf(); basic_streambuf(const basic_streambuf<char, char_traits<char> > &) @@ -138,7 +138,7 @@ namespace std { return *this; } - + char_type* eback() const { return mgbeg; @@ -204,7 +204,7 @@ namespace std return 0; } - virtual pos_type seekoff(off_type , ios_base::seekdir, + virtual pos_type seekoff(off_type , ios_base::seekdir, ios_base::openmode = ios_base::in | ios_base::out) { return 0; @@ -372,7 +372,7 @@ namespace std return T::to_int_type(c); } - template <class C, class T> basic_streambuf<C, T>::basic_streambuf() + template <class C, class T> basic_streambuf<C, T>::basic_streambuf() : myLocale(), mgbeg(0), mgnext(0), mgend(0), mpbeg(0), mpnext(0), mpend(0), openedFor(0) diff --git a/misc/uClibc++/include/uClibc++/string_iostream b/misc/uClibc++/include/uClibc++/string_iostream index 46a9893c1..1f8dd30ec 100644 --- a/misc/uClibc++/include/uClibc++/string_iostream +++ b/misc/uClibc++/include/uClibc++/string_iostream @@ -119,7 +119,7 @@ template<class charT, class traits, class Allocator> _UCXXEXPORT basic_istream<c str.append(1, c); } - return is; + return is; } template<class charT, class traits, class Allocator> _UCXXEXPORT basic_istream<charT,traits>& @@ -139,7 +139,7 @@ template<> _UCXXEXPORT basic_istream<char, char_traits<char> >& operator>>( #ifdef __UCLIBCXX_EXPAND_OSTREAM_CHAR__ template<> _UCXXEXPORT basic_ostream<char, char_traits<char> >& - operator<<(basic_ostream<char, char_traits<char> >& os, + operator<<(basic_ostream<char, char_traits<char> >& os, const basic_string<char,char_traits<char>, std::allocator<char> >& str); #endif diff --git a/misc/uClibc++/include/uClibc++/typeinfo b/misc/uClibc++/include/uClibc++/typeinfo index 88a2639b8..306f214fd 100644 --- a/misc/uClibc++/include/uClibc++/typeinfo +++ b/misc/uClibc++/include/uClibc++/typeinfo @@ -8,12 +8,12 @@ // it under the terms of the GNU General Public License as published by // the Free Software Foundation; either version 2, or (at your option) // any later version. -// +// // GNU CC is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. -// +// // You should have received a copy of the GNU General Public License // along with GNU CC; see the file COPYING. If not, write to // the Free Software Foundation, 59 Temple Place - Suite 330, @@ -52,7 +52,7 @@ namespace __cxxabiv1 #define __GXX_MERGED_TYPEINFO_NAMES 1 #endif -namespace std +namespace std { /** * @brief Part of RTTI. @@ -60,7 +60,7 @@ namespace std * The @c type_info class describes type information generated by * an implementation. */ - class type_info + class type_info { public: /** Destructor. Being the first non-inline virtual function, this @@ -73,13 +73,13 @@ namespace std /// Assigning type_info is not supported. Made private. type_info& operator=(const type_info&); type_info(const type_info&); - + protected: const char *__name; - + protected: explicit type_info(const char *__n): __name(__n) { } - + public: // the public interface /** Returns an @e implementation-defined byte string; this is not @@ -105,7 +105,7 @@ namespace std #endif bool operator!=(const type_info& __arg) const { return !operator==(__arg); } - + // the internal interface public: // return true if this is a pointer type of some kind @@ -132,7 +132,7 @@ namespace std * * If you attempt an invalid @c dynamic_cast expression, an instance of * this class (or something derived from this class) is thrown. */ - class bad_cast : public exception + class bad_cast : public exception { public: bad_cast() throw() { } @@ -140,9 +140,9 @@ namespace std // http://gcc.gnu.org/onlinedocs/gcc-3.0.2/gcc_6.html#SEC118 virtual ~bad_cast() throw(); }; - + /** If you use a NULL pointer in a @c typeid expression, this is thrown. */ - class bad_typeid : public exception + class bad_typeid : public exception { public: bad_typeid () throw() { } diff --git a/misc/uClibc++/include/uClibc++/unwind-cxx.h b/misc/uClibc++/include/uClibc++/unwind-cxx.h index b0d5b416b..d42c61369 100644 --- a/misc/uClibc++/include/uClibc++/unwind-cxx.h +++ b/misc/uClibc++/include/uClibc++/unwind-cxx.h @@ -1,227 +1,227 @@ -// -*- C++ -*- Exception handling and frame unwind runtime interface routines.
-// Copyright (C) 2001 Free Software Foundation, Inc.
-//
-// This file is part of GCC.
-//
-// GCC is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 2, or (at your option)
-// any later version.
-//
-// GCC is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with GCC; see the file COPYING. If not, write to
-// the Free Software Foundation, 59 Temple Place - Suite 330,
-// Boston, MA 02111-1307, USA.
-
-// As a special exception, you may use this file as part of a free software
-// library without restriction. Specifically, if other files instantiate
-// templates or use macros or inline functions from this file, or you compile
-// this file and link it with other files to produce an executable, this
-// file does not by itself cause the resulting executable to be covered by
-// the GNU General Public License. This exception does not however
-// invalidate any other reasons why the executable file might be covered by
-// the GNU General Public License.
-
-// This is derived from the C++ ABI for IA-64. Where we diverge
-// for cross-architecture compatibility are noted with "@@@".
-
-#ifndef _UNWIND_CXX_H
-#define _UNWIND_CXX_H 1
-
-// Level 2: C++ ABI
-
-#include <typeinfo>
-#include <exception>
-#include <cstddef>
-#include "unwind.h"
-
-#pragma GCC visibility push(default)
-
-namespace __cxxabiv1
-{
-
-// A primary C++ exception object consists of a header, which is a wrapper
-// around an unwind object header with additional C++ specific information,
-// followed by the exception object itself.
-
-struct __cxa_exception
-{
- // Manage the exception object itself.
- std::type_info *exceptionType;
- void (*exceptionDestructor)(void *);
-
- // The C++ standard has entertaining rules wrt calling set_terminate
- // and set_unexpected in the middle of the exception cleanup process.
- std::unexpected_handler unexpectedHandler;
- std::terminate_handler terminateHandler;
-
- // The caught exception stack threads through here.
- __cxa_exception *nextException;
-
- // How many nested handlers have caught this exception. A negated
- // value is a signal that this object has been rethrown.
- int handlerCount;
-
- // Cache parsed handler data from the personality routine Phase 1
- // for Phase 2 and __cxa_call_unexpected.
- int handlerSwitchValue;
- const unsigned char *actionRecord;
- const unsigned char *languageSpecificData;
- _Unwind_Ptr catchTemp;
- void *adjustedPtr;
-
- // The generic exception header. Must be last.
- _Unwind_Exception unwindHeader;
-};
-
-// A dependent C++ exception object consists of a header, which is a wrapper
-// around an unwind object header with additional C++ specific information,
-// followed by the exception object itself.
-
-struct __cxa_dependent_exception
-{
- // The primary exception
- void *primaryException;
-
- // The C++ standard has entertaining rules wrt calling set_terminate
- // and set_unexpected in the middle of the exception cleanup process.
- std::unexpected_handler unexpectedHandler;
- std::terminate_handler terminateHandler;
-
- // The caught exception stack threads through here.
- __cxa_exception *nextException;
-
- // How many nested handlers have caught this exception. A negated
- // value is a signal that this object has been rethrown.
- int handlerCount;
-
- // Cache parsed handler data from the personality routine Phase 1
- // for Phase 2 and __cxa_call_unexpected.
- int handlerSwitchValue;
- const unsigned char *actionRecord;
- const unsigned char *languageSpecificData;
- _Unwind_Ptr catchTemp;
- void *adjustedPtr;
-
- // The generic exception header. Must be last.
- _Unwind_Exception unwindHeader;
-};
-
-// Each thread in a C++ program has access to a __cxa_eh_globals object.
-
-struct __cxa_eh_globals
-{
- __cxa_exception *caughtExceptions;
- unsigned int uncaughtExceptions;
-};
-
-// The __cxa_eh_globals for the current thread can be obtained by using
-// either of the following functions. The "fast" version assumes at least
-// one prior call of __cxa_get_globals has been made from the current
-// thread, so no initialization is necessary.
-
-extern "C" __cxa_eh_globals *__cxa_get_globals () throw();
-extern "C" __cxa_eh_globals *__cxa_get_globals_fast () throw();
-
-// Allocate memory for the primary exception plus the thrown object.
-
-extern "C" void *__cxa_allocate_exception(std::size_t thrown_size) throw();
-
-// Allocate memory for dependent exception.
-
-extern "C" __cxa_dependent_exception *__cxa_allocate_dependent_exception() throw();
-
-// Free the space allocated for the primary exception.
-
-extern "C" void __cxa_free_exception(void *thrown_exception) throw();
-
-// Free the space allocated for the dependent exception.
-
-extern "C" void __cxa_free_dependent_exception(__cxa_dependent_exception *dependent_exception) throw();
-
-// Throw the exception.
-
-extern "C" void __cxa_throw (void *thrown_exception,
- std::type_info *tinfo,
- void (*dest) (void *)) __attribute__((noreturn));
-
-// Used to implement exception handlers.
-
-extern "C" void *__cxa_begin_catch (void *) throw();
-extern "C" void __cxa_end_catch ();
-extern "C" void __cxa_rethrow () __attribute__((noreturn));
-
-// These facilitate code generation for recurring situations.
-
-extern "C" void __cxa_bad_cast ();
-extern "C" void __cxa_bad_typeid ();
-
-// @@@ These are not directly specified by the IA-64 C++ ABI.
-
-// Handles re-checking the exception specification if unexpectedHandler
-// throws, and if bad_exception needs to be thrown. Called from the
-// compiler.
-
-extern "C" void __cxa_call_unexpected (void *) __attribute__((noreturn));
-
-// Invokes given handler, dying appropriately if the user handler was
-// so inconsiderate as to return.
-
-extern void __terminate(std::terminate_handler) __attribute__((noreturn));
-extern void __unexpected(std::unexpected_handler) __attribute__((noreturn));
-
-// The current installed user handlers.
-
-extern std::terminate_handler __terminate_handler;
-extern std::unexpected_handler __unexpected_handler;
-
-// These are explicitly GNU C++ specific.
-
-// This is the exception class we report -- "GNUCC++\0".
-
-const _Unwind_Exception_Class __gxx_exception_class =
- ((((((((_Unwind_Exception_Class) 'G'
- << 8 | (_Unwind_Exception_Class) 'N')
- << 8 | (_Unwind_Exception_Class) 'U')
- << 8 | (_Unwind_Exception_Class) 'C')
- << 8 | (_Unwind_Exception_Class) 'C')
- << 8 | (_Unwind_Exception_Class) '+')
- << 8 | (_Unwind_Exception_Class) '+')
- << 8 | (_Unwind_Exception_Class) '\0');
-
-// GNU C++ personality routine, Version 0.
-
-extern "C" _Unwind_Reason_Code __gxx_personality_v0
- (int, _Unwind_Action, _Unwind_Exception_Class,
- struct _Unwind_Exception *, struct _Unwind_Context *);
-
-// GNU C++ sjlj personality routine, Version 0.
-
-extern "C" _Unwind_Reason_Code __gxx_personality_sj0
- (int, _Unwind_Action, _Unwind_Exception_Class,
- struct _Unwind_Exception *, struct _Unwind_Context *);
-
-// Acquire the C++ exception header from the C++ object.
-
-static inline __cxa_exception *__get_exception_header_from_obj (void *ptr)
-{
- return reinterpret_cast<__cxa_exception *>(ptr) - 1;
-}
-
-// Acquire the C++ exception header from the generic exception header.
-
-static inline __cxa_exception *__get_exception_header_from_ue (_Unwind_Exception *exc)
-{
- return reinterpret_cast<__cxa_exception *>(exc + 1) - 1;
-}
-
-} /* namespace __cxxabiv1 */
-
-#pragma GCC visibility pop
-
-#endif // _UNWIND_CXX_H
+// -*- C++ -*- Exception handling and frame unwind runtime interface routines. +// Copyright (C) 2001 Free Software Foundation, Inc. +// +// This file is part of GCC. +// +// GCC is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// GCC is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with GCC; see the file COPYING. If not, write to +// the Free Software Foundation, 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// This is derived from the C++ ABI for IA-64. Where we diverge +// for cross-architecture compatibility are noted with "@@@". + +#ifndef _UNWIND_CXX_H +#define _UNWIND_CXX_H 1 + +// Level 2: C++ ABI + +#include <typeinfo> +#include <exception> +#include <cstddef> +#include "unwind.h" + +#pragma GCC visibility push(default) + +namespace __cxxabiv1 +{ + +// A primary C++ exception object consists of a header, which is a wrapper +// around an unwind object header with additional C++ specific information, +// followed by the exception object itself. + +struct __cxa_exception +{ + // Manage the exception object itself. + std::type_info *exceptionType; + void (*exceptionDestructor)(void *); + + // The C++ standard has entertaining rules wrt calling set_terminate + // and set_unexpected in the middle of the exception cleanup process. + std::unexpected_handler unexpectedHandler; + std::terminate_handler terminateHandler; + + // The caught exception stack threads through here. + __cxa_exception *nextException; + + // How many nested handlers have caught this exception. A negated + // value is a signal that this object has been rethrown. + int handlerCount; + + // Cache parsed handler data from the personality routine Phase 1 + // for Phase 2 and __cxa_call_unexpected. + int handlerSwitchValue; + const unsigned char *actionRecord; + const unsigned char *languageSpecificData; + _Unwind_Ptr catchTemp; + void *adjustedPtr; + + // The generic exception header. Must be last. + _Unwind_Exception unwindHeader; +}; + +// A dependent C++ exception object consists of a header, which is a wrapper +// around an unwind object header with additional C++ specific information, +// followed by the exception object itself. + +struct __cxa_dependent_exception +{ + // The primary exception + void *primaryException; + + // The C++ standard has entertaining rules wrt calling set_terminate + // and set_unexpected in the middle of the exception cleanup process. + std::unexpected_handler unexpectedHandler; + std::terminate_handler terminateHandler; + + // The caught exception stack threads through here. + __cxa_exception *nextException; + + // How many nested handlers have caught this exception. A negated + // value is a signal that this object has been rethrown. + int handlerCount; + + // Cache parsed handler data from the personality routine Phase 1 + // for Phase 2 and __cxa_call_unexpected. + int handlerSwitchValue; + const unsigned char *actionRecord; + const unsigned char *languageSpecificData; + _Unwind_Ptr catchTemp; + void *adjustedPtr; + + // The generic exception header. Must be last. + _Unwind_Exception unwindHeader; +}; + +// Each thread in a C++ program has access to a __cxa_eh_globals object. + +struct __cxa_eh_globals +{ + __cxa_exception *caughtExceptions; + unsigned int uncaughtExceptions; +}; + +// The __cxa_eh_globals for the current thread can be obtained by using +// either of the following functions. The "fast" version assumes at least +// one prior call of __cxa_get_globals has been made from the current +// thread, so no initialization is necessary. + +extern "C" __cxa_eh_globals *__cxa_get_globals () throw(); +extern "C" __cxa_eh_globals *__cxa_get_globals_fast () throw(); + +// Allocate memory for the primary exception plus the thrown object. + +extern "C" void *__cxa_allocate_exception(std::size_t thrown_size) throw(); + +// Allocate memory for dependent exception. + +extern "C" __cxa_dependent_exception *__cxa_allocate_dependent_exception() throw(); + +// Free the space allocated for the primary exception. + +extern "C" void __cxa_free_exception(void *thrown_exception) throw(); + +// Free the space allocated for the dependent exception. + +extern "C" void __cxa_free_dependent_exception(__cxa_dependent_exception *dependent_exception) throw(); + +// Throw the exception. + +extern "C" void __cxa_throw (void *thrown_exception, + std::type_info *tinfo, + void (*dest) (void *)) __attribute__((noreturn)); + +// Used to implement exception handlers. + +extern "C" void *__cxa_begin_catch (void *) throw(); +extern "C" void __cxa_end_catch (); +extern "C" void __cxa_rethrow () __attribute__((noreturn)); + +// These facilitate code generation for recurring situations. + +extern "C" void __cxa_bad_cast (); +extern "C" void __cxa_bad_typeid (); + +// @@@ These are not directly specified by the IA-64 C++ ABI. + +// Handles re-checking the exception specification if unexpectedHandler +// throws, and if bad_exception needs to be thrown. Called from the +// compiler. + +extern "C" void __cxa_call_unexpected (void *) __attribute__((noreturn)); + +// Invokes given handler, dying appropriately if the user handler was +// so inconsiderate as to return. + +extern void __terminate(std::terminate_handler) __attribute__((noreturn)); +extern void __unexpected(std::unexpected_handler) __attribute__((noreturn)); + +// The current installed user handlers. + +extern std::terminate_handler __terminate_handler; +extern std::unexpected_handler __unexpected_handler; + +// These are explicitly GNU C++ specific. + +// This is the exception class we report -- "GNUCC++\0". + +const _Unwind_Exception_Class __gxx_exception_class = + ((((((((_Unwind_Exception_Class) 'G' + << 8 | (_Unwind_Exception_Class) 'N') + << 8 | (_Unwind_Exception_Class) 'U') + << 8 | (_Unwind_Exception_Class) 'C') + << 8 | (_Unwind_Exception_Class) 'C') + << 8 | (_Unwind_Exception_Class) '+') + << 8 | (_Unwind_Exception_Class) '+') + << 8 | (_Unwind_Exception_Class) '\0'); + +// GNU C++ personality routine, Version 0. + +extern "C" _Unwind_Reason_Code __gxx_personality_v0 + (int, _Unwind_Action, _Unwind_Exception_Class, + struct _Unwind_Exception *, struct _Unwind_Context *); + +// GNU C++ sjlj personality routine, Version 0. + +extern "C" _Unwind_Reason_Code __gxx_personality_sj0 + (int, _Unwind_Action, _Unwind_Exception_Class, + struct _Unwind_Exception *, struct _Unwind_Context *); + +// Acquire the C++ exception header from the C++ object. + +static inline __cxa_exception *__get_exception_header_from_obj (void *ptr) +{ + return reinterpret_cast<__cxa_exception *>(ptr) - 1; +} + +// Acquire the C++ exception header from the generic exception header. + +static inline __cxa_exception *__get_exception_header_from_ue (_Unwind_Exception *exc) +{ + return reinterpret_cast<__cxa_exception *>(exc + 1) - 1; +} + +} /* namespace __cxxabiv1 */ + +#pragma GCC visibility pop + +#endif // _UNWIND_CXX_H diff --git a/misc/uClibc++/include/uClibc++/utility b/misc/uClibc++/include/uClibc++/utility index f5cb59f2f..30c6525ae 100644 --- a/misc/uClibc++/include/uClibc++/utility +++ b/misc/uClibc++/include/uClibc++/utility @@ -28,7 +28,7 @@ extern "C++" namespace std { - namespace rel_ops + namespace rel_ops { template<class T> inline bool operator!=(const T& x, const T& y) { @@ -62,7 +62,7 @@ namespace std pair(const T1& x, const T2& y) : first(x), second(y) { } template<class U, class V> pair(const pair<U, V> &p) : first(p.first), second(p.second) { } }; - + template <class T1, class T2> bool operator==(const pair<T1,T2>& x, const pair<T1,T2>& y) { using namespace rel_ops; diff --git a/misc/uClibc++/include/uClibc++/valarray b/misc/uClibc++/include/uClibc++/valarray index f28ad5874..dbbadcb56 100644 --- a/misc/uClibc++/include/uClibc++/valarray +++ b/misc/uClibc++/include/uClibc++/valarray @@ -797,8 +797,8 @@ namespace std void operator|=(const valarray<T>& array) const; void operator<<=(const valarray<T>& array) const; void operator>>=(const valarray<T>& array) const; - - void operator=(const T&); + + void operator=(const T&); private: gslice_array(); diff --git a/misc/uClibc++/include/uClibc++/vector b/misc/uClibc++/include/uClibc++/vector index 88adbd011..25845b87d 100644 --- a/misc/uClibc++/include/uClibc++/vector +++ b/misc/uClibc++/include/uClibc++/vector @@ -42,7 +42,7 @@ namespace std template <class T, class Allocator> bool operator<=(const vector<T,Allocator>& x, const vector<T,Allocator>& y); template <class T, class Allocator> void swap(vector<T,Allocator>& x, vector<T,Allocator>& y); - template <class T, class Allocator> class _UCXXEXPORT vector + template <class T, class Allocator> class _UCXXEXPORT vector { public: |