June 15, 2003 conversion function: illegal operand types | ||||
---|---|---|---|---|
| ||||
struct A
{
operator unsigned short() const
{
return 0;
}
};
struct B
: public A
{
operator unsigned short() const
{
return 0;
}
};
int main()
{
B b;
return 0 < b;
// Error: illegal operand types
// Had: int
// and: B
}
Extracted from Boost's date_time library.
bye, Christof
--
http://cmeerw.org JID: cmeerw@jabber.at mailto cmeerw at web.de
...and what have you contributed to the Net?
|
Copyright © 1999-2021 by the D Language Foundation