This is the mail archive of the gcc@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]

C++ Standard Question


Hi

I think this is a glibc issue but since this method is defined in the C++
standards, I thought there were plenty of language lawyers here. :)

<strstream>
   class strstreambuf : public basic_streambuf<char, char_traits<char> >
   ISSUE ====> int pcount() const;   <===== ISSUE

My reading of the C++03 and draft C++14 says that the int pcount() method
in this class is not const. glibc has it const in the glibc shipped with
Fedora 20
and CentOS 6.

This is a simple test case:

    #include <strstream>

    int main() {
        int (std::strstreambuf::*dummy)() = &std::strstreambuf::pcount; 
/*-- pcount is conformant --*/
        return 0;
    }

What's the consensus?

Thanks.

-- 
Joel Sherrill, Ph.D.             Director of Research & Development
joel.sherrill@OARcorp.com        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
Support Available                (256) 722-9985



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