[Bug c/67784] New: Incorrect parsing when using declarations in for loops and typedefs
jacques-henri.jourdan at inria dot Fr
gcc-bugzilla@gcc.gnu.org
Wed Sep 30 14:14:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67784
Bug ID: 67784
Summary: Incorrect parsing when using declarations in for loops
and typedefs
Product: gcc
Version: 5.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: jacques-henri.jourdan at inria dot Fr
Target Milestone: ---
The following code snippet does not parse correctly:
typedef int T;
void h() {
for(int T; ;)
if(1)
;
T *x;
x = 0;
}
However, this one does:
typedef int T;
void h() {
for(int T; ;)
if(1)
;
;
T *x;
x = 0;
}
More information about the Gcc-bugs
mailing list