Skip to content

Commit

Permalink
more Ostrich compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
pruemmer committed Dec 12, 2020
1 parent 39e279c commit f3c0c48
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 66 deletions.
3 changes: 3 additions & 0 deletions lib/model.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ function parsePrimitive(value) {
contents = contents.replace(/\\x([a-fA-F0-9]{2})/g, (a, b) => {
return String.fromCharCode(parseInt(b, 16));
});
contents = contents.replace(/\\u\{([a-fA-F0-9]+)\}/g, (a, b) => {
return String.fromCharCode(parseInt(b, 16));
});
contents = contents.replace(/\\b/g, "\b");
contents = contents.replace(/\\e/g, "\x1B");
contents = contents.replace(/\\n/g, "\n");
Expand Down
2 changes: 1 addition & 1 deletion lib/smt.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ exports.SMTSolver = class SMTSolver {
this._commandLogs[i].write(output, "utf8");
}
// Enable to see the SMT-LIB commands
// console.error(output);
fs.appendFileSync("smt-log.smt2", output);
this.process.stdin.write(output);
}

Expand Down
2 changes: 1 addition & 1 deletion lib/smt2/ostrich/prelude.smt2
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@
(define-sort Properties () (Array String MaybeVal))
(declare-fun GetProperties (Int) Properties)

(declare-fun EmptyObject () Properties) ; not supported: ((as const Properties) Nothing))
(define-fun EmptyObject () Properties ((as const Properties) Nothing))
126 changes: 62 additions & 64 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f3c0c48

Please sign in to comment.