call.c (build_user_type_conversion_1): Do set ICS_BAD_FLAG if all the ambiguous conversions are bad.

* call.c (build_user_type_conversion_1): Do set ICS_BAD_FLAG if
        all the ambiguous conversions are bad.

From-SVN: r61249
This commit is contained in:
Jason Merrill 2003-01-13 04:16:06 -05:00
parent e1dfc61b5b
commit 970684896d
1 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,22 @@
// Bug: g++ thought that the QChar overload was a viable but ambiguous
// candidate. It isn't viable, because there's no conversion from const
// char * to QChar.
class QChar {
public:
QChar( char c );
QChar( unsigned char c );
};
class QString
{
public:
QString( const char *str ); // deep copy
QString &insert( unsigned int index, const QString & );
QString &insert( unsigned int index, QChar );
QString &prepend( const char* );
};
inline QString &QString::prepend( const char* s )
{ return insert(0,s); }