Canonicalization of function pointers
John David Anglin
dave@hiauly1.hia.nrc.ca
Fri Nov 22 11:24:00 GMT 2002
> "John David Anglin" <dave@hiauly1.hia.nrc.ca> writes:
>
> |> The code snippet below demonstrates a problem in comparing a void *
> |> to a function pointer. I believe this is a gcc extension and is not
> |> allowed in ISO C.
>
> Yes, it is even a constraint violation:
>
> 6.5.9 Equality operators
Yes. I had read this section prior to sending the message. Gcc seems
to be following the conversion specified in paragraph 5 but this doesn't
make any sense for function pointers which need canonicalization.
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
More information about the Gcc
mailing list