Skip to content

Commit

Permalink
Add public new method to ConditionalDatabase
Browse files Browse the repository at this point in the history
  • Loading branch information
Dekker1 committed May 6, 2024
1 parent 3a97525 commit d5c43e1
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/pindakaas/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,11 @@ pub struct ConditionalDatabase<'a, DB: ClauseDatabase + ?Sized> {
db: &'a mut DB,
conditions: Vec<Lit>,
}
impl<'a, DB: ClauseDatabase + ?Sized> ConditionalDatabase<'a, DB> {
pub fn new(db: &'a mut DB, conditions: Vec<Lit>) -> Self {
Self { db, conditions }
}
}
impl<'a, DB: ClauseDatabase + ?Sized> ClauseDatabase for ConditionalDatabase<'a, DB> {
fn new_var(&mut self) -> Var {
self.db.new_var()
Expand Down

0 comments on commit d5c43e1

Please sign in to comment.