forked from OCamlPro/alt-ergo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Treat missing values in models as abstract
When printing models, we can end up with class representatives that are not actually in the model. This can happen if a class representative is a defined constant, but also if it is an intermediate fresh constant introduced by the solver (!kXXX). This is because, in a class containing only uninterpreted terms, the representative will be the minimum term, independently of whether it is defined or fresh. This patch records and adds such terms to the `values` table as a (named) `Abstract` constant. This ensures that the same abstract value is used for all uses of a given constant. This is backported from a0575d2 for branch 2.5.x. Fixes OCamlPro#854
- Loading branch information
1 parent
26298cc
commit 4d1b51d
Showing
8 changed files
with
148 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
|
||
unknown | ||
( | ||
(define-fun intrefqtmk ((arg_0 Int)) intref (as @!k2 intref)) | ||
(define-fun f ((arg_0 Int)) Int 0) | ||
(define-fun a () Int 0) | ||
(define-fun a1 () Int 0) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
(set-logic ALL) | ||
(set-info :smt-lib-version 2.6) | ||
(set-option :produce-models true) | ||
(declare-sort intref 0) | ||
(declare-fun intrefqtmk (Int) intref) | ||
(declare-fun a () Int) | ||
(declare-fun f (Int) Int) | ||
(define-fun aqtunused ((x Int)) intref (intrefqtmk (f a))) | ||
(assert (= (aqtunused 0) (aqtunused 1))) | ||
(declare-fun a1 () Int) | ||
(assert (not (and (<= 5 a1) (<= a1 15)))) | ||
(check-sat) | ||
(get-model) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
unknown | ||
( | ||
(define-fun intrefqtmk ((arg_0 Int)) intref (as @!k1 intref)) | ||
(define-fun a () Int 0) | ||
(define-fun a1 () Int 0) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
(set-logic ALL) | ||
(set-info :smt-lib-version 2.6) | ||
(set-option :produce-models true) | ||
(declare-sort intref 0) | ||
(declare-fun intrefqtmk (Int) intref) | ||
(declare-fun a () Int) | ||
(define-fun aqtunused () intref (intrefqtmk a)) | ||
(declare-fun a1 () Int) | ||
(assert (not (and (<= 5 a1) (<= a1 15)))) | ||
(check-sat) | ||
(get-model) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
|
||
unknown | ||
( | ||
(define-fun intrefqtmk ((arg_0 Int)) intref (as @!k1 intref)) | ||
(define-fun another_mk ((arg_0 Int)) intref (as @!k1 intref)) | ||
(define-fun a () Int 0) | ||
(define-fun a1 () Int 0) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
(set-logic ALL) | ||
(set-info :smt-lib-version 2.6) | ||
(set-option :produce-models true) | ||
(declare-sort intref 0) | ||
(declare-fun intrefqtmk (Int) intref) | ||
(declare-fun another_mk (Int) intref) | ||
(declare-fun a () Int) | ||
(define-fun aqtunused () intref (intrefqtmk a)) | ||
(assert (= aqtunused (another_mk a))) | ||
(declare-fun a1 () Int) | ||
(assert (not (and (<= 5 a1) (<= a1 15)))) | ||
(check-sat) | ||
(get-model) |