aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/ann_module.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/ann_module.py')
-rw-r--r--Lib/test/ann_module.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/test/ann_module.py b/Lib/test/ann_module.py
index 9e6b87dac40..0567d6de1b6 100644
--- a/Lib/test/ann_module.py
+++ b/Lib/test/ann_module.py
@@ -6,6 +6,7 @@ Empty lines above are for good reason (testing for correct line numbers)
"""
from typing import Optional
+from functools import wraps
__annotations__[1] = 2
@@ -51,3 +52,9 @@ def foo(x: int = 10):
def bar(y: List[str]):
x: str = 'yes'
bar()
+
+def dec(func):
+ @wraps(func)
+ def wrapper(*args, **kwargs):
+ return func(*args, **kwargs)
+ return wrapper