summaryrefslogtreecommitdiffstats
path: root/gcc/java/typeck.c
diff options
context:
space:
mode:
authorapbianco <apbianco@138bc75d-0d04-0410-961f-82ee72b054a4>1999-12-30 22:36:25 +0000
committerapbianco <apbianco@138bc75d-0d04-0410-961f-82ee72b054a4>1999-12-30 22:36:25 +0000
commita2cad990a216ca3a96d5675c232332f088a1ef45 (patch)
tree9853301b4a969ce1435d6529c461d2f6510bc73a /gcc/java/typeck.c
parent7df26e929ae1dc262282ed4f996606d45c4c78f6 (diff)
downloadppe42-gcc-a2cad990a216ca3a96d5675c232332f088a1ef45.tar.gz
ppe42-gcc-a2cad990a216ca3a96d5675c232332f088a1ef45.zip
1999-12-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
* class.c (class_depth): Return -1 if the class doesn't load properly. * expr.c (can_widen_reference_to): Check for errors during depth computation and return 0 accordingly. * jcf-parse.c (parse_source_file): Call java_fix_constructors to create default constructors and add an other error check. * parse.h (java_fix_constructors): Prototyped. * parse.y (java_pre_expand_clinit): Likewise. (build_super_invocation): Re-prototyped to feature one argument. (java_check_circular_reference): Directly use `current'. (java_fix_constructors): New function. (java_check_regular_methods): Don't create default constructors here, but abort if none were found. (java_complete_expand_methods): Pre-process <clinit> calling java_pre_expand_clinit. (java_pre_expand_clinit): New function. (fix_constructors): build_super_invocation invoked with the current method declaration as an argument. (build_super_invocation): Use the context of the processed method decl argument instead of current_class. * typeck.c (lookup_java_method): Take WFLs in method names into account. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31144 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java/typeck.c')
-rw-r--r--gcc/java/typeck.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/java/typeck.c b/gcc/java/typeck.c
index 331de1c9fb6..213a3899fbc 100644
--- a/gcc/java/typeck.c
+++ b/gcc/java/typeck.c
@@ -755,7 +755,10 @@ lookup_java_method (searched_class, method_name, method_signature)
method != NULL_TREE; method = TREE_CHAIN (method))
{
tree method_sig = build_java_signature (TREE_TYPE (method));
- if (DECL_NAME (method) == method_name
+ tree name = DECL_NAME (method);
+
+ if ((TREE_CODE (name) == EXPR_WITH_FILE_LOCATION ?
+ EXPR_WFL_NODE (name) : name) == method_name
&& method_sig == method_signature)
return method;
}
@@ -788,8 +791,10 @@ lookup_java_method (searched_class, method_name, method_signature)
method != NULL_TREE; method = TREE_CHAIN (method))
{
tree method_sig = build_java_signature (TREE_TYPE (method));
+ tree name = DECL_NAME (method);
- if (DECL_NAME (method) == method_name
+ if ((TREE_CODE (name) == EXPR_WITH_FILE_LOCATION ?
+ EXPR_WFL_NODE (name) : name) == method_name
&& method_sig == method_signature)
return method;
}
OpenPOWER on IntegriCloud