Skip to content

Commit 8980c84

Browse files
committed
avoid checking decorators for synthetic functions
1 parent 33d06cc commit 8980c84

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

mypy/checker.py

+2
Original file line numberDiff line numberDiff line change
@@ -4876,6 +4876,8 @@ def visit_del_stmt(self, s: DelStmt) -> None:
48764876
)
48774877

48784878
def visit_decorator(self, e: Decorator) -> None:
4879+
if e.func.is_synthetic():
4880+
return
48794881
for d in e.decorators:
48804882
if isinstance(d, RefExpr):
48814883
if d.fullname == "typing.no_type_check":

0 commit comments

Comments
 (0)