Fixes cvc5/cvc5-projects#464.
#include "options/base_options.h"
#include "options/quantifiers_options.h"
#include "smt/env.h"
+#include "smt/logic_exception.h"
#include "util/random.h"
using namespace cvc5::kind;
if (!n.getType().isBoolean())
{
// currently, should not register non-Boolean terms here
- Assert(false);
+ std::stringstream ss;
+ ss << "SyGuS solution filtering requires the grammar to "
+ "generate Boolean terms only";
+ throw LogicException(ss.str());
return true;
}
Node basen = d_isStrong ? n : n.negate();
regress0/sygus/print-debug.sy
regress0/sygus/print-define-fun.sy
regress0/sygus/print-grammar.sy
+ regress0/sygus/proj-issue464-rr-option.smt2
regress0/sygus/real-si-all.sy
regress0/sygus/setFeature.sy
regress0/sygus/strings-unconstrained.sy
--- /dev/null
+; SCRUBBER: grep -v -E '\(define-fun'
+; EXPECT: (error "SyGuS solution filtering requires the grammar to generate Boolean terms only")
+; EXIT: 1
+(set-logic ALL)
+(set-option :global-declarations true)
+(set-option :sygus-rr-synth-input true)
+(set-option :sygus-filter-sol weak)
+(declare-sort _u0 0)
+(declare-const _x6 Bool)
+(declare-const _x10 _u0)
+(declare-const _x12 _u0)
+(assert (= (distinct _x12 _x10) _x6))
+(check-sat)