diff options
author | Richard Sandiford <rdsandiford@googlemail.com> | 2013-11-18 14:52:29 +0000 |
---|---|---|
committer | Richard Sandiford <rsandifo@gcc.gnu.org> | 2013-11-18 14:52:29 +0000 |
commit | 386b1f1f416c9da018d47ccd371494b3a3a32870 (patch) | |
tree | d16c65f5e22e1df0f38b0740834821a33ca730ff /gcc/cp | |
parent | ae7e9dddb860567a40d7c84736522242236a3355 (diff) | |
download | gcc-386b1f1f416c9da018d47ccd371494b3a3a32870.zip gcc-386b1f1f416c9da018d47ccd371494b3a3a32870.tar.gz gcc-386b1f1f416c9da018d47ccd371494b3a3a32870.tar.bz2 |
cuintp.c (UI_From_gnu): Use tree_to_shwi rather than tree_low_cst.
gcc/ada/
* gcc-interface/cuintp.c (UI_From_gnu): Use tree_to_shwi rather than
tree_low_cst.
gcc/c-family/
* c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
tree_low_cst.
(complete_array_type): Update comment to refer to tree_to_[su]hwi
rather than tree_low_cst.
gcc/c/
* c-decl.c (grokdeclarator): Update comment to refer to
tree_to_[su]hwi rather than tree_low_cst.
gcc/cp/
* decl.c (reshape_init_array_1): Use tree_to_uhwi rather than
tree_low_cst.
(grokdeclarator): Update comment to refer to tree_to_[su]hwi rather
than tree_low_cst.
gcc/
* expr.h: Update comments to refer to tree_to_[su]hwi rather
than tree_low_cst.
* fold-const.c (fold_binary_loc): Likewise.
* expr.c (store_constructor): Use tree_to_uhwi rather than
tree_low_cst.
* ipa-utils.h (possible_polymorphic_call_target_p): Likewise.
* stmt.c (emit_case_dispatch_table): Likewise.
* tree-switch-conversion.c (emit_case_bit_tests): Likewise.
From-SVN: r204962
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/cp/decl.c | 5 |
2 files changed, 9 insertions, 3 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index e2705f9..2906ed7 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,12 @@ 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> + * decl.c (reshape_init_array_1): Use tree_to_uhwi rather than + tree_low_cst. + (grokdeclarator): Update comment to refer to tree_to_[su]hwi rather + than tree_low_cst. + +2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> + * call.c, class.c, decl.c, error.c: Replace tree_low_cst (..., 1) with tree_to_uhwi throughout. diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 1a1581e..e2aad9d 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -5097,8 +5097,7 @@ reshape_init_array_1 (tree elt_type, tree max_index, reshape_iter *d, max_index_cst = tree_to_uhwi (max_index); /* sizetype is sign extended, not zero extended. */ else - max_index_cst = tree_low_cst (fold_convert (size_type_node, max_index), - 1); + max_index_cst = tree_to_uhwi (fold_convert (size_type_node, max_index)); } /* Loop until there are no more initializers. */ @@ -10033,7 +10032,7 @@ grokdeclarator (const cp_declarator *declarator, { error ("size of array %qs is too large", name); /* If we proceed with the array type as it is, we'll eventually - crash in tree_low_cst(). */ + crash in tree_to_[su]hwi(). */ type = error_mark_node; } |