diff options
Diffstat (limited to 'gcc/java/jcf-parse.c')
-rw-r--r-- | gcc/java/jcf-parse.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/java/jcf-parse.c b/gcc/java/jcf-parse.c index eeb262a4846..030edf30b00 100644 --- a/gcc/java/jcf-parse.c +++ b/gcc/java/jcf-parse.c @@ -1,5 +1,5 @@ /* Parser for Java(TM) .class files. - Copyright (C) 1996, 1998, 1999, 2000, 2001, 2002 + Copyright (C) 1996, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. This file is part of GNU CC. @@ -548,6 +548,10 @@ read_class (name) read_zip_member(current_jcf, current_jcf->zipd, current_jcf->zipd->zipf); jcf_parse (current_jcf); + /* Parsing might change the class, in which case we have to + put it back where we found it. */ + if (current_class != class && icv != NULL_TREE) + TREE_TYPE (icv) = current_class; class = current_class; java_pop_parser_context (0); java_parser_context_restore_global (); |