From 2a76afcef1fbd5cac0435cc9a11f765120a48fe9 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Mon, 5 Sep 2022 17:33:59 -0400 Subject: [PATCH] compilers: drop some useless info from CompileResult text_mode was never set, nor used, and pid was set but never used. --- mesonbuild/compilers/compilers.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py index ef3511045..d2ac7c622 100644 --- a/mesonbuild/compilers/compilers.py +++ b/mesonbuild/compilers/compilers.py @@ -454,8 +454,7 @@ class CompileResult(HoldableObject): def __init__(self, stdo: T.Optional[str] = None, stde: T.Optional[str] = None, command: T.Optional[T.List[str]] = None, - returncode: int = 999, pid: int = -1, - text_mode: bool = True, + returncode: int = 999, input_name: T.Optional[str] = None, output_name: T.Optional[str] = None, cached: bool = False): @@ -466,8 +465,6 @@ class CompileResult(HoldableObject): self.command = command or [] self.cached = cached self.returncode = returncode - self.pid = pid - self.text_mode = text_mode class Compiler(HoldableObject, metaclass=abc.ABCMeta): @@ -811,7 +808,7 @@ class Compiler(HoldableObject, metaclass=abc.ABCMeta): mlog.debug('Compiler stdout:\n', stdo) mlog.debug('Compiler stderr:\n', stde) - result = CompileResult(stdo, stde, command_list, p.returncode, p.pid, input_name=srcname) + result = CompileResult(stdo, stde, command_list, p.returncode, input_name=srcname) if want_output: result.output_name = output yield result