libstdc++/2020
benjamin kosnik
bkoz@nabi.net
Sun Apr 1 00:00:00 GMT 2001
The following reply was made to PR libstdc++/2020; it has been noted by GNATS.
From: benjamin kosnik <bkoz@nabi.net>
To: gcc-gnats@gcc.gnu.org, bumgard@roguewave.com, nobody@gcc.gnu.org
Cc:
Subject: Re: libstdc++/2020
Date: Mon, 12 Mar 2001 15:13:06 -0800
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view&pr=2020&database=gcc
here's the testcase:
// libstdc++/2020
#include <fstream>
class gnu_char_type
{
unsigned long character;
public:
// operator ==
bool
operator==(const gnu_char_type& __lhs)
{ return character == __lhs.character; }
// operator <
bool
operator<(const gnu_char_type& __lhs)
{ return character < __lhs.character; }
// to_char_type
gnu_char_type(const unsigned long& __l) : character(__l) { }
// to_int_type
operator unsigned long() const { return character; }
};
void test01()
{
typedef std::basic_filebuf<gnu_char_type> gnu_filebuf;
gnu_filebuf obj;
}
int main()
{
test01();
return 0;
}
More information about the Gcc-prs
mailing list