diff options
| author | nickc <nickc@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-05-14 17:09:34 +0000 |
|---|---|---|
| committer | nickc <nickc@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-05-14 17:09:34 +0000 |
| commit | 7bf4741d80abb671c5d13b416f688a97f69c17d8 (patch) | |
| tree | c49b504ede3c538726169a571f1842028a54eae8 /gcc/cp/decl.c | |
| parent | 6c52fa55a62076066e792d5d1dc7811fbfe162e3 (diff) | |
| download | ppe42-gcc-7bf4741d80abb671c5d13b416f688a97f69c17d8.tar.gz ppe42-gcc-7bf4741d80abb671c5d13b416f688a97f69c17d8.zip | |
Suppress warning about duplicate decls if the first decl is a friend.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@42073 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/decl.c')
| -rw-r--r-- | gcc/cp/decl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 54d84f47ddd..ee5c279a3f6 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -3457,7 +3457,7 @@ duplicate_decls (newdecl, olddecl) /* Don't warn about extern decl followed by definition. */ && !(DECL_EXTERNAL (olddecl) && ! DECL_EXTERNAL (newdecl)) /* Don't warn about friends, let add_friend take care of it. */ - && ! DECL_FRIEND_P (newdecl)) + && ! (DECL_FRIEND_P (newdecl) || DECL_FRIEND_P (olddecl))) { cp_warning ("redundant redeclaration of `%D' in same scope", newdecl); cp_warning_at ("previous declaration of `%D'", olddecl); |

