From a27d18f2265c74804842c1170396dbc273c9e1c9 Mon Sep 17 00:00:00 2001 From: Paul Cristian Sarbu Date: Tue, 27 Jun 2023 15:49:03 +0200 Subject: python: Add type hints and fix style in rules scripts For maximum compatibility, we use the uppercase types from the typing package instead of the built-in types, therefore compliant with PEP 484 and PEP 526. --- CC/prebuilt/read_pkgconfig.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CC/prebuilt/read_pkgconfig.py b/CC/prebuilt/read_pkgconfig.py index 7530e6c..115c305 100755 --- a/CC/prebuilt/read_pkgconfig.py +++ b/CC/prebuilt/read_pkgconfig.py @@ -54,7 +54,7 @@ def read_ldflags(pkg: str, args: List[str], env: Dict[str, str]) -> str: return " ".join([f for f in link_flags if not is_local(f)]) -def read_pkgconfig(): +def read_pkgconfig() -> None: if len(sys.argv) < 3: print(f"usage: read_pkgconfig OUT_NAME PC_FILE [PC_ARGS...]") exit(1) -- cgit v1.2.3