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]

Re: Strange pedantic error message




On Thu, 8 Feb 2001, Fergus Henderson wrote:
>
> It means that in a conditional expression `x ? y : z',
> ANSI C does not allow just one of `x' and `y' to have type `void'.
> They can both be `void', or they can both not be `void',
> but if only one of them has type `void', that is not allowed.
> 

Aha!  Yes, that' s the answer - I had a conditional expression involving
library calls inside the 'else'-less 'if' statements I thought were
causing the error, but it was wrapped up in a macro, so I didn't spot it.

Thanks, (hopefully Google will index this thread so that others won't be
as confused as me in the future :-)

Jamie.


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