A false midnight
A false midnight
Posted Mar 14, 2014 19:16 UTC (Fri) by mathstuf (subscriber, #69389)In reply to: A false midnight by zuki
Parent article: A false midnight
How do you do metaclasses supporting both? Python3's way is a syntax error in Python2 and Python2's way is ignored in Python3.
Posted Mar 15, 2014 12:58 UTC (Sat)
by edomaur (subscriber, #14520)
[Link]
A false midnight
Well, you can use the six library, there is some tools for that very case :
http://pythonhosted.org/six/#six.with_metaclass