diff options
author | Bryce McKinlay <bryce@waitaki.otago.ac.nz> | 2001-10-09 05:40:35 +0000 |
---|---|---|
committer | Bryce McKinlay <bryce@gcc.gnu.org> | 2001-10-09 06:40:35 +0100 |
commit | 908fecca8cba9118747951b2d9883b8abd4a94b6 (patch) | |
tree | e0885f9bb8a52f27cfe66b51168538ae2a077f04 /gcc/java | |
parent | 3c017635c9012494cd6aaf7af315653aa06261bf (diff) | |
download | gcc-908fecca8cba9118747951b2d9883b8abd4a94b6.zip gcc-908fecca8cba9118747951b2d9883b8abd4a94b6.tar.gz gcc-908fecca8cba9118747951b2d9883b8abd4a94b6.tar.bz2 |
parse.y (find_as_inner_class): Don't disregard the enclosing scope when name qualifier matches a package name.
* parse.y (find_as_inner_class): Don't disregard the enclosing scope
when name qualifier matches a package name.
From-SVN: r46113
Diffstat (limited to 'gcc/java')
-rw-r--r-- | gcc/java/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/java/parse.y | 13 |
2 files changed, 6 insertions, 12 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index 52ccdab..d32998b 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,8 @@ +2001-10-09 Bryce McKinlay <bryce@waitaki.otago.ac.nz> + + * parse.y (find_as_inner_class): Don't disregard the enclosing scope + when name qualifier matches a package name. + 2001-10-08 Tom Tromey <tromey@redhat.com> Fix for PR java/4489: diff --git a/gcc/java/parse.y b/gcc/java/parse.y index 2737579..180b99d 100644 --- a/gcc/java/parse.y +++ b/gcc/java/parse.y @@ -3636,18 +3636,7 @@ find_as_inner_class (enclosing, name, cl) acc = merge_qualified_name (acc, EXPR_WFL_NODE (TREE_PURPOSE (qual))); BUILD_PTR_FROM_NAME (ptr, acc); - - /* Don't try to resolve ACC as a class name if it follows - the current package name. We don't want to pick something - that's accidentally there: for example `a.b.c' in package - `a.b' shouldn't trigger loading `a' if it's there by - itself. */ - if (ctxp->package - && strstr (IDENTIFIER_POINTER (ctxp->package), - IDENTIFIER_POINTER (acc))) - decl = NULL; - else - decl = do_resolve_class (NULL_TREE, ptr, NULL_TREE, cl); + decl = do_resolve_class (NULL_TREE, ptr, NULL_TREE, cl); } /* A NULL qual and a decl means that the search ended |