Commit ca059043 by Andrew Pinski Committed by Andrew Pinski

parser.c (cp_parser_asm_definition): Look passed the CLEANUP_POINT_EXPR to get the asm expression.

cp/ChangeLog:
	* 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.

From-SVN: r88688
parent 93348822
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
......
......@@ -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);
......
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
......
......@@ -7,5 +7,5 @@ void bar()
{
A a;
asm("" : : "r"(foo(a)) );//<-- cleanup needed here.
};
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment