[Subversion] / PEAK-Rules / Predicates.txt  

Diff of /PEAK-Rules/Predicates.txt

Parent Directory | Revision Log

version 2566, Tue Jul 15 16:49:02 2008 UTC version 2567, Tue Jul 15 16:58:17 2008 UTC
Line 804 
Line 804 
     >>> always_testable(IsInstance(Add(Local('a'),Local('b'))))      >>> always_testable(IsInstance(Add(Local('a'),Local('b'))))
     False      False
   
     >>> always_testable(IsSubclass(Local('x')))  
     True  
     >>> always_testable(IsSubclass(Add(Local('a'),Local('b'))))  
     False  
   
     >>> always_testable(Comparison(Local('x')))      >>> always_testable(Comparison(Local('x')))
     True      True
     >>> always_testable(Comparison(Add(Local('a'),Local('b'))))      >>> always_testable(Comparison(Add(Local('a'),Local('b'))))
Line 824 
Line 819 
     >>> always_testable(Truth(Add(Local('a'),Local('b'))))      >>> always_testable(Truth(Add(Local('a'),Local('b'))))
     False      False
   
   Except for ``IsSubclass()``, which may need to have other tests applied before
   it::
   
       >>> always_testable(IsSubclass(Local('x')))
       False
   
 If you create a new predicate type, be sure to define a method for  If you create a new predicate type, be sure to define a method for
 ``always_testable`` that will recursively invoke ``always_testable`` on the  ``always_testable`` that will recursively invoke ``always_testable`` on the
 predicate's target expression.  If you don't do this, then your predicate  predicate's target expression.  If you don't do this, then your predicate


Generate output suitable for use with a patch program
Legend:
Removed from v.2566  
changed lines
  Added in v.2567

cvs-admin@eby-sarna.com

Powered by ViewCVS 1.0-dev

ViewCVS and CVS Help