Use nested config structure

This commit is contained in:
Zaid Abdulla committed 2018-12-26 00:22:07 -08:00
1 parent 581a510960
commit 30dbf0cf40
15 files changed
+366 -251

No files matched your search

+5
View File
@@ -3,6 +3,7 @@
const filterParser = require("./filter-parser");
const filterCnf = require("./filter-cnf");
const satSolver = require("./sat-solver");
const funcCache = require("./func-cache");
function* permute(arr) {
if (arr.length <= 1) {
@@ -24,6 +25,10 @@ class Filter {
else this.ast = filterParser.parse(str);
}
static parse(str) {
return new Filter(str);
}
toString() {
if (!this.string)
if (this.ast) this.string = filterParser.stringify(this.ast);