changeset 1337:568f9c696979

always use "is not None" instead of "!= None"
author Martin Geisler <mg@cs.au.dk>
date Tue, 27 Oct 2009 11:43:37 +0100
parents 13f6a14cafe0
children c7403cb56ace c2a553514804 3f6c65d4c9c1
files apps/benchutil.py viff/orlandi.py
diffstat 2 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/apps/benchutil.py	Tue Oct 27 11:35:09 2009 +0100
+++ b/apps/benchutil.py	Tue Oct 27 11:43:37 2009 +0100
@@ -108,7 +108,7 @@
 
     def run_test(self, shares):
         # print "rt", self.rt.program_counter, self.pc
-        if self.pc != None:
+        if self.pc is not None:
             self.rt.program_counter = self.pc
         else:
             self.pc = list(self.rt.program_counter)
--- a/viff/orlandi.py	Tue Oct 27 11:35:09 2009 +0100
+++ b/viff/orlandi.py	Tue Oct 27 11:43:37 2009 +0100
@@ -455,7 +455,7 @@
         3. ``[x] = [r] - Delta``
         """
         # TODO: Communitcation costs?
-        assert (self.id in inputters and number != None) or (self.id not in inputters)
+        assert (self.id in inputters and number is not None) or (self.id not in inputters)
 
         self.program_counter[-1] += 1