summaryrefslogtreecommitdiff
path: root/gcc/ipa-pure-const.c
diff options
context:
space:
mode:
authoruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2007-10-26 07:08:05 +0000
committeruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2007-10-26 07:08:05 +0000
commitbc17fd997cf8ff11c4483ee32da60ded71c49be0 (patch)
tree1f1998b89b39b08905a1aa1d8835d27810441036 /gcc/ipa-pure-const.c
parentf6b520a41813421f68dde5d968f32b8917267373 (diff)
downloadgcc-bc17fd997cf8ff11c4483ee32da60ded71c49be0.tar.gz
* ipa-pure-const.c (check_decl): Return immediately when
pure_const_state has been set to IPA_NEITHER. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129644 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa-pure-const.c')
-rw-r--r--gcc/ipa-pure-const.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/ipa-pure-const.c b/gcc/ipa-pure-const.c
index 519b402df20..d3b880adc83 100644
--- a/gcc/ipa-pure-const.c
+++ b/gcc/ipa-pure-const.c
@@ -114,7 +114,10 @@ check_decl (funct_state local,
are CHECKING_WRITE, this cannot be a pure or constant
function. */
if (checking_write)
- local->pure_const_state = IPA_NEITHER;
+ {
+ local->pure_const_state = IPA_NEITHER;
+ return;
+ }
if (DECL_EXTERNAL (t) || TREE_PUBLIC (t))
{