diff options
author | Clifford Wolf <clifford@clifford.at> | 2014-03-03 02:13:17 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2014-03-03 02:13:17 +0100 |
commit | d5bd93997c9ce7c31ef430684700a2096618672e (patch) | |
tree | a2f62a10775c5d4e19b99cfeafb187ba200c0290 /libs/ezsat/ezsat.cc | |
parent | 895e9fc70cb2d45c606c64a7b12d51dc0564c005 (diff) |
ezSAT: Added frozen_literal() API
Diffstat (limited to 'libs/ezsat/ezsat.cc')
-rw-r--r-- | libs/ezsat/ezsat.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libs/ezsat/ezsat.cc b/libs/ezsat/ezsat.cc index bbebee74..fb3d2499 100644 --- a/libs/ezsat/ezsat.cc +++ b/libs/ezsat/ezsat.cc @@ -67,6 +67,20 @@ int ezSAT::literal(const std::string &name) return literalsCache.at(name); } +int ezSAT::frozen_literal() +{ + int id = literal(); + freeze(id); + return id; +} + +int ezSAT::frozen_literal(const std::string &name) +{ + int id = literal(name); + freeze(id); + return id; +} + int ezSAT::expression(OpId op, int a, int b, int c, int d, int e, int f) { std::vector<int> args(6); |