This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54807] New: Names declared in a for's for-init-statement and condition should be in the same declarative region
- From: "ulfalizer at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 04 Oct 2012 04:51:27 +0000
- Subject: [Bug c++/54807] New: Names declared in a for's for-init-statement and condition should be in the same declarative region
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54807
Bug #: 54807
Summary: Names declared in a for's for-init-statement and
condition should be in the same declarative region
Classification: Unclassified
Product: gcc
Version: 4.6.3
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: ulfalizer@gmail.com
for (int i; int i = 0;) should give an error but currently doesn't.
14882:2003 6.5.3.1: "...except that names declared in the for-init-statement
are in the same declarative-region as those declared in the condition".