diff options
author | Carlton Gibson <carlton.gibson@noumenal.es> | 2023-01-11 21:17:26 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-11 21:17:26 (GMT) |
commit | 07a87f74faf31cdd755ac7de6d44531139899d1b (patch) | |
tree | 269e8cc207a034436e1372438844e00837fa3261 /Lib/inspect.py | |
parent | 6e4e14d98fe0868981f29701496d57a8223c5407 (diff) | |
download | cpython-07a87f74faf31cdd755ac7de6d44531139899d1b.zip cpython-07a87f74faf31cdd755ac7de6d44531139899d1b.tar.gz cpython-07a87f74faf31cdd755ac7de6d44531139899d1b.tar.bz2 |
gh-94912: Adjusted check for non-standard coroutine function marker. (#100935)
The initial implementation did not correctly identify explicitly
marked class instances.
Follow up to 532aa4e4e019812d0388920768ede7c04232ebe1
Diffstat (limited to 'Lib/inspect.py')
-rw-r--r-- | Lib/inspect.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/Lib/inspect.py b/Lib/inspect.py index 3db7745..8bb3a37 100644 --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -399,8 +399,6 @@ def _has_coroutine_mark(f): while ismethod(f): f = f.__func__ f = functools._unwrap_partial(f) - if not (isfunction(f) or _signature_is_functionlike(f)): - return False return getattr(f, "_is_coroutine_marker", None) is _is_coroutine_marker def markcoroutinefunction(func): |