diff mbox series

[committed,fortran] PR82009 [F08] ICE with block construct

Message ID a84d6648-31b3-c242-c146-89e939fd3e0b@charter.net
State New
Headers show
Series [committed,fortran] PR82009 [F08] ICE with block construct | expand

Commit Message

Jerry DeLisle July 4, 2018, 6:13 p.m. UTC
This patch committed as obvious after regression testing and auditing 
the code.  New test case added.

Author: jvdelisle
Date: Wed Jul  4 18:08:16 2018
New Revision: 262416

URL: https://gcc.gnu.org/viewcvs?rev=262416&root=gcc&view=rev
Log:
2018-07-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR fortran/82009
	* trans-decl.c (gfc_process_block_locals): Delete assert and set
	saved_local_decls = NULL_TREE.

	* gfortran.dg/block_16.f08. New test.

Added:
     trunk/gcc/testsuite/gfortran.dg/block_16.f08
Modified:
     trunk/gcc/fortran/ChangeLog
     trunk/gcc/fortran/trans-decl.c
     trunk/gcc/testsuite/ChangeLog

Comments

Paul Richard Thomas July 4, 2018, 6:32 p.m. UTC | #1
Thanks, Jerry.
On Wed, 4 Jul 2018 at 19:14, Jerry DeLisle <jvdelisle@charter.net> wrote:
>
> This patch committed as obvious after regression testing and auditing
> the code.  New test case added.
>
> Author: jvdelisle
> Date: Wed Jul  4 18:08:16 2018
> New Revision: 262416
>
> URL: https://gcc.gnu.org/viewcvs?rev=262416&root=gcc&view=rev
> Log:
> 2018-07-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
>
>         PR fortran/82009
>         * trans-decl.c (gfc_process_block_locals): Delete assert and set
>         saved_local_decls = NULL_TREE.
>
>         * gfortran.dg/block_16.f08. New test.
>
> Added:
>      trunk/gcc/testsuite/gfortran.dg/block_16.f08
> Modified:
>      trunk/gcc/fortran/ChangeLog
>      trunk/gcc/fortran/trans-decl.c
>      trunk/gcc/testsuite/ChangeLog
>
>
>
> diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c
> index 254768c5828..08c1ebd2d4b 100644
> --- a/gcc/fortran/trans-decl.c
> +++ b/gcc/fortran/trans-decl.c
> @@ -6751,7 +6751,7 @@ gfc_process_block_locals (gfc_namespace* ns)
>   {
>     tree decl;
>
> -  gcc_assert (saved_local_decls == NULL_TREE);
> +  saved_local_decls = NULL_TREE;
>     has_coarray_vars = false;
>
>     generate_local_vars (ns);
diff mbox series

Patch

diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c
index 254768c5828..08c1ebd2d4b 100644
--- a/gcc/fortran/trans-decl.c
+++ b/gcc/fortran/trans-decl.c
@@ -6751,7 +6751,7 @@  gfc_process_block_locals (gfc_namespace* ns)
  {
    tree decl;

-  gcc_assert (saved_local_decls == NULL_TREE);
+  saved_local_decls = NULL_TREE;
    has_coarray_vars = false;

    generate_local_vars (ns);