Is there a Data Type in Python which cannot be typecast in string -


lets 'a' of type (which want know!)

doing thing like:

b = str(a) 

this should favorably raise typeerror

there no builtin python class raises typeerror str, define custom class:

class foo(object):     def __str__(self):         raise typeerror('can not stringified')   foo = foo() b = str(foo) 

raises typeerror.


Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

c# - must be a non-abstract type with a public parameterless constructor in redis -

ajax - PHP/JSON Login script (Twitter style) not setting sessions -