OSDN Git Service

Remove trailing whitespace (see ChangeLog for longwinded description).
[pf3gnuchains/gcc-fork.git] / libstdc++-v3 / include / bits / ostream.tcc
index c8f7fc7..1ff14a6 100644 (file)
@@ -39,7 +39,7 @@
 
 #include <locale>
 
-namespace std 
+namespace std
 {
   template<typename _CharT, typename _Traits>
     basic_ostream<_CharT, _Traits>::sentry::
@@ -58,9 +58,9 @@ namespace std
          __os.setstate(ios_base::failbit);
        }
     }
-  
+
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(__ostream_type& (*__pf)(__ostream_type&))
     {
@@ -69,9 +69,9 @@ namespace std
       // The inserters for manipulators are *not* formatted output functions.
       return __pf(*this);
     }
-  
+
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(__ios_type& (*__pf)(__ios_type&))
     {
@@ -83,7 +83,7 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(ios_base& (*__pf)(ios_base&))
     {
@@ -95,15 +95,15 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(bool __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -118,15 +118,15 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(long __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              bool __b = false;
              char_type __c = this->fill();
@@ -139,7 +139,7 @@ namespace std
                }
              else
                __b = __np.put(*this, *this, __c, __n).failed();
-             if (__b)  
+             if (__b)
                __err |= ios_base::badbit;
            }
          catch(...)
@@ -151,15 +151,15 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(unsigned long __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -175,15 +175,15 @@ namespace std
 
 #ifdef _GLIBCXX_USE_LONG_LONG
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(long long __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              bool __b = false;
              char_type __c = this->fill();
@@ -197,7 +197,7 @@ namespace std
                }
              else
                __b = __np.put(*this, *this, __c, __n).failed();
-             if (__b)  
+             if (__b)
                __err |= ios_base::badbit;
            }
          catch(...)
@@ -209,15 +209,15 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(unsigned long long __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -231,17 +231,17 @@ namespace std
       return *this;
     }
 #endif
-  
+
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(double __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -254,17 +254,17 @@ namespace std
        }
       return *this;
     }
-  
+
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(long double __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -279,15 +279,15 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(const void* __n)
     {
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
-         try 
+         try
            {
              const __num_put_type& __np = __check_facet(this->_M_num_put);
              if (__np.put(*this, *this, this->fill(), __n).failed())
@@ -302,7 +302,7 @@ namespace std
     }
 
   template<typename _CharT, typename _Traits>
-    basic_ostream<_CharT, _Traits>& 
+    basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     operator<<(__streambuf_type* __sbin)
     {
@@ -329,7 +329,7 @@ namespace std
     basic_ostream<_CharT, _Traits>&
     basic_ostream<_CharT, _Traits>::
     put(char_type __c)
-    { 
+    {
       // _GLIBCXX_RESOLVE_LIB_DEFECTS
       // DR 60. What is a formatted input function?
       // basic_ostream::put(char_type) is an unformatted output function.
@@ -337,12 +337,12 @@ namespace std
       // Unformatted output functions should catch exceptions thrown
       // from streambuf members.
       sentry __cerb(*this);
-      if (__cerb) 
+      if (__cerb)
        {
          ios_base::iostate __err = ios_base::iostate(ios_base::goodbit);
          try
            {
-             int_type __put = this->rdbuf()->sputc(__c); 
+             int_type __put = this->rdbuf()->sputc(__c);
              if (traits_type::eq_int_type(__put, traits_type::eof()))
                __err |= ios_base::badbit;
            }
@@ -351,7 +351,7 @@ namespace std
          if (__err)
            this->setstate(__err);
        }
-      return *this;  
+      return *this;
     }
 
   template<typename _CharT, typename _Traits>
@@ -397,7 +397,7 @@ namespace std
        this->setstate(__err);
       return *this;
     }
-  
+
   template<typename _CharT, typename _Traits>
     typename basic_ostream<_CharT, _Traits>::pos_type
     basic_ostream<_CharT, _Traits>::
@@ -427,7 +427,7 @@ namespace std
              // _GLIBCXX_RESOLVE_LIB_DEFECTS
              // 136.  seekp, seekg setting wrong streams?
              pos_type __p = this->rdbuf()->pubseekpos(__pos, ios_base::out);
-             
+
              // 129. Need error indication from seekp() and seekg()
              if (__p == pos_type(off_type(-1)))
                __err |= ios_base::failbit;
@@ -452,9 +452,9 @@ namespace std
            {
              // _GLIBCXX_RESOLVE_LIB_DEFECTS
              // 136.  seekp, seekg setting wrong streams?
-             pos_type __p = this->rdbuf()->pubseekoff(__off, __dir, 
+             pos_type __p = this->rdbuf()->pubseekoff(__off, __dir,
                                                       ios_base::out);
-             
+
              // 129. Need error indication from seekp() and seekg()
              if (__p == pos_type(off_type(-1)))
                __err |= ios_base::failbit;
@@ -476,7 +476,7 @@ namespace std
       typename __ostream_type::sentry __cerb(__out);
       if (__cerb)
        {
-         try 
+         try
            {
              const streamsize __w = __out.width();
              streamsize __len = 1;
@@ -485,7 +485,7 @@ namespace std
                {
                  __cs = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT)
                                                               * __w));
-                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs, 
+                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs,
                                                 &__c, __w, __len, false);
                  __len = __w;
                }
@@ -497,9 +497,9 @@ namespace std
        }
       return __out;
     }
-  
+
   // Specializations.
-  template <class _Traits> 
+  template <class _Traits>
     basic_ostream<char, _Traits>&
     operator<<(basic_ostream<char, _Traits>& __out, char __c)
     {
@@ -507,7 +507,7 @@ namespace std
       typename __ostream_type::sentry __cerb(__out);
       if (__cerb)
        {
-         try 
+         try
            {
              const streamsize __w = __out.width();
              streamsize __len = 1;
@@ -515,7 +515,7 @@ namespace std
              if (__w > __len)
                {
                  __cs = static_cast<char*>(__builtin_alloca(__w));
-                 __pad<char, _Traits>::_S_pad(__out, __out.fill(), __cs, 
+                 __pad<char, _Traits>::_S_pad(__out, __out.fill(), __cs,
                                               &__c, __w, __len, false);
                  __len = __w;
                }
@@ -536,7 +536,7 @@ namespace std
       typename __ostream_type::sentry __cerb(__out);
       if (__cerb && __s)
        {
-         try 
+         try
            {
              const streamsize __w = __out.width();
              streamsize __len = static_cast<streamsize>(_Traits::length(__s));
@@ -544,7 +544,7 @@ namespace std
                {
                  _CharT* __cs = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT)
                                                                       * __w));
-                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs, 
+                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs,
                                                 __s, __w, __len, false);
                  __s = __cs;
                  __len = __w;
@@ -578,8 +578,8 @@ namespace std
          for (size_t  __i = 0; __i < __clen; ++__i)
            __ws[__i] = __out.widen(__s[__i]);
          _CharT* __str = __ws;
-         
-         try 
+
+         try
            {
              const streamsize __w = __out.width();
              streamsize __len = static_cast<streamsize>(__clen);
@@ -587,7 +587,7 @@ namespace std
                {
                  _CharT* __cs = static_cast<_CharT*>(__builtin_alloca(sizeof(_CharT)
                                                                       * __w));
-                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs, 
+                 __pad<_CharT, _Traits>::_S_pad(__out, __out.fill(), __cs,
                                                 __ws, __w, __len, false);
                  __str = __cs;
                  __len = __w;
@@ -612,14 +612,14 @@ namespace std
       typename __ostream_type::sentry __cerb(__out);
       if (__cerb && __s)
        {
-         try 
+         try
            {
              const streamsize __w = __out.width();
              streamsize __len = static_cast<streamsize>(_Traits::length(__s));
              if (__w > __len)
                {
                  char* __cs = static_cast<char*>(__builtin_alloca(__w));
-                 __pad<char, _Traits>::_S_pad(__out, __out.fill(), __cs, 
+                 __pad<char, _Traits>::_S_pad(__out, __out.fill(), __cs,
                                                 __s, __w, __len, false);
                  __s = __cs;
                  __len = __w;
@@ -640,7 +640,7 @@ namespace std
     basic_ostream<_CharT, _Traits>&
     operator<<(basic_ostream<_CharT, _Traits>& __out,
               const basic_string<_CharT, _Traits, _Alloc>& __str)
-    { 
+    {
       typedef basic_ostream<_CharT, _Traits> __ostream_type;
       typename __ostream_type::sentry __cerb(__out);
       if (__cerb)
@@ -666,7 +666,7 @@ namespace std
     }
 
   // Inhibit implicit instantiations for required instantiations,
-  // which are defined via explicit instantiations elsewhere.  
+  // which are defined via explicit instantiations elsewhere.
   // NB:  This syntax is a GNU extension.
 #if _GLIBCXX_EXTERN_TEMPLATE
   extern template class basic_ostream<char>;