aboutsummaryrefslogtreecommitdiffstats
path: root/src/vhdl/vhdl-sem_psl.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2021-04-03 16:48:08 +0200
committerTristan Gingold <tgingold@free.fr>2021-04-03 16:48:08 +0200
commit6617613f93e70df2e2b964f380652ea43e2bb2a5 (patch)
tree2ce620bb15fc0e5e59fc61e1f4e4a1936b985049 /src/vhdl/vhdl-sem_psl.adb
parentbfc5f5c20b791e09b5a2d80aeea5ce77b84d309f (diff)
downloadghdl-6617613f93e70df2e2b964f380652ea43e2bb2a5.tar.gz
ghdl-6617613f93e70df2e2b964f380652ea43e2bb2a5.tar.bz2
ghdl-6617613f93e70df2e2b964f380652ea43e2bb2a5.zip
psl: prefix of goto/non-consecutive repetition is a bool. Fix #1708
Diffstat (limited to 'src/vhdl/vhdl-sem_psl.adb')
-rw-r--r--src/vhdl/vhdl-sem_psl.adb20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/vhdl/vhdl-sem_psl.adb b/src/vhdl/vhdl-sem_psl.adb
index 7e1f805eb..f6be38207 100644
--- a/src/vhdl/vhdl-sem_psl.adb
+++ b/src/vhdl/vhdl-sem_psl.adb
@@ -435,20 +435,24 @@ package body Vhdl.Sem_Psl is
Set_Right (Seq, R);
return Seq;
when N_Star_Repeat_Seq
- | N_Plus_Repeat_Seq
- | N_Equal_Repeat_Seq
- | N_Goto_Repeat_Seq =>
+ | N_Plus_Repeat_Seq =>
Res := Get_Sequence (Seq);
if Res /= Null_PSL_Node then
- Res := Sem_Sequence (Get_Sequence (Seq));
+ Res := Sem_Sequence (Res);
Set_Sequence (Seq, Res);
end if;
- -- TODO: Fix here if SERE is not of boolean type for
- -- Equal Repeat and goto repeat!!
+ return Seq;
+ when N_Equal_Repeat_Seq
+ | N_Goto_Repeat_Seq =>
+ Res := Get_Boolean (Seq);
+ if Res /= Null_PSL_Node then
+ Res := Sem_Boolean (Res);
+ Set_Boolean (Seq, Res);
+ end if;
return Seq;
when N_And_Bool
- | N_Or_Bool
- | N_Not_Bool =>
+ | N_Or_Bool
+ | N_Not_Bool =>
return Sem_Boolean (Seq);
when N_HDL_Expr =>
Res := Sem_Hdl_Expr (Seq);