This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug pending/19514] bogus warning about complex "integer" types from typedef
- From: "stevenj at fftw dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Jan 2005 22:56:58 -0000
- Subject: [Bug pending/19514] bogus warning about complex "integer" types from typedef
- References: <20050118220248.19514.stevenj@ab-initio.mit.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From stevenj at fftw dot org 2005-01-18 22:56 -------
Subject: Re: bogus warning about complex "integer" types
from typedef
On Tue, 18 Jan 2005, joseph at codesourcery dot com wrote:
>> typedef double R;
>> typedef R _Complex C;
>
> This is not valid code; you can't use _Complex together with a typedef,
> only together with "float", "double" or "long double" in one of the forms
> listed in C99.
My copy of the C99 draft standard states (sec. 6.7.7):
"A typedef declaration does not introduce a new type, only a
synonym for the type so specified."
According to this, "R complex" should be a synonym for "double complex",
and therefore should be valid code. What justification do you have for
claiming otherwise?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19514