diff options
author | Thomas Schwinge <thomas@codesourcery.com> | 2014-07-10 14:05:27 +0200 |
---|---|---|
committer | Thomas Schwinge <tschwinge@gcc.gnu.org> | 2014-07-10 14:05:27 +0200 |
commit | f9abc06c5e9a8b55af730a07f8cd37bb914093c8 (patch) | |
tree | f80b2891f317fac6d516f3f95a228834386ba4d5 /gcc/fold-const.c | |
parent | d764963b54885cdf3604e54717b1a137492d7415 (diff) | |
download | gcc-f9abc06c5e9a8b55af730a07f8cd37bb914093c8.zip gcc-f9abc06c5e9a8b55af730a07f8cd37bb914093c8.tar.gz gcc-f9abc06c5e9a8b55af730a07f8cd37bb914093c8.tar.bz2 |
Fix --enable-checking=fold failure.
gcc/
* fold-const.c (fold_checksum_tree): Look at DECL_VINDEX only for
FUNCTION_DECLs.
From-SVN: r212428
Diffstat (limited to 'gcc/fold-const.c')
-rw-r--r-- | gcc/fold-const.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/fold-const.c b/gcc/fold-const.c index c57ac7b..d51bda7 100644 --- a/gcc/fold-const.c +++ b/gcc/fold-const.c @@ -14858,7 +14858,8 @@ fold_checksum_tree (const_tree expr, struct md5_ctx *ctx, if (CODE_CONTAINS_STRUCT (TREE_CODE (expr), TS_DECL_NON_COMMON)) { - fold_checksum_tree (DECL_VINDEX (expr), ctx, ht); + if (TREE_CODE (expr) == FUNCTION_DECL) + fold_checksum_tree (DECL_VINDEX (expr), ctx, ht); fold_checksum_tree (DECL_RESULT_FLD (expr), ctx, ht); fold_checksum_tree (DECL_ARGUMENT_FLD (expr), ctx, ht); } |