From: Arnaud Charlet Date: Tue, 11 Dec 2018 11:11:53 +0000 (+0000) Subject: [Ada] Unnesting: ensure Current_Subprogram is always initialized X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2ffa39d24733c209d32cc6b2cb87f4d38d8198a9;p=gcc.git [Ada] Unnesting: ensure Current_Subprogram is always initialized 2018-12-11 Arnaud Charlet gcc/ada/ * exp_unst.adb (Unnest_Subprogram): Ensure Current_Subprogram is always initialized. From-SVN: r267009 --- diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 1fd528ccaf5..7f020e39b56 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2018-12-11 Arnaud Charlet + + * exp_unst.adb (Unnest_Subprogram): Ensure Current_Subprogram is + always initialized. + 2018-12-11 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity): Add diff --git a/gcc/ada/exp_unst.adb b/gcc/ada/exp_unst.adb index 57b2a9e190c..f8c8fd56be1 100644 --- a/gcc/ada/exp_unst.adb +++ b/gcc/ada/exp_unst.adb @@ -440,7 +440,7 @@ package body Exp_Unst is Urefs.Init; Build_Tables : declare - Current_Subprogram : Entity_Id; + Current_Subprogram : Entity_Id := Empty; -- When we scan a subprogram body, we set Current_Subprogram to the -- corresponding entity. This gets recursively saved and restored.