This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: istringstream.rdbuf with custom streambuf does not compile


The member function 'basic_streambuf<charT,traits>* rdbuf(basic_streambuf<charT,traits>* sb)' of class template basic_ios is hidden *intentionally*.

ISO/IEC WG21 (Working Draft, Standard for Programming Language C++) N4582:
[quote]
27.8 String-based streams [string.streams]
27.8.3 Class template basic_istringstream [istringstream]
namespace std {
template <class charT, class traits = char_traits<charT>,
    class Allocator = allocator<charT> >
class basic_istringstream : public basic_istream<charT,traits> {
public:
(... omitted ...)
  // 27.8.3.3 Members:
  basic_stringbuf<charT,traits,Allocator>* rdbuf() const;
(... omitted ...)
};
[/quote]

The function taking no parameters is the only overload required by the standard. It isn't a GCC bug.

------------------				 
Best regards,
lh_mouse
2016-05-06


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]