From ee682abac876cf558627e39415ebc92d2431c964 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Fri, 26 Dec 2025 14:13:14 +0100 Subject: [PATCH] mypy: no need to declare None as return type for __init__ --- scripts/generate-builtin-terminfo.py | 8 ++++---- scripts/generate-emoji-variation-sequences.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/generate-builtin-terminfo.py b/scripts/generate-builtin-terminfo.py index 515153a2..c10373d3 100755 --- a/scripts/generate-builtin-terminfo.py +++ b/scripts/generate-builtin-terminfo.py @@ -6,7 +6,7 @@ import re class Capability: - def __init__(self, name: str, value: bool | int | str) -> None: + def __init__(self, name: str, value: bool | int | str): self._name = name self._value = value @@ -50,7 +50,7 @@ class Capability: class BoolCapability(Capability): - def __init__(self, name: str) -> None: + def __init__(self, name: str): super().__init__(name, True) @@ -59,7 +59,7 @@ class IntCapability(Capability): class StringCapability(Capability): - def __init__(self, name: str, value: str) -> None: + def __init__(self, name: str, value: str): # see terminfo(5) for valid escape sequences # Control characters @@ -92,7 +92,7 @@ class StringCapability(Capability): class Fragment: - def __init__(self, name: str, description: str) -> None: + def __init__(self, name: str, description: str): self._name = name self._description = description self._caps = dict[str, Capability]() diff --git a/scripts/generate-emoji-variation-sequences.py b/scripts/generate-emoji-variation-sequences.py index 17172d20..57e881c7 100644 --- a/scripts/generate-emoji-variation-sequences.py +++ b/scripts/generate-emoji-variation-sequences.py @@ -4,7 +4,7 @@ import argparse class Codepoint: - def __init__(self, start: int, end: None | int = None) -> None: + def __init__(self, start: int, end: None | int = None): self.start = start self.end = start if end is None else end self.vs15 = False