[pypy-svn] r52633 - pypy/dist/pypy/translator/cli

antocuni at codespeak.net antocuni at codespeak.net
Mon Mar 17 11:46:36 CET 2008


Author: antocuni
Date: Mon Mar 17 11:46:36 2008
New Revision: 52633

Modified:
   pypy/dist/pypy/translator/cli/dotnet.py
Log:
(arigo, antocuni)

for the series "how can it ever worked", we need to test for
ootype.String *before* testing for ootype.OOType.



Modified: pypy/dist/pypy/translator/cli/dotnet.py
==============================================================================
--- pypy/dist/pypy/translator/cli/dotnet.py	(original)
+++ pypy/dist/pypy/translator/cli/dotnet.py	Mon Mar 17 11:46:36 2008
@@ -446,13 +446,15 @@
             # can_be_None == True because it can always return None, if it fails
             classdef = self.bookkeeper.getuniqueclassdef(TYPE)
             return SomeInstance(classdef, can_be_None=True)
+        elif TYPE in BOXABLE_TYPES:
+            return OverloadingResolver.lltype_to_annotation(TYPE)
         elif isinstance(TYPE, ootype.StaticMethod):
             return SomeOOStaticMeth(TYPE)
         elif isinstance(TYPE, ootype.OOType):
             return SomeOOInstance(TYPE)
         else:
-            assert TYPE in BOXABLE_TYPES
-            return OverloadingResolver.lltype_to_annotation(TYPE)
+            assert False
+            
 
     def specialize_call(self, hop):
         assert hop.args_s[1].is_constant()



More information about the Pypy-commit mailing list