blob: a4621d5324c9cacb7128e4f6f5bb0365b353681f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
"""Since Python version 3.8, a class decorated with typing.final cannot be
subclassed."""
# pylint: disable=missing-docstring, too-few-public-methods
# Disabled because of a bug with pypy 3.8 see
# https://github.com/PyCQA/pylint/pull/7918#issuecomment-1352737369
# pylint: disable=multiple-statements
from typing import final
@final
class Base:
pass
class Subclass(Base): # [subclassed-final-class]
pass
|