Commits

Anonymous committed a8e2f07 Draft

Cut out complex interpretation of signature types

This was copied from "enforceargs", but our little DSL will be different.

Comments (0)

Files changed (1)

pypy/annotation/signature.py

 
 def enforce_signature_args(funcdesc, paramtypes, actualtypes):
     assert len(paramtypes) == len(actualtypes)
-    params_s = []
-    for i, paramtype in enumerate(paramtypes):
-        params_s.append(annotation(paramtype, bookkeeper=funcdesc.bookkeeper))
+    params_s = paramtypes
     for i, (s_param, s_actual) in enumerate(zip(params_s, actualtypes)):
         if not s_param.contains(s_actual):
             raise Exception("%r argument %d:\n"
 
 
 def enforce_signature_return(funcdesc, sigtype, inferredtype):
-    annsigtype = annotation(sigtype, bookkeeper=funcdesc.bookkeeper)
-    return annsigtype
+    return sigtype