re PR objc/7993 (private variables cannot be shadowed in subclasses)
authorNicola Pero <nicola@brainstorm.co.uk>
Tue, 1 Jun 2004 07:40:02 +0000 (07:40 +0000)
committerZack Weinberg <zack@gcc.gnu.org>
Tue, 1 Jun 2004 07:40:02 +0000 (07:40 +0000)
commit61c627ed2c1b7184807d2101ab2d288e9ca4f39b
tree139086f8092179d1478c674d6dd17965d6d53178
parentd314442396916fa65739d6baeb24b2f0cfc76634
re PR objc/7993 (private variables cannot be shadowed in subclasses)

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.

From-SVN: r82532
gcc/ChangeLog
gcc/objc/objc-act.c
gcc/testsuite/ChangeLog
gcc/testsuite/objc.dg/private-1.m [new file with mode: 0644]
gcc/testsuite/objc.dg/private-2.m [new file with mode: 0644]