From 5b384f9a56cb652411d1d63c44db9d4158e51701 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Mon, 8 Apr 2019 18:51:15 +0200 Subject: vhdl: fix crash for -Wdelayed-checks. Fix #794 --- src/vhdl/sem.adb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vhdl/sem.adb b/src/vhdl/sem.adb index 45899f368..c5d9761ac 100644 --- a/src/vhdl/sem.adb +++ b/src/vhdl/sem.adb @@ -2461,7 +2461,8 @@ package body Sem is Keep := True; if Emit_Warnings then declare - Callees : constant Iir_List := Get_Callees_List (El); + Bod : constant Iir := Get_Subprogram_Body (El); + Callees : constant Iir_List := Get_Callees_List (Bod); pragma Assert (Callees /= Null_Iir_List); Callee : constant Iir := Get_First_Element (Callees); begin -- cgit v1.2.3