mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PY-84107 Fix Type Parameters mistakenly reported as unused in PyUnusedLocalInspection
(cherry picked from commit 0593c2290aa1c84dde96673297374efef2b27fc3) GitOrigin-RevId: 56de9b7a6b305eb9e88dc2bf8281c93f788eae80
This commit is contained in:
committed by
intellij-monorepo-bot
parent
fcf1abdbb7
commit
7d46075b5f
+13
@@ -0,0 +1,13 @@
|
||||
from typing import Callable
|
||||
|
||||
def wait_for_condition[T](fn: Callable[..., T]) -> T:
|
||||
return fn()
|
||||
|
||||
def foo[T, U](fn: Callable[..., T]) -> U:
|
||||
return fn()
|
||||
|
||||
def bar[T, <weak_warning descr="Type parameter 'U' is not used">U</weak_warning>](fn: Callable[..., T]) -> T:
|
||||
return fn()
|
||||
|
||||
def baz[<weak_warning descr="Type parameter 'T' is not used">T</weak_warning>, <weak_warning descr="Type parameter 'U' is not used">U</weak_warning>](fn: Callable[..., int]) -> str:
|
||||
return fn()
|
||||
Reference in New Issue
Block a user