Commit 06e48c0f authored by Stefan Behnel's avatar Stefan Behnel

support 'object' as type in cython.declare()

parent cbc0665c
......@@ -144,7 +144,7 @@ def address(arg):
return pointer(type(arg))([arg])
def declare(type=None, value=_Unspecified, **kwds):
if type is not None and hasattr(type, '__call__'):
if type not in (None, object) and hasattr(type, '__call__'):
if value is not _Unspecified:
return type(value)
else:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment