OSDN Git Service

cp/ChangeLog:
authorpinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 7 Oct 2004 13:48:27 +0000 (13:48 +0000)
committerpinskia <pinskia@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 7 Oct 2004 13:48:27 +0000 (13:48 +0000)
* parser.c (cp_parser_asm_definition): Look passed the
CLEANUP_POINT_EXPR to get the asm expression.

testsuite/ChangeLog:
* g++.dg/ext/asm6.C: Remove extraneous semicolon.

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

gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/ext/asm6.C

index 20a6a2d..364d1be 100644 (file)
@@ -1,4 +1,9 @@
-2004-10-05  Andrew Pinski  <pinskia@physics.uc.edu>
+2004-10-07  Andrew Pinski  <pinskia@physics.uc.edu>
+
+       * parser.c (cp_parser_asm_definition): Look passed the
+       CLEANUP_POINT_EXPR to get the asm expression.
+
+2004-10-06  Andrew Pinski  <pinskia@physics.uc.edu>
 
        PR c++/17368
        * semantics.c (finish_asm_stmt): Asm expressions need cleanup
index 79342db..9bd3f18 100644 (file)
@@ -10389,7 +10389,13 @@ cp_parser_asm_definition (cp_parser* parser)
                                  inputs, clobbers);
       /* If the extended syntax was not used, mark the ASM_EXPR.  */
       if (!extended_p)
-       ASM_INPUT_P (asm_stmt) = 1;
+       {
+         tree temp = asm_stmt;
+         if (TREE_CODE (temp) == CLEANUP_POINT_EXPR)
+           temp = TREE_OPERAND (temp, 0);
+         
+         ASM_INPUT_P (temp) = 1;
+       }
     }
   else
     assemble_asm (string);
index 1087adb..03e569e 100644 (file)
@@ -1,3 +1,7 @@
+2004-10-07  Andrew Pinski  <pinskia@physics.uc.edu>
+
+       * g++.dg/ext/asm6.C: Remove extraneous semicolon.
+
 2004-10-07  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
 
        PR c++/17115
index eaf79f4..96ef9d3 100644 (file)
@@ -7,5 +7,5 @@ void bar()
 {
     A a;
     asm("" : : "r"(foo(a)) );//<-- cleanup needed here.
-};
+}