From 921c2370a722cbaa42bd256c699fae3185084939 Mon Sep 17 00:00:00 2001 From: Tristan Partin Date: Wed, 12 Jul 2023 17:36:25 -0500 Subject: Replace some type comments with annotations --- mesonbuild/compilers/mixins/intel.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'mesonbuild/compilers/mixins/intel.py') diff --git a/mesonbuild/compilers/mixins/intel.py b/mesonbuild/compilers/mixins/intel.py index b793fa8..711e77c 100644 --- a/mesonbuild/compilers/mixins/intel.py +++ b/mesonbuild/compilers/mixins/intel.py @@ -50,14 +50,14 @@ class IntelGnuLikeCompiler(GnuLikeCompiler): minsize: -O2 """ - BUILD_ARGS = { + BUILD_ARGS: T.Dict[str, T.List[str]] = { 'plain': [], 'debug': ["-g", "-traceback"], 'debugoptimized': ["-g", "-traceback"], 'release': [], 'minsize': [], 'custom': [], - } # type: T.Dict[str, T.List[str]] + } OPTIM_ARGS: T.Dict[str, T.List[str]] = { 'plain': [], @@ -129,14 +129,14 @@ class IntelVisualStudioLikeCompiler(VisualStudioLikeCompiler): """Abstractions for ICL, the Intel compiler on Windows.""" - BUILD_ARGS = { + BUILD_ARGS: T.Dict[str, T.List[str]] = { 'plain': [], 'debug': ["/Zi", "/traceback"], 'debugoptimized': ["/Zi", "/traceback"], 'release': [], 'minsize': [], 'custom': [], - } # type: T.Dict[str, T.List[str]] + } OPTIM_ARGS: T.Dict[str, T.List[str]] = { 'plain': [], -- cgit v1.1 From 33c8362a1cdd57dd60c7be8fdf3b0566ccdeb3bf Mon Sep 17 00:00:00 2001 From: Tristan Partin Date: Wed, 12 Jul 2023 17:56:18 -0500 Subject: Match the method signatures of parent classes Names and types of some methods did not match their parent methods. --- mesonbuild/compilers/mixins/intel.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mesonbuild/compilers/mixins/intel.py') diff --git a/mesonbuild/compilers/mixins/intel.py b/mesonbuild/compilers/mixins/intel.py index 711e77c..9af05e0 100644 --- a/mesonbuild/compilers/mixins/intel.py +++ b/mesonbuild/compilers/mixins/intel.py @@ -89,8 +89,8 @@ class IntelGnuLikeCompiler(GnuLikeCompiler): return ['-pch', '-pch_dir', os.path.join(pch_dir), '-x', self.lang_header, '-include', header, '-x', 'none'] - def get_pch_name(self, header_name: str) -> str: - return os.path.basename(header_name) + '.' + self.get_pch_suffix() + def get_pch_name(self, name: str) -> str: + return os.path.basename(name) + '.' + self.get_pch_suffix() def openmp_flags(self) -> T.List[str]: if mesonlib.version_compare(self.version, '>=15.0.0'): -- cgit v1.1