]> granicus.if.org Git - python/commitdiff
Small change by Jack Jansen.
authorGuido van Rossum <guido@python.org>
Tue, 9 Mar 1999 16:05:26 +0000 (16:05 +0000)
committerGuido van Rossum <guido@python.org>
Tue, 9 Mar 1999 16:05:26 +0000 (16:05 +0000)
Test for self.returntype behaving like OSErr rather than being it.

Tools/bgen/bgen/macsupport.py

index 5a00eca96eb3042e53a03750cae43b136405a0da..38c9d9652e0796456819d3e717e427c4c460a902 100644 (file)
@@ -150,9 +150,9 @@ initstuff = """
 # This requires that the OSErr type (defined above) has a non-trivial
 # errorCheck method.
 class OSErrMixIn:
-       "Mix-in class to treat OSErr return values special"
+       "Mix-in class to treat OSErr/OSStatus return values special"
        def makereturnvar(self):
-               if self.returntype is OSErr:
+               if self.returntype.__class__ == OSErrType:
                        return Variable(self.returntype, "_err", ErrorMode)
                else:
                        return Variable(self.returntype, "_rv", OutMode)