diff options
author | mmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-11-01 04:08:54 +0000 |
---|---|---|
committer | mmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-11-01 04:08:54 +0000 |
commit | 5d1cbc1db397a6325dc16e56c0d0d10725e0fce3 (patch) | |
tree | 12857d39a7bf55c73f1280f11bfdf2d1560fc75d /gcc/expr.c | |
parent | 1ff8dee7c716a5682cdecd426e8302f6f263b0e2 (diff) | |
download | gcc-5d1cbc1db397a6325dc16e56c0d0d10725e0fce3.tar.gz |
* expr.c (readonly_fields_p): Ignore everything except FIELD_DECLs.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@30306 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/expr.c')
-rw-r--r-- | gcc/expr.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/expr.c b/gcc/expr.c index 59ae687c5d8..69c6f56bced 100644 --- a/gcc/expr.c +++ b/gcc/expr.c @@ -5573,9 +5573,10 @@ readonly_fields_p (type) tree field; for (field = TYPE_FIELDS (type); field != 0; field = TREE_CHAIN (field)) - if (TREE_READONLY (field) - || (TREE_CODE (TREE_TYPE (field)) == RECORD_TYPE - && readonly_fields_p (TREE_TYPE (field)))) + if (TREE_CODE (field) == FIELD_DECL + && (TREE_READONLY (field) + || (TREE_CODE (TREE_TYPE (field)) == RECORD_TYPE + && readonly_fields_p (TREE_TYPE (field))))) return 1; return 0; |