mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-30 08:41:59 +07:00
24 lines
426 B
Python
24 lines
426 B
Python
from typing import final, overload
|
|
|
|
|
|
class A:
|
|
@overload
|
|
def foo(self, a: int) -> int: ...
|
|
|
|
@overload
|
|
def foo(self, a: str) -> str: ...
|
|
|
|
@final
|
|
def foo(self, a):
|
|
pass
|
|
|
|
@final
|
|
@overload
|
|
def <warning descr="'@final' should be placed on the implementation">bar</warning>(self, a: int) -> int: ...
|
|
|
|
@overload
|
|
def bar(self, a: str) -> str: ...
|
|
|
|
def bar(self, a):
|
|
pass
|