* parse.y (resolve_qualified_expression_name): If creating a
authorbothner <bothner@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 31 Aug 2001 03:07:12 +0000 (03:07 +0000)
committerbothner <bothner@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 31 Aug 2001 03:07:12 +0000 (03:07 +0000)
COMPOUND_EXPR, set it's type correctly.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@45305 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/java/ChangeLog
gcc/java/parse.y

index 02297cf..0d9f4c5 100644 (file)
@@ -1,5 +1,10 @@
 2001-08-30  Per Bothner  <per@bothner.com>
 
+       * parse.y (resolve_qualified_expression_name):  If creating a
+       COMPOUND_EXPR, set it's type correctly.
+
+2001-08-30  Per Bothner  <per@bothner.com>
+
        * jcf-io.c (open_class):  Set filename field.
 
        * jcf-parse,c (parse_class_file):  Set current_function_decl
index 7567c3d..3f1cfa7 100644 (file)
@@ -9418,7 +9418,8 @@ resolve_qualified_expression_name (wfl, found_decl, where_found, type_found)
             forcoming function's argument. */
          if (previous_call_static && is_static)
            {
-             decl = build (COMPOUND_EXPR, type, decl, *where_found);
+             decl = build (COMPOUND_EXPR, TREE_TYPE (*where_found),
+                           decl, *where_found);
              TREE_SIDE_EFFECTS (decl) = 1;
            }
          else