[Rewrite Synthesis] Fix args for non-chaining ops (#7996)
authorAndres Noetzli <andres.noetzli@gmail.com>
Fri, 28 Jan 2022 16:56:27 +0000 (08:56 -0800)
committerGitHub <noreply@github.com>
Fri, 28 Jan 2022 16:56:27 +0000 (16:56 +0000)
commitf25aa7f135b8f50dadc0252231943cf077a7ff9e
tree9569553813d4a428bb6847a5efee3a548c018d27
parent8e3892ebe308712ad645848b551219f95e550b61
[Rewrite Synthesis] Fix args for non-chaining ops (#7996)

Fixes https://github.com/cvc5/cvc5-projects/issues/445. Fixes
https://github.com/cvc5/cvc5-projects/issues/446. The issue is related
to the preprocessing pass for doing rewrite rule synthesis based on the
input. It was removing duplicate arguments from both chaining operators
and non-chaining operators when constructing the corresponding
datatypes. In the case of non-chaining operators, it could happen that
the constructor of the datatype did not have the correct number of
arguments for a given kind if there was a term where multiple arguments
were the same. This commit fixes the issue by doing the duplicate
elimination only for chaining operators.
src/preprocessing/passes/synth_rew_rules.cpp
test/api/cpp/CMakeLists.txt
test/api/cpp/proj-issue445.cpp [new file with mode: 0644]