Files
openide/python/testData/deprecation/abcDeprecatedAbstracts.py
Andrey Vokin 0f8e5afa8a PY-73263 Python 3.13 Support - Code Insight - Typeshed
Remove custom deprecation check for abc. Typesheds now have deprecation decorator

GitOrigin-RevId: 72ba0028bfda2d7eda4a8e01aed5962613305531
2024-09-09 13:54:00 +00:00

44 lines
1.1 KiB
Python

import abc
class A(metaclass=abc.ABCMeta):
@abc.<warning descr="Use 'property' with 'abstractmethod' instead">abstractproperty</warning>
def prop(self):
pass
from abc import <warning descr="Use 'property' with 'abstractmethod' instead">abstractproperty</warning>
class B(metaclass=abc.ABCMeta):
@<warning descr="Use 'property' with 'abstractmethod' instead">abstractproperty</warning>
def prop(self):
pass
from abc import <warning descr="Use 'property' with 'abstractmethod' instead">abstractproperty</warning> as ap
class C(metaclass=abc.ABCMeta):
@<warning descr="Use 'property' with 'abstractmethod' instead">ap</warning>
def prop(self):
pass
import abc as foo
class D(metaclass=abc.ABCMeta):
@foo.<warning descr="Use 'property' with 'abstractmethod' instead">abstractproperty</warning>
def prop(self):
pass
class A:
@abc.<warning descr="Use 'classmethod' with 'abstractmethod' instead">abstractclassmethod</warning>
def foo(cls):
pass
@abc.<warning descr="Use 'staticmethod' with 'abstractmethod' instead">abstractstaticmethod</warning>
def bar():
pass