On 31/03/16 18:22, Johannes wrote:
On 31.03.2016 23:08, Justin C. Walker wrote:
2. Is there a way to tell, when hasattr(X, "foo") returns True,
whether "X.foo" can be called?

X.foo and x.foo.__call__ is None

!?

The only way to go here is

if callable(X.foo):
    print "X.foo is callable"

Vincent

--
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to