aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree.h
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2013-04-11 16:15:25 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2013-04-11 16:15:25 +0000
commit966b587e0b513fa8075beaf9ab184ed74686ee97 (patch)
tree50ecfdf73e14a55579b5dfadb4bcc575c87bafec /gcc/tree.h
parent76545796c5181baef9511af159178aef8d93de7c (diff)
downloadgcc-966b587e0b513fa8075beaf9ab184ed74686ee97.zip
gcc-966b587e0b513fa8075beaf9ab184ed74686ee97.tar.gz
gcc-966b587e0b513fa8075beaf9ab184ed74686ee97.tar.bz2
stor-layout.c (skip_simple_constant_arithmetic): Move to...
* stor-layout.c (skip_simple_constant_arithmetic): Move to... * tree.c (skip_simple_constant_arithmetic): ...here and make public. (skip_simple_arithmetic): Tidy up. * tree.h (skip_simple_constant_arithmetic): Declare. ada/ * gcc-interface/decl.c (elaborate_expression_1): Skip only constant arithmetics when looking for a read-only variable in the expression. From-SVN: r197815
Diffstat (limited to 'gcc/tree.h')
-rw-r--r--gcc/tree.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/tree.h b/gcc/tree.h
index aa424c0..be43440 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -5339,11 +5339,16 @@ extern tree staticp (tree);
extern tree save_expr (tree);
-/* Look inside EXPR and into any simple arithmetic operations. Return
- the innermost non-arithmetic node. */
+/* Look inside EXPR into any simple arithmetic operations. Return the
+ outermost non-arithmetic or non-invariant node. */
extern tree skip_simple_arithmetic (tree);
+/* Look inside EXPR into simple arithmetic operations involving constants.
+ Return the outermost non-arithmetic or non-constant node. */
+
+extern tree skip_simple_constant_arithmetic (tree);
+
/* Return which tree structure is used by T. */
enum tree_node_structure_enum tree_node_structure (const_tree);