} else {
unsigned len = filenameStr.size();
if(len >= 5 && !strcmp(".smt2", filename + len - 5)) {
- opts.setInputLanguage(language::input::LANG_SMTLIB_V2_5);
+ opts.setInputLanguage(language::input::LANG_SMTLIB_V2_6);
} else if(len >= 4 && !strcmp(".smt", filename + len - 4)) {
opts.setInputLanguage(language::input::LANG_SMTLIB_V1);
} else if(len >= 5 && !strcmp(".smt1", filename + len - 5)) {
} else if(language == "smtlib1" || language == "smt1" ||
language == "LANG_SMTLIB_V1") {
return input::LANG_SMTLIB_V1;
- } else if(language == "smtlib" || language == "smt" ||
- language == "smtlib2" || language == "smt2" ||
- language == "smtlib2.0" || language == "smt2.0" ||
- language == "LANG_SMTLIB_V2_0" || language == "LANG_SMTLIB_V2") {
+ } else if(language == "smtlib2.0" || language == "smt2.0" ||
+ language == "LANG_SMTLIB_V2_0") {
return input::LANG_SMTLIB_V2_0;
} else if(language == "smtlib2.5" || language == "smt2.5" ||
language == "LANG_SMTLIB_V2_5") {
return input::LANG_SMTLIB_V2_5;
- } else if(language == "smtlib2.6" || language == "smt2.6" ||
- language == "LANG_SMTLIB_V2_6") {
+ } else if(language == "smtlib" || language == "smt" ||
+ language == "smtlib2" || language == "smt2" ||
+ language == "smtlib2.6" || language == "smt2.6" ||
+ language == "LANG_SMTLIB_V2_6" || language == "LANG_SMTLIB_V2") {
return input::LANG_SMTLIB_V2_6;
} else if(language == "tptp" || language == "LANG_TPTP") {
return input::LANG_TPTP;
CONST_TOK : 'const';
// extended commands
-DECLARE_CODATATYPE_TOK : { PARSER_STATE->v2_6() }? 'declare-codatatype';
-DECLARE_DATATYPE_TOK : { PARSER_STATE->v2_6() }? 'declare-datatype';
-DECLARE_DATATYPES_2_5_TOK : { !PARSER_STATE->v2_6() }?'declare-datatypes';
-DECLARE_DATATYPES_TOK : { PARSER_STATE->v2_6() }?'declare-datatypes';
-DECLARE_CODATATYPES_2_5_TOK : { !PARSER_STATE->v2_6() }?'declare-codatatypes';
-DECLARE_CODATATYPES_TOK : { PARSER_STATE->v2_6() }?'declare-codatatypes';
+DECLARE_CODATATYPE_TOK : { PARSER_STATE->v2_6() || PARSER_STATE->sygus() }? 'declare-codatatype';
+DECLARE_DATATYPE_TOK : { PARSER_STATE->v2_6() || PARSER_STATE->sygus() }? 'declare-datatype';
+DECLARE_DATATYPES_2_5_TOK : { !( PARSER_STATE->v2_6() || PARSER_STATE->sygus() ) }?'declare-datatypes';
+DECLARE_DATATYPES_TOK : { PARSER_STATE->v2_6() || PARSER_STATE->sygus() }?'declare-datatypes';
+DECLARE_CODATATYPES_2_5_TOK : { !( PARSER_STATE->v2_6() || PARSER_STATE->sygus() ) }?'declare-codatatypes';
+DECLARE_CODATATYPES_TOK : { PARSER_STATE->v2_6() || PARSER_STATE->sygus() }?'declare-codatatypes';
PAR_TOK : { PARSER_STATE->v2_6() }?'par';
-TESTER_TOK : { PARSER_STATE->v2_6() && PARSER_STATE->isTheoryEnabled(Smt2::THEORY_DATATYPES) }?'is';
-MATCH_TOK : { PARSER_STATE->v2_6() && PARSER_STATE->isTheoryEnabled(Smt2::THEORY_DATATYPES) }?'match';
+TESTER_TOK : { ( PARSER_STATE->v2_6() || PARSER_STATE->sygus() ) && PARSER_STATE->isTheoryEnabled(Smt2::THEORY_DATATYPES) }?'is';
+MATCH_TOK : { ( PARSER_STATE->v2_6() || PARSER_STATE->sygus() ) && PARSER_STATE->isTheoryEnabled(Smt2::THEORY_DATATYPES) }?'match';
GET_MODEL_TOK : 'get-model';
ECHO_TOK : 'echo';
REWRITE_RULE_TOK : 'assert-rewrite';
+; COMMAND-LINE: --lang=smt2.5
; SCRUBBER: sed -e 's/The fact in question: .*$/The fact in question: TERM/' -e 's/in a linear logic: .*$/in a linear logic: TERM/'
; EXPECT: (error "A non-linear fact was asserted to arithmetic in a linear logic.
; EXPECT: The fact in question: TERM
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic QF_ALL)
(set-info :status unsat)
(declare-datatypes
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
+
; Preamble --------------
(set-logic ALL)
(set-info :status sat)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
(set-logic QF_ALL_SUPPORTED)
(set-info :status sat)
+; COMMAND-LINE: --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(declare-datatypes (T1 T2) ((Pair (mk-pair (first T1) (second T2)))))
(set-logic ALL_SUPPORTED)
-; COMMAND-LINE: --incremental
+; COMMAND-LINE: --incremental --lang=smt2.5
; EXPECT: unknown
; EXPECT: unsat
; EXPECT: unknown
+; COMMAND-LINE: --lang=smt2.5
; EXIT: 1
; EXPECT: (error "Array theory solver does not yet support write-chains connecting two different constant arrays")
(set-logic ALL_SUPPORTED)
(set-info :status sat)
; Tree type
-(declare-datatypes () ((Tree (node (data Int) (color Bool) (left Tree) (right Tree)) (nil))))
+(declare-datatypes ((Tree 0)) (((node (data Int) (color Bool) (left Tree) (right Tree)) (nil))))
; content function
(declare-fun size (Tree) Int)
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-(declare-datatypes () ( (PairIntInt (pair (firstPairIntInt Int)
+(declare-datatypes ((PairIntInt 0)) ( ( (pair (firstPairIntInt Int)
(secondPairIntInt Int)) ) ))
(declare-fun /ArrayIntOfPair () (Array Int PairIntInt))
-(declare-datatypes () ( (SequenceABC (sequenceABC (a Int) (b Bool) (c Int)) )
+(declare-datatypes ((SequenceABC 0)) ( ( (sequenceABC (a Int) (b Bool) (c Int)) )
))
(declare-fun /ArrayIntOfSequenceABC () (Array Int SequenceABC))
(check-sat)
(declare-fun x2 () Int)
(declare-fun y1 () Int)
(declare-fun y2 () Int)
-(declare-datatypes () ( (type
+(declare-datatypes ((type 0)) ( (
(constructor1 (f1 Int))
(constructor2 (f2 Int))
)))
(define-fun mktest ((constructor Int) (p1 Int) (p2 Int)) type (ite (= constructor 1) (constructor1 p1) (constructor2 p2)))
(assert (distinct (mktest x1 x2 x2) (mktest y1 y2 y2)))
-(check-sat)
\ No newline at end of file
+(check-sat)
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-(declare-codatatypes () ((Stream (C (c Stream)) (D (d Stream)) (E (e Stream)))))
+(declare-codatatypes ((Stream 0)) (((C (c Stream)) (D (d Stream)) (E (e Stream)))))
(declare-const z Stream)
(declare-const x Stream)
(assert (= w (E y)))
(assert (= x (C v)))
(assert (distinct x y z u v w))
-(check-sat)
\ No newline at end of file
+(check-sat)
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
-(declare-codatatypes () ((list (cons (head Int) (tail list)))))
+(declare-codatatypes ((list 0)) (((cons (head Int) (tail list)))))
(declare-fun x () list)
(declare-fun y () list)
(set-info :status sat)
(declare-sort a_ 0)
(declare-fun __nun_card_witness_0 () a_)
-(declare-codatatypes ()
- ((llist_ (LCons_ (_select_LCons__0 a_) (_select_LCons__1 llist_))
- (LNil_ ))))
+(declare-codatatypes ((llist_ 0))
+ (((LCons_ (_select_LCons__0 a_) (_select_LCons__1 llist_))
+ (LNil_ ))))
(declare-fun s () llist_)
(declare-fun a () a_)
(declare-fun b () a_)
(assert (= s (LCons_ a (LCons_ b s))))
-(check-sat)
\ No newline at end of file
+(check-sat)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
(declare-fun start!13 () Bool)
-; COMMAND-LINE: --lang=smt2.6
-; EXPECT: sat
(set-logic ALL)
(set-info :status sat)
-(declare-datatypes ( ( Tree 1) ( TreeList 1) ) (
+(declare-datatypes ( (Tree 1) (TreeList 1) ) (
(par ( X ) ( ( node ( value X ) ( children ( TreeList X )) )))
(par ( Y ) ( ( empty ) ( insert ( head ( Tree Y )) ( tail ( TreeList Y ))) ))
))
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
(set-logic QF_ALL_SUPPORTED)
(set-info :status sat)
(declare-datatypes (T S) ( (Pair (pair (first T) (second S)) ) ) )
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic QF_ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes (T S) ( (Pair (pair (first T) (second S)) ) ) )
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
(set-logic ALL)
(set-info :status sat)
(declare-datatypes () ((D (C (R Bool)))))
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
-(declare-datatypes () ((Unit (u))))
+(declare-datatypes ((Unit 0)) (((u))))
(declare-fun x () Unit)
(assert (not (is-u x)))
(check-sat)
-; COMMAND-LINE: --lang=smt2.6
-; EXPECT: sat
(set-logic ALL)
(set-info :status sat)
(declare-datatypes ((nat 0)(list 0)(tree 0)) (((succ (pred nat)) (zero))
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: sat
;(set-option :produce-models true)
(set-logic QF_ALL_SUPPORTED)
(set-info :status sat)
(set-logic ALL_SUPPORTED)
(set-info :status sat)
(declare-sort term 0)
-(declare-codatatypes () (
- (llist_tree (lnil_tree )
+(declare-codatatypes ((llist_tree 0) (tree 0)) (
+ ( (lnil_tree )
(lcons_tree (_select_llist_tree_0 tree)
(_select_llist_tree_1 llist_tree)))
- (tree (leaf (_select_tree_0 term))
+ ((leaf (_select_tree_0 term))
(node (_select_tree_1 llist_tree)))
))
(declare-fun nun_sk_2 () term)
(node
(lcons_tree (leaf nun_sk_1)
(lcons_tree (leaf nun_sk_2) (lcons_tree nun_sk_0 lnil_tree))))))
-(check-sat)
\ No newline at end of file
+(check-sat)
(set-logic QF_ALL_SUPPORTED)
(set-info :status unsat)
-(declare-codatatypes () ((Stream (S (s Stream)))))
+(declare-codatatypes ((Stream 0)) (((S (s Stream)))))
(declare-fun x () Stream)
(declare-fun y () Stream)
(assert (not (= x y)))
-(check-sat)
\ No newline at end of file
+(check-sat)
(set-logic QF_ALL_SUPPORTED)
(set-info :status sat)
-(declare-datatypes () ((DNat (dnat (data Nat)))
- (Nat (succ (pred DNat)) (zero))))
+(declare-datatypes ((DNat 0) (Nat 0)) (((dnat (data Nat)))
+ ((succ (pred DNat)) (zero))))
(declare-fun x () Nat)
(assert (not (= x zero)))
-(check-sat)
\ No newline at end of file
+(check-sat)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
; Preamble --------------
(set-logic ALL_SUPPORTED)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: unsat
; Preamble --------------
(set-logic ALL_SUPPORTED)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: unsat
; Preamble --------------
(set-option :produce-models true)
(= (ite (= (x38 (select x62 x63)) x3) (ite (and (=> (= (x40 (select x62 x63)) x69) (=> (= (x41 (select x62 x63)) x71) (=> (= x65 (store x67 x71 (d53 (x46 (x43 (select x62 x63)))))) (=> (= x70 (store x62 x63 (let ((x77 (select x62 x63))) (x44 (x38 x77) (x39 x77) (x40 x77) (x41 x77) (x42 x77) x32)))) (=> (= x68 (store x70 x63 (let ((x78 (select x70 x63))) (x44 x4 (x39 x78) (x40 x78) (x41 x78) (x42 x78) (x43 x78)))))
(=> (= (store x65 x69 (x51 (let ((x82 (ite (is-x49 (select x65 x69)) (let ((x79 (x48 (select x65 x69)))) (x57 x79)) (ite (is-x51 (select x65 x69)) (let ((x80 (x50 (select x65 x69)))) x80) (let ((x81 (s52 (select x65 x69)))) (x58 x81)))))) (x28 x4 x3 (x25 x82) (x26 x82) (+ (x27 (ite (is-x49 (select x65 x69)) (let ((x83 (x48 (select x65 x69)))) (x57 x83)) (ite (is-x51 (select x65 x69)) (let ((x84 (x50 (select x65 x69)))) x84) (let ((x85 (s52 (select x65 x69)))) (x58 x85))))) 1))))) x64) (forall ((x86 x6)) (=> (and (= x3 (x7 x86)) (= x3 (select x61 x86)) (= (select x66 x86) x16)) (= (ite (is-d53 (select x64 x86)) x3 x4) x3))))))))) (= x3 (x38 (select x62 x63)))) x3 x4) (ite (forall ((x87 x6)) (=> (and (= x3 (select x61 x87)) (= x3 (x7 x87)) (= x16 (select x66 x87))) (= x3 (ite (is-d53 (select x67 x87)) x3 x4)))) x3 x4)) x3))))
-(check-sat)
\ No newline at end of file
+(check-sat)
-; COMMAND-LINE: --fmf-fun --no-check-models
+; COMMAND-LINE: --fmf-fun --no-check-models --lang=smt2.5
; EXPECT: sat
(set-logic UFDTSLIA)
(set-info :smt-lib-version 2.5)
-; COMMAND-LINE: --fmf-fun-rlv --no-check-models
+; COMMAND-LINE: --fmf-fun-rlv --no-check-models --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(define-fun $$isTrue$$ ((b Bool)) Bool b)
-; COMMAND-LINE: --fmf-fun --no-check-models
+; COMMAND-LINE: --fmf-fun --no-check-models --lang=smt2.5
; EXPECT: sat
(set-logic ALL)
(set-info :status sat)
; COMMAND-LINE: --fmf-bound
; EXPECT: sat
(set-logic ALL)
-(declare-datatypes () ((list (cons (head Int) (tail list)) (nil))))
+(declare-datatypes ((list 0)) (((cons (head Int) (tail list)) (nil))))
(declare-fun P (Int) Bool)
(declare-fun S () (Set list))
; should construct instantiation involving selectors for l
(declare-fun l () list)
-(assert (is-cons l))
+(assert ((_ is cons) l))
(assert (member l S))
; should not contribute to instantiations
-; COMMAND-LINE: --fmf-fun
+; COMMAND-LINE: --fmf-fun --lang=smt2.5
; EXPECT: sat
(set-logic UFDTLIA)
(declare-datatypes () (
(declare-fun d () U)
(assert (distinct a b c))
(declare-sort V 0)
-(declare-datatypes () ((ufin1 (cons1 (s11 U) (s13 ufin2))) (ufin2 (cons2 (s21 V) (s22 U)) (cons3))))
+(declare-datatypes ((ufin1 0) (ufin2 0)) (((cons1 (s11 U) (s13 ufin2))) ((cons2 (s21 V) (s22 U)) (cons3))))
(declare-fun P (ufin1 ufin2) Bool)
(declare-fun Q (ufin1 ufin1) Bool)
(assert (forall ((x ufin1) (y ufin2) (z ufin1)) (or (P x y) (Q x z))))
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(declare-sort U 0)
(set-logic ALL_SUPPORTED)
(set-info :status sat)
(declare-sort U 0)
-(declare-datatypes () ((D (cons (x Int) (y U)))))
+(declare-datatypes ((D 0)) (((cons (x Int) (y U)))))
(declare-fun d1 () D)
(declare-fun d2 () D)
(declare-fun d3 () D)
(declare-fun a () U)
(declare-fun P (U) Bool)
(assert (P a))
-(check-sat)
\ No newline at end of file
+(check-sat)
(set-logic ALL_SUPPORTED)
(declare-sort a 0)
-(declare-datatypes () ((tree (Leaf (lab a)))))
+(declare-datatypes ((tree 0)) (((Leaf (lab a)))))
(declare-sort alpha 0)
(declare-fun alphabet (tree a) Bool)
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(declare-sort a 0)
-(declare-datatypes () ((prod (Pair (gx a) (gy a)))))
+(declare-datatypes ((prod 0)) (((Pair (gx a) (gy a)))))
(declare-fun p () prod)
(assert (forall ((x a) (y a)) (not (= p (Pair x y)))))
(check-sat)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes () ((St (Block!2236 (body!2237 List!2293)) (For!2238 (init!2239 St) (expr!2240 Ex) (step!2241 St) (body!2242 St)) (IfTE (expr!2244 Ex) (then!2245 St) (elze!2246 St)) (Skip!2250) (While (expr!2252 Ex) (body St)))
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
-; COMMAND-LINE: --finite-model-find --fmf-inst-engine --uf-ss-fair-monotone
+; COMMAND-LINE: --finite-model-find --fmf-inst-engine --uf-ss-fair-monotone --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
(declare-fun cowlThing ($$unsorted) Bool)
(declare-fun xsd_integer ($$unsorted) Bool)
(declare-fun xsd_string ($$unsorted) Bool)
-(declare-fun is () $$unsorted)
+(declare-fun _is () $$unsorted)
(assert (and (forall ((X $$unsorted)) (cowlThing X) ) (forall ((X $$unsorted)) (not (cowlNothing X)) )))
(assert (forall ((X $$unsorted)) (= (xsd_string X) (not (xsd_integer X))) ))
-(assert (and (forall ((X $$unsorted)) (or (not (cowlThing X)) (= X is)) ) (cowlThing is)))
-(assert (cowlThing is))
-(assert (and (forall ((X $$unsorted)) (cowlThing X) ) (forall ((X $$unsorted)) (not (cowlNothing X)) ) (forall ((X $$unsorted)) (or (not (cowlThing X)) (= X is)) )))
+(assert (and (forall ((X $$unsorted)) (or (not (cowlThing X)) (= X _is)) ) (cowlThing _is)))
+(assert (cowlThing _is))
+(assert (and (forall ((X $$unsorted)) (cowlThing X) ) (forall ((X $$unsorted)) (not (cowlNothing X)) ) (forall ((X $$unsorted)) (or (not (cowlThing X)) (= X _is)) )))
(check-sat)
-; COMMAND-LINE: --finite-model-find --fmf-inst-engine --uf-ss-fair-monotone
+; COMMAND-LINE: --finite-model-find --fmf-inst-engine --uf-ss-fair-monotone --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-; COMMAND-LINE: --finite-model-find --dt-rewrite-error-sel
+; COMMAND-LINE: --finite-model-find --dt-rewrite-error-sel --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(declare-datatypes () ((Nat (succ (pred Nat)) (zero)) (Lst (cons (hd Nat) (tl Lst)) (nil))))
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(declare-sort b__ 0)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(declare-sort elem 0)
-(declare-datatypes () ((list (Nil) (Cons (hd elem) (tl list)))))
+(declare-datatypes ((list 0)) (((Nil) (Cons (hd elem) (tl list)))))
(define-fun-rec f ((x list)) elem
- (ite (is-Nil x) (f x) (hd x))
+ (ite ((_ is Nil) x) (f x) (hd x))
)
(declare-fun t () elem)
(assert (= t (f Nil)))
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes () ((Nat!2409 (succ!2410 (pred!2411 Nat!2409)) (zero!2412))
(forall ((?j I_count!263)) (ite (is-nil!2417 (count!263_arg_1_7 ?j)) true (ite (is-cons!2414 (count!263_arg_1_7 ?j)) (ite (= (count!263_arg_0_6 ?j) (ite (is-cons!2414 (count!263_arg_1_7 ?j)) (head!2415 (count!263_arg_1_7 ?j)) (head!2415_uf_3 (count!263_arg_1_7 ?j)))) (not (forall ((?z I_count!263)) (or (not (= (count!263_arg_0_6 ?z) (count!263_arg_0_6 ?j))) (not (= (count!263_arg_1_7 ?z) (ite (is-cons!2414 (count!263_arg_1_7 ?j)) (tail!2416 (count!263_arg_1_7 ?j)) (tail!2416_uf_2 (count!263_arg_1_7 ?j)))))) )) (not (forall ((?z I_count!263)) (or (not (= (count!263_arg_0_6 ?z) (count!263_arg_0_6 ?j))) (not (= (count!263_arg_1_7 ?z) (ite (is-cons!2414 (count!263_arg_1_7 ?j)) (tail!2416 (count!263_arg_1_7 ?j)) (tail!2416_uf_2 (count!263_arg_1_7 ?j)))))) ))) true)) )
)
)
-(check-sat)
\ No newline at end of file
+(check-sat)
; COMMAND-LINE: --incremental --fmf-fun
(set-logic ALL_SUPPORTED)
-(declare-datatypes () ((Lst (cons (head Int) (tail Lst)) (nil))))
+(declare-datatypes ((Lst 0)) (((cons (head Int) (tail Lst)) (nil))))
(define-fun-rec sum ((l Lst)) Int (ite (is-nil l) 0 (+ (head l) (sum (tail l)))))
(declare-fun input () Int)
-; COMMAND-LINE: --incremental --fmf-fun --strings-exp
+; COMMAND-LINE: --incremental --fmf-fun --strings-exp --lang=smt2.5
(set-logic ALL_SUPPORTED)
(declare-datatypes () (
(List_T_C (List_T_C$CNil_T_CustomerType) (ListTC (ListTC$head T_CustomerType) (ListTC$tail List_T_C)))
; EXPECT: sat
(push 1)
(check-sat)
-(pop 1)
\ No newline at end of file
+(pop 1)
; COMMAND-LINE: --quant-ind --incremental --rewrite-divk
(set-logic ALL_SUPPORTED)
-(declare-datatypes () ((Lst (cons (head Int) (tail Lst)) (nil))))
+(declare-datatypes ((Lst 0)) (((cons (head Int) (tail Lst)) (nil))))
(define-fun-rec app ((l1 Lst) (l2 Lst)) Lst (ite (is-nil l1) l2 (cons (head l1) (app (tail l1) l2))))
(define-fun-rec rev ((l Lst)) Lst (ite (is-nil l) nil (app (rev (tail l)) (cons (head l) nil))))
; EXPECT: unsat
-; COMMAND-LINE: --incremental
+; COMMAND-LINE: --incremental --lang=smt2.5
; EXPECT: unsat
; EXPECT: sat
; EXPECT: sat
-; COMMAND-LINE: --incremental --fmf-fun-rlv --no-check-models
+; COMMAND-LINE: --incremental --fmf-fun-rlv --no-check-models --lang=smt2.5
(set-logic ALL_SUPPORTED)
(declare-datatypes () (
; COMMAND-LINE: --incremental --fmf-fun --no-check-models
(set-logic UFDTLIA)
(set-option :produce-models true)
-(set-info :smt-lib-version 2.5)
-(declare-datatypes () ((List (Nil) (Cons (Cons$head Int) (Cons$tail List)))))
-(define-fun-rec all-z ((x List)) Bool (=> (is-Cons x) (and (= 0 (Cons$head x)) (all-z (Cons$tail x)))))
-(define-fun-rec len ((x List)) Int (ite (is-Nil x) 0 (+ 1 (len (Cons$tail x)))))
+(declare-datatypes ((List 0)) (((Nil) (Cons (Cons$head Int) (Cons$tail List)))))
+(define-fun-rec all-z ((x List)) Bool (=> ((_ is Cons) x) (and (= 0 (Cons$head x)) (all-z (Cons$tail x)))))
+(define-fun-rec len ((x List)) Int (ite ((_ is Nil) x) 0 (+ 1 (len (Cons$tail x)))))
(declare-fun root() List)
; EXPECT: sat
(assert (and (all-z root) (<= 1 (len root))))
-; COMMAND-LINE: --lang=smt2.6
-; EXPECT: unsat
(set-logic UFDT)
(set-info :source |
Generated by: Andrew Reynolds
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
+
;; produced by cvc4_14.drv ;;
(set-logic AUFBVDTNIRA)
(set-info :source |VC generated by SPARK 2014|)
-; COMMAND-LINE: --cbqi --dt-rewrite-error-sel
+; COMMAND-LINE: --cbqi --dt-rewrite-error-sel --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(declare-datatypes () ((List (cons (head Int) (tail List)) (nil))))
-; COMMAND-LINE: --full-saturate-quant
+; COMMAND-LINE: --full-saturate-quant --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
; EXPECT: unknown
(set-logic ALL_SUPPORTED)
-(declare-datatypes (T) ((List (cons (hd T) (tl (List T))) (nil))))
+(declare-datatypes ((List 1)) ((par (T) ((cons (hd T) (tl (List T))) (nil)))))
(declare-fun R ((List Real)) Bool)
(assert (forall ((x (List Int))) (R x)))
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes (T) ((List (cons (head T) (tail (List T))) (nil))))
; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-(declare-datatypes () ((nat (Suc (pred nat)) (zero))))
+(declare-datatypes ((nat 0)) (( (Suc (pred nat)) (zero))))
(declare-fun y () nat)
(assert (forall ((x nat)) (not (= y (Suc x)))))
(check-sat)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes () ((Formula!953 (And!954 (lhs!955 Formula!953) (rhs!956 Formula!953)) (Not!957 (f!958 Formula!953)) (Or!959 (lhs!960 Formula!953) (rhs!961 Formula!953)) (Variable!962 (id!963 (_ BitVec 32))))
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
-(declare-datatypes () ((Lst (cons (head Int) (tail Lst)) (nil))))
+(declare-datatypes ((Lst 0)) (((cons (head Int) (tail Lst)) (nil))))
(define-fun-rec len ((x Lst)) Int (ite (is-cons x) (+ 1 (len (tail x))) 0))
(assert (= (len (cons 0 nil)) 0))
-(check-sat)
\ No newline at end of file
+(check-sat)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-sort A$ 0)
-; COMMAND-LINE:
+; COMMAND-LINE: --lang=smt2.5
; EXPECT: unknown
; this will fail if type rule for APPLY_UF requires arguments to be subtypes
(set-logic ALL_SUPPORTED)
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(set-info :status unsat)
-(declare-datatypes (
-(nat (succ (pred nat)) (zero ) )
-(list (cons (car nat)(cdr list)) (nil ) )
+(declare-datatypes ((nat 0) (list 0)) (
+((succ (pred nat)) (zero ) )
+((cons (car nat)(cdr list)) (nil ) )
))
(set-info :status unsat)
-(declare-datatypes (
-(nat (succ (pred nat)) (zero ) )
-(list (cons (car nat)(cdr list)) (nil ) )
+(declare-datatypes ((nat 0) (list 0)) (
+((succ (pred nat)) (zero ) )
+((cons (car nat)(cdr list)) (nil ) )
))
(declare-sort Loc 0)
(declare-const loc0 Loc)
-(declare-datatypes () ((Node (node (data Int) (left Loc) (right Loc)))))
+(declare-datatypes ((Node 0)) (((node (data Int) (left Loc) (right Loc)))))
(declare-fun data0 () Node)
(set-logic ALL_SUPPORTED)
(set-info :status sat)
-(declare-datatypes () ((D (A (a Int)))))
+(declare-datatypes ((D 0)) (((A (a Int)))))
(declare-fun x1 () D)
(declare-fun S () (Set D))
(declare-fun P (D) Bool)
(set-logic UFDTSLIA)
(set-info :status sat)
-(declare-datatypes () ( (T (TC (TCb String))) ) )
+(declare-datatypes ((T 0)) ( ((TC (TCb String))) ) )
(declare-fun root5 () String)
(declare-fun root6 () T)
(declare-var m Int)
(declare-var s Int)
(declare-var inc Int)
-(declare-datatypes () ( (tuple2 (tuple2 (_m Int) (_s Int))) ))
+(declare-datatypes ((tuple2 0)) ( ((tuple2 (_m Int) (_s Int))) ))
(synth-fun x12 ((m Int) (s Int) (inc Int)) tuple2)
(constraint (=>
; EXPECT: unsat
(set-logic LIA)
-(declare-datatypes () ((List (cons (head Int) (tail List)) (nil))))
+(declare-datatypes ((List 0)) (((cons (head Int) (tail List)) (nil))))
(synth-fun f ((x Int)) List)
; COMMAND-LINE: --cegqi-si=all --no-dump-synth
(set-logic LIA)
-(declare-datatypes () ((List (cons (head Int) (tail List)) (nil))))
+(declare-datatypes ((List 0)) (((cons (head Int) (tail List)) (nil))))
(synth-fun f ((x Int)) List)
; COMMAND-LINE: --cegqi-si=all --no-dump-synth
(set-logic ALL_SUPPORTED)
-(declare-datatypes () ((List (cons (head Int) (tail List)) (nil))))
+(declare-datatypes ((List 0)) (((cons (head Int) (tail List)) (nil))))
(synth-fun f ((x Int)) List)
; EXPECT: unsat
-; COMMAND-LINE: --cegqi
+; COMMAND-LINE: --cegqi --lang=smt2.5
(set-logic UFDTLIA)
(set-logic LIA)
-(declare-datatypes () ((List (cons (head Int) (tail List)) (nil))))
+(declare-datatypes ((List 0)) (((cons (head Int) (tail List)) (nil))))
(define-fun g ((x Int)) List (cons (+ x 1) nil))
(define-fun i () List (cons 3 nil))
+; COMMAND-LINE: --lang=smt2.5
+; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes () ( (tuple2!879 (tuple2!879!880 (_1!881 Int) (_2!882 Int))) ))
-; COMMAND-LINE: --finite-model-find --uf-ss=no-minimal
+; COMMAND-LINE: --finite-model-find --uf-ss=no-minimal --lang=smt2.5
; EXPECT: unsat
(set-logic ALL_SUPPORTED)
(declare-datatypes () ((Statement!1556 (Assign!1557 (varID!1558 (_ BitVec 32)) (expr!1559 Expression!1578)) (Block!1560 (body!1561 List!1617)) (For!1562 (init!1563 Statement!1556) (expr!1564 Expression!1578) (step!1565 Statement!1556) (body!1566 Statement!1556)) (IfThenElse!1567 (expr!1568 Expression!1578) (then!1569 Statement!1556) (elze!1570 Statement!1556)) (Print!1571 (msg!1572 (_ BitVec 32)) (varID!1573 (_ BitVec 32))) (Skip!1574) (While!1575 (expr!1576 Expression!1578) (body!1577 Statement!1556)))
; EXPECT: unsat
-; COMMAND-LINE: --finite-model-find
+; COMMAND-LINE: --finite-model-find --lang=smt2.5
(set-logic ALL_SUPPORTED)
(set-info :status unsat)
(declare-datatypes () ((nat__ (Suc__ (_select_Suc___0 nat__)) (zero__ ))))
+; COMMAND-LINE: --lang=smt2.0
+; EXPECT: sat
(set-logic ALL_SUPPORTED)
(set-info :status sat)
(set-option :strings-exp true)