Skip to content

Commit 58e7b93

Browse files
authored
Merge pull request #1245 from diffblue/property_and1-fix
Fix for typechecking SVA `and` on named properties
2 parents 3804d06 + e010998 commit 58e7b93

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
KNOWNBUG
1+
CORE
22
property_and1.sv
3-
--bdd
3+
4+
^\[.*\] always \(main\.P1 and main\.P1\): PROVED \(1-induction\)$
45
^EXIT=0$
56
^SIGNAL=0$
67
--
78
^warning: ignoring
89
--
9-
This is rejected with a typechecking error.

src/verilog/verilog_typecheck_sva.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,10 +121,8 @@ exprt verilog_typecheck_exprt::convert_binary_sva(binary_exprt expr)
121121
// These yield sequences when both operands are sequences, and
122122
// properties otherwise.
123123
if(
124-
(expr.lhs().type().id() == ID_verilog_sva_sequence ||
125-
!has_temporal_operator(expr.lhs())) &&
126-
(expr.rhs().type().id() == ID_verilog_sva_sequence ||
127-
!has_temporal_operator(expr.rhs())))
124+
expr.lhs().type().id() != ID_verilog_sva_property &&
125+
expr.rhs().type().id() != ID_verilog_sva_property)
128126
{
129127
expr.type() = verilog_sva_sequence_typet{};
130128
require_sva_sequence(expr.lhs());

0 commit comments

Comments
 (0)