Skip to content

Commit

Permalink
BUG: return reordering setting in cudd pick_iter
Browse files Browse the repository at this point in the history
At the end of pick_iter() in the CUDD wrapper, the original value of
the `reordering` option should be restored. Before this changeset, it
is always assigned True.

closes #40
#40
  • Loading branch information
slivingston committed Feb 1, 2019
1 parent 954c704 commit 32bc137
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dd/cudd.pyx
Expand Up @@ -850,7 +850,7 @@ cdef class BDD(object):
'Missing bits: '
'support - care_vars = {missing}').format(
missing=missing))
self.configure(reordering=False)
config = self.configure(reordering=False)
gen = Cudd_FirstCube(self.manager, u.node, &cube, &value)
assert gen != NULL, 'first cube failed'
try:
Expand All @@ -863,7 +863,7 @@ cdef class BDD(object):
r = Cudd_NextCube(gen, &cube, &value)
finally:
Cudd_GenFree(gen)
self.configure(reordering=True)
self.configure(reordering=config['reordering'])

cpdef Function apply(
self,
Expand Down

0 comments on commit 32bc137

Please sign in to comment.