diff options
author | kargl <kargl@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-11-25 15:04:33 +0000 |
---|---|---|
committer | kargl <kargl@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-11-25 15:04:33 +0000 |
commit | c112228a6f016e9c1c078033e03c5eba2c9eeb19 (patch) | |
tree | 276bacdded40164e7d3c72839a91830bd3990276 | |
parent | 54485efce55983b0c4a2221cfed2eea2af12b4a9 (diff) | |
download | gcc-c112228a6f016e9c1c078033e03c5eba2c9eeb19.tar.gz |
2015-11-25 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/68227
* trans-stmt.c (gfc_do_allocate): Convert gcc_assert argument into
into part of conditional statement.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@230873 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/fortran/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/fortran/trans-stmt.c | 3 |
2 files changed, 7 insertions, 2 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index da29a9d8f42..f1ad5e1f2b5 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,9 @@ +2015-11-25 Steven G. Kargl <kargl@gcc.gnu.org> + + PR fortran/68227 + * trans-stmt.c (gfc_do_allocate): Convert gcc_assert argument into + into part of conditional statement. + 2015-11-25 Ilmir Usmanov <me@ilmir.us> Cesar Philippidis <cesar@codesourcery.com> diff --git a/gcc/fortran/trans-stmt.c b/gcc/fortran/trans-stmt.c index 06591a31a3e..47ffd78eee6 100644 --- a/gcc/fortran/trans-stmt.c +++ b/gcc/fortran/trans-stmt.c @@ -3125,9 +3125,8 @@ gfc_do_allocate (tree bytesize, tree size, tree * pdata, stmtblock_t * pblock, type = build_range_type (gfc_array_index_type, gfc_index_zero_node, tmp); type = build_array_type (elem_type, type); - if (gfc_can_put_var_on_stack (bytesize)) + if (gfc_can_put_var_on_stack (bytesize) && INTEGER_CST_P (size)) { - gcc_assert (INTEGER_CST_P (size)); tmpvar = gfc_create_var (type, "temp"); *pdata = NULL_TREE; } |