Skip to content

Commit 8876276

Browse files
Fix slowdown based on repr in type
1 parent 315246f commit 8876276

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/egglog/runtime.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,8 @@ def __call__(cls, *args, **kwargs) -> type:
177177
for m in reversed(cls.__mro__):
178178
namespace.update(m.__dict__)
179179
init = namespace.pop("__init__")
180-
meta = types.new_class(f"type(type[{args}])", (BaseClassFactoryMeta,), {}, lambda ns: ns.update(**namespace))
181-
tp = types.new_class(f"type[{args}]", (), {"metaclass": meta})
180+
meta = types.new_class("type(RuntimeClass)", (BaseClassFactoryMeta,), {}, lambda ns: ns.update(**namespace))
181+
tp = types.new_class("RuntimeClass", (), {"metaclass": meta})
182182
init(tp, *args, **kwargs)
183183
return tp
184184

0 commit comments

Comments
 (0)