Skip to content

Commit

Permalink
Add check to see if scratch is valid/fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
mattxwang committed Oct 23, 2023
1 parent 417e477 commit de58801
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/builder/bdd/robdd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,12 @@ impl<'a, T: IteTable<'a, BddPtr<'a>> + Default> RobddBuilder<'a, T> {
match bdd.scratch::<usize>() {
None => (),
Some(v) => {
return if bdd.is_neg() {
alloc[v].neg()
} else {
alloc[v]
if alloc.len() > v {
return if bdd.is_neg() {
alloc[v].neg()
} else {
alloc[v]
};
}
}
};
Expand Down

0 comments on commit de58801

Please sign in to comment.