This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug objc/7993] [3.4/3.5 regression] private variables cannot be shadowed in subclasses
- From: "cvs-commit at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 1 Jun 2004 07:40:15 -0000
- Subject: [Bug objc/7993] [3.4/3.5 regression] private variables cannot be shadowed in subclasses
- References: <20020920175601.7993.lminder@gmx.net>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-06-01 07:40 -------
Subject: Bug 7993
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: zack@gcc.gnu.org 2004-06-01 07:40:03
Modified files:
gcc : ChangeLog
gcc/objc : objc-act.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/objc.dg: private-1.m private-2.m
Log message:
2004-06-01 Nicola Pero <nicola@brainstorm.co.uk>
Fix PR objc/7993:
* objc-act.c (is_private): Do not emit the 'instance variable %s
is declared private' error.
(is_public): Emit the error after calling is_private.
(lookup_objc_ivar): If the instance variable is private, return 0
- the instance variable is invisible here.
testsuite:
* objc.dg/private-1.m, objc-dg/private-2.m: New testcases.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.3811&r2=2.3812
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/objc/objc-act.c.diff?cvsroot=gcc&r1=1.214&r2=1.215
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.3800&r2=1.3801
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/objc.dg/private-1.m.diff?cvsroot=gcc&r1=1.1&r2=1.2
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/objc.dg/private-2.m.diff?cvsroot=gcc&r1=1.1&r2=1.2
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7993