1
0
Fork 0
mirror of synced 2024-11-10 10:58:57 -05:00
dotbot/dotbot/util/compat.py

6 lines
210 B
Python
Raw Normal View History

def with_metaclass(meta, *bases):
class metaclass(meta):
def __new__(cls, name, this_bases, d):
return meta(name, bases, d)
return type.__new__(metaclass, 'temporary_class', (), {})