gimple-fold.c (fold_const_aggregate_ref_1): Use DECL_P.

* gimple-fold.c (fold_const_aggregate_ref_1): Use DECL_P.
	* gimplify.c (gimplify_modify_expr_rhs): Likewise.

	* c-ada-spec.c (dump_sloc): Use DECL_P.

From-SVN: r223440
This commit is contained in:
Marek Polacek 2015-05-20 11:45:07 +00:00 committed by Marek Polacek
parent 7bd1191163
commit 3a65ee74e8
5 changed files with 12 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2015-05-20 Marek Polacek <polacek@redhat.com>
* gimple-fold.c (fold_const_aggregate_ref_1): Use DECL_P.
* gimplify.c (gimplify_modify_expr_rhs): Likewise.
2015-05-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
* config/aarch64/aarch64.c (aarch64_class_max_nregs):

View File

@ -1,3 +1,7 @@
2015-05-20 Marek Polacek <polacek@redhat.com>
* c-ada-spec.c (dump_sloc): Use DECL_P.
2015-05-20 Marek Polacek <polacek@redhat.com>
* c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.

View File

@ -1629,7 +1629,7 @@ dump_sloc (pretty_printer *buffer, tree node)
xloc.file = NULL;
if (TREE_CODE_CLASS (TREE_CODE (node)) == tcc_declaration)
if (DECL_P (node))
xloc = expand_location (DECL_SOURCE_LOCATION (node));
else if (EXPR_HAS_LOCATION (node))
xloc = expand_location (EXPR_LOCATION (node));

View File

@ -5518,7 +5518,7 @@ fold_const_aggregate_ref_1 (tree t, tree (*valueize) (tree))
if (TREE_THIS_VOLATILE (t))
return NULL_TREE;
if (TREE_CODE_CLASS (TREE_CODE (t)) == tcc_declaration)
if (DECL_P (t))
return get_symbol_constant_value (t);
tem = fold_read_from_constant_string (t);

View File

@ -4222,7 +4222,7 @@ gimplify_modify_expr_rhs (tree *expr_p, tree *from_p, tree *to_p,
{
if (TREE_THIS_VOLATILE (t) != volatile_p)
{
if (TREE_CODE_CLASS (TREE_CODE (t)) == tcc_declaration)
if (DECL_P (t))
t = build_simple_mem_ref_loc (EXPR_LOCATION (*from_p),
build_fold_addr_expr (t));
if (REFERENCE_CLASS_P (t))