Make-lang.in (cp/semantics.o): Depend on c-common.h.
authorZiemowit Laski <zlaski@apple.com>
Thu, 9 Sep 2004 01:49:00 +0000 (01:49 +0000)
committerZiemowit Laski <zlaski@gcc.gnu.org>
Thu, 9 Sep 2004 01:49:00 +0000 (01:49 +0000)
[gcc/cp/ChangeLog]
2004-09-08  Ziemowit Laski  <zlaski@apple.com>

        * Make-lang.in (cp/semantics.o): Depend on c-common.h.
        * semantics.c: Include c-common.h.
        (finish_compound_stmt): Call objc_clear_super_receiver().

From-SVN: r87219

gcc/cp/ChangeLog
gcc/cp/Make-lang.in
gcc/cp/semantics.c

index 76c7de3442846fb0365d94a18aa48dc32f638d0c..2792cca7fed16fae752fee929adfe41b5aece0c6 100644 (file)
@@ -1,3 +1,9 @@
+2004-09-08  Ziemowit Laski  <zlaski@apple.com>
+
+       * Make-lang.in (cp/semantics.o): Depend on c-common.h.
+       * semantics.c: Include c-common.h.
+       (finish_compound_stmt): Call objc_clear_super_receiver().
+
 2004-09-08  Ziemowit Laski  <zlaski@apple.com>
 
        * cp-tree.h (do_poplevel): New prototype.
index 3e91bf9078076e1ab7eb3205df6dfffb63acc1bf..29a533bd849102972306047cd18be8cc0d7261a5 100644 (file)
@@ -267,7 +267,7 @@ cp/repo.o: cp/repo.c $(CXX_TREE_H) $(TM_H) toplev.h diagnostic.h \
   gt-cp-repo.h
 cp/semantics.o: cp/semantics.c $(CXX_TREE_H) $(TM_H) except.h toplev.h \
   flags.h debug.h output.h $(RTL_H) $(TIMEVAR_H) $(EXPR_H) \
-  tree-inline.h cgraph.h $(TARGET_H)
+  tree-inline.h cgraph.h $(TARGET_H) c-common.h
 cp/dump.o: cp/dump.c $(CXX_TREE_H) $(TM_H) tree-dump.h
 cp/optimize.o: cp/optimize.c $(CXX_TREE_H) $(TM_H) rtl.h integrate.h insn-config.h \
   input.h $(PARAMS_H) debug.h tree-inline.h tree-gimple.h $(TARGET_H)
index b31e1e2490ef96d7ecf235401559750eef3ebcdf..5d50ea687eb774795653d36125210263aa9c2e34 100644 (file)
@@ -31,6 +31,7 @@
 #include "tm.h"
 #include "tree.h"
 #include "cp-tree.h"
+#include "c-common.h"
 #include "tree-inline.h"
 #include "tree-mudflap.h"
 #include "except.h"
@@ -1088,7 +1089,13 @@ finish_compound_stmt (tree stmt)
   else if (STATEMENT_LIST_NO_SCOPE (stmt))
     stmt = pop_stmt_list (stmt);
   else
-    stmt = do_poplevel (stmt);
+    {
+      /* Destroy any ObjC "super" receivers that may have been
+        created.  */
+      objc_clear_super_receiver ();
+
+      stmt = do_poplevel (stmt);
+    }
 
   /* ??? See c_end_compound_stmt wrt statement expressions.  */
   add_stmt (stmt);