summaryrefslogtreecommitdiff
path: root/gcc/java
diff options
context:
space:
mode:
authoraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>1999-07-01 06:03:28 +0000
committeraph <aph@138bc75d-0d04-0410-961f-82ee72b054a4>1999-07-01 06:03:28 +0000
commit2370e6b9d7b4f4f6d1635d035d5b7809303c7832 (patch)
treef0056ec9bc77c60aecc81347ace42b571b4b767c /gcc/java
parent7097d4700c2647ef11cfee62a1cdd7fdd3dec8f9 (diff)
downloadgcc-2370e6b9d7b4f4f6d1635d035d5b7809303c7832.tar.gz
1999-06-24 Andrew Haley <aph@cygnus.com>
* class.c (finish_class): Whenever a deferred method is output, rescan the list of methods to see if a new candidate for output can be found. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@27872 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java')
-rw-r--r--gcc/java/ChangeLog6
-rw-r--r--gcc/java/class.c13
2 files changed, 15 insertions, 4 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog
index 0c14d37ff6e..7241c550861 100644
--- a/gcc/java/ChangeLog
+++ b/gcc/java/ChangeLog
@@ -1,3 +1,9 @@
+1999-06-24 Andrew Haley <aph@cygnus.com>
+
+ * class.c (finish_class): Whenever a deferred method is
+ output, rescan the list of methods to see if a new candidate for
+ output can be found.
+
1999-06-28 Tom Tromey <tromey@cygnus.com>
* jvspec.c (lang_specific_driver): Recognize --help.
diff --git a/gcc/java/class.c b/gcc/java/class.c
index 8217a950768..9a73364c8c9 100644
--- a/gcc/java/class.c
+++ b/gcc/java/class.c
@@ -1200,10 +1200,10 @@ finish_class (cl)
tree cl;
{
tree method;
-
- /* Emit deferred inline methods. */
- for ( method = TYPE_METHODS (CLASS_TO_HANDLE_TYPE (current_class));
- method != NULL_TREE; method = TREE_CHAIN (method))
+ tree type_methods = TYPE_METHODS (CLASS_TO_HANDLE_TYPE (current_class));
+
+ /* Emit deferred inline methods. */
+ for (method = type_methods; method != NULL_TREE; )
{
if (! TREE_ASM_WRITTEN (method) && DECL_SAVED_INSNS (method) != 0)
{
@@ -1215,8 +1215,13 @@ finish_class (cl)
temporary_allocation ();
output_inline_function (method);
permanent_allocation (1);
+ /* Scan the list again to see if there are any earlier
+ methods to emit. */
+ method = type_methods;
+ continue;
}
}
+ method = TREE_CHAIN (method);
}
make_class_data (current_class);