Serhiy Storchaka <storchaka+cpyt...@gmail.com> added the comment:

One such decorator was added in 3.7: xmlrpc.server.register_function (see 
issue7769). I don't think lru_cache should follow this example.

There are few cases in which such obscure decorators are more or less 
appropriate:

1. The function initially was not a decorator, and now it can be used as a 
decorator, but we need to pass additional optional arguments.

2. The decorator initially didn't take arguments, but we need to pass optional 
arguments now.

3. The majority of usages of the decorator don't take arguments.

Maybe needed to satisfy more than one of the above conditions.

----------

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

Reply via email to