From 7941bc42a3fceaa926b68797f92644e2a30d1970 Mon Sep 17 00:00:00 2001 From: Olivier Breuleux Date: Thu, 12 Dec 2024 10:59:35 -0500 Subject: [PATCH] Remove useless _setattrs --- src/ovld/core.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/ovld/core.py b/src/ovld/core.py index e0c235e..31ce44b 100644 --- a/src/ovld/core.py +++ b/src/ovld/core.py @@ -27,13 +27,6 @@ _current_id = itertools.count() -@keyword_decorator -def _setattrs(fn, **kwargs): - for k, v in kwargs.items(): - setattr(fn, k, v) - return fn - - def bootstrap_dispatch(ov, name): def first_entry(*args, **kwargs): ov.compile() @@ -327,7 +320,6 @@ def __get__(self, obj, cls): self.compile() return self.dispatch.__get__(obj, cls) - @_setattrs(rename="dispatch") def __call__(self, *args, **kwargs): # pragma: no cover """Call the overloaded function. @@ -337,7 +329,6 @@ def __call__(self, *args, **kwargs): # pragma: no cover self.compile() return self.dispatch(*args, **kwargs) - @_setattrs(rename="next") def next(self, *args): """Call the next matching method after the caller, in terms of priority or specificity.""" fr = sys._getframe(1)