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]

Re: Call of overloaded function is ambiguous ?




On Fri, 15 Mar 2002, Joe.Buck@synopsys.com (Joe Buck) wrote:
> Date: Fri, 15 Mar 2002 12:23:32 -0800 (PST)
> To: ude@handshake.de
> From: Joe.Buck@synopsys.com (Joe Buck)
> CC: gcc@gcc.gnu.org
> Subject: Re: Call of overloaded function is ambiguous ?

[...]

> Yes.  The code contains an error; all C++ compilers that conform to
> the standard will give the same error.  The scoring system used in
> the language rules considers both candidates to be equally good matches.

That's clear to me - but why the different treatment of signed and unsigned
integers ? Remember that the following did not cause any warning:

/* [...] */

void f ( int ) { }
void f ( void * ) { }

int main ( void )
{
  f ( 0 ) ;

  return 0 ;
}

/* [...] */


- Sebastian


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