diff options
author | Tristan Gingold <tgingold@free.fr> | 2022-11-28 14:14:09 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2022-11-28 14:14:09 +0100 |
commit | 5707cc82d8222346b475fb820be81fd677bc3c29 (patch) | |
tree | 777bacc91ccaaa66ef566dd709350d24abe11b4b /src/vhdl/vhdl-sem_expr.adb | |
parent | eaf363fa47f047d62a987804e1f86c2a6ca460f7 (diff) | |
download | ghdl-5707cc82d8222346b475fb820be81fd677bc3c29.tar.gz ghdl-5707cc82d8222346b475fb820be81fd677bc3c29.tar.bz2 ghdl-5707cc82d8222346b475fb820be81fd677bc3c29.zip |
vhdl-evaluation: improve handling of ieee 08 static functions.
Fix #2252
Diffstat (limited to 'src/vhdl/vhdl-sem_expr.adb')
-rw-r--r-- | src/vhdl/vhdl-sem_expr.adb | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/src/vhdl/vhdl-sem_expr.adb b/src/vhdl/vhdl-sem_expr.adb index a115cfe66..3dd86d900 100644 --- a/src/vhdl/vhdl-sem_expr.adb +++ b/src/vhdl/vhdl-sem_expr.adb @@ -17,7 +17,6 @@ with Grt.Algos; with Errorout; use Errorout; with Name_Table; -with Std_Names; with Str_Table; with Flags; use Flags; @@ -895,25 +894,10 @@ package body Vhdl.Sem_Expr is function Is_Ieee_Operation (Imp : Iir) return Boolean is - use Std_Names; - Parent : Iir; - begin pragma Assert (Get_Kind (Imp) = Iir_Kind_Function_Declaration); - - -- TODO: remove this code so that all operations are allowed (and not - -- only operators). - case Get_Identifier (Imp) is - when Name_Id_Operators - | Name_Word_Operators - | Name_Logical_Operators => - null; - when others => - -- Not an operator. - return False; - end case; - + Parent : constant Iir := Get_Parent (Imp); + begin -- TODO: numeric_bit, numeric_bit_unsigned, numeric_std_unsigned. - Parent := Get_Parent (Imp); return Parent = Vhdl.Ieee.Numeric.Numeric_Std_Pkg or Parent = Vhdl.Ieee.Std_Logic_1164.Std_Logic_1164_Pkg; end Is_Ieee_Operation; |