diff options
author | Tristan Gingold <tgingold@free.fr> | 2019-11-18 07:30:06 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2019-11-18 07:32:20 +0100 |
commit | b57c47f3c516d156c046fe162a132b34e8806b7e (patch) | |
tree | 00793cc3e83dfb7df355c280d33faea5e15318c3 | |
parent | 139314752796bc5cfc56d7716924313095e37f1f (diff) | |
download | ghdl-b57c47f3c516d156c046fe162a132b34e8806b7e.tar.gz ghdl-b57c47f3c516d156c046fe162a132b34e8806b7e.tar.bz2 ghdl-b57c47f3c516d156c046fe162a132b34e8806b7e.zip |
synth-expr: properly set the return type in synth_bit_eq_const. For #1022
-rw-r--r-- | src/synth/synth-oper.adb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/synth/synth-oper.adb b/src/synth/synth-oper.adb index 884c9de10..45eddb435 100644 --- a/src/synth/synth-oper.adb +++ b/src/synth/synth-oper.adb @@ -107,7 +107,8 @@ package body Synth.Oper is Set_Location (N, Loc); return Create_Value_Net (N, Boolean_Type); elsif Val = 1 then - return Expr; + -- The result type is a boolean. + return Create_Value_Discrete (1, Boolean_Type); else pragma Assert (Val = 0); N := Build_Monadic (Build_Context, Id_Not, Get_Net (Expr)); |