From dbcf503f9d04da7ab62cb8c8e593e8a7107e40ec Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Thu, 27 Nov 2014 07:26:08 +0100 Subject: translate: fix dichotomy upper bound. --- src/vhdl/translate/trans-chap8.adb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/vhdl/translate') diff --git a/src/vhdl/translate/trans-chap8.adb b/src/vhdl/translate/trans-chap8.adb index 72aa77a..8f63e78 100644 --- a/src/vhdl/translate/trans-chap8.adb +++ b/src/vhdl/translate/trans-chap8.adb @@ -999,7 +999,7 @@ package body Trans.Chap8 is New_Assign_Stmt (New_Obj (Var_Hi), New_Lit (New_Unsigned_Literal (Ghdl_Index_Type, - Unsigned_64 (Nbr_Choices)))); + Unsigned_64 (Nbr_Choices - 1)))); Func := Chap7.Find_Predefined_Function (Get_Base_Type (Expr_Type), Iir_Predefined_Array_Greater); -- cgit