From a43ea3192f8f3dfe1c59e33f50e2e6f323c7e4db Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Sun, 13 Aug 1995 21:42:59 -0400 Subject: [PATCH] (c_expand_asm_operands): Check for read-only output operand where the variable is read-only but the type is not. From-SVN: r10232 --- gcc/c-typeck.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/c-typeck.c b/gcc/c-typeck.c index b16a7bfb820..527b6ebb916 100644 --- a/gcc/c-typeck.c +++ b/gcc/c-typeck.c @@ -6432,7 +6432,8 @@ c_expand_asm_operands (string, outputs, inputs, clobbers, vol, filename, line) else { tree type = TREE_TYPE (o[i]); - if (TYPE_READONLY (type) + if (TREE_READONLY (o[i]) + || TYPE_READONLY (type) || ((TREE_CODE (type) == RECORD_TYPE || TREE_CODE (type) == UNION_TYPE) && C_TYPE_FIELDS_READONLY (type))) -- 2.30.2