[pypy-svn] r22960 - pypy/dist/pypy/lib/logic/computation_space
auc at codespeak.net
auc at codespeak.net
Thu Feb 2 17:28:27 CET 2006
Author: auc
Date: Thu Feb 2 17:28:26 2006
New Revision: 22960
Modified:
pypy/dist/pypy/lib/logic/computation_space/computationspace.py
Log:
Modified: pypy/dist/pypy/lib/logic/computation_space/computationspace.py
==============================================================================
--- pypy/dist/pypy/lib/logic/computation_space/computationspace.py (original)
+++ pypy/dist/pypy/lib/logic/computation_space/computationspace.py Thu Feb 2 17:28:26 2006
@@ -323,7 +323,7 @@
raise NotInStore(name)
def is_bound(self, var):
- """check wether a var is bound is locally bound"""
+ """check wether a var is locally bound"""
if self.TOP:
return var.is_bound()
return len(var.cs_get_dom(self)) == 1
@@ -334,10 +334,10 @@
def val(self, var):
"""return the local binding without blocking"""
- if self.TOP:
+ if self.TOP: # the real thing
return var.val
- if self.is_bound(var):
- return var.cs_get_dom(self)[0]
+ if self.is_bound(var): # the speculative val
+ return self.dom(var)[0]
return NoValue
#-- Constraints -------------------------
More information about the Pypy-commit
mailing list