Eric Snow added the comment:

It's for times like this that I wonder if a simple serialization protocol might 
be worth it--something separate from __str__() but much simpler than the pickle 
protocol.  __str__() could be the fallback.  In the end, though, I always 
conclude that it's not worth adding yet another optional protocol to objects.  
Still, it would help in this case (at least for anything that knows to make use 
of the simple serialization protocol).

Alternately, would it make sense to add special handling of enums to the json 
module?  Do we already with pickle?

----------
nosy: +eric.snow

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue18264>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to