diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2021-03-09 15:00:41 -0800 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2021-03-14 22:05:55 -0700 |
commit | 2be074b1d445fcd30535bcf7518f8ce0738bcbf3 (patch) | |
tree | 8f93fabd6ecc2cd2812b8fb2d7fa356a1385f578 /mesonbuild/compilers/d.py | |
parent | 320412b3bbe97d8779d715f992f7a88d3a461ace (diff) | |
download | meson-2be074b1d445fcd30535bcf7518f8ce0738bcbf3.zip meson-2be074b1d445fcd30535bcf7518f8ce0738bcbf3.tar.gz meson-2be074b1d445fcd30535bcf7518f8ce0738bcbf3.tar.bz2 |
ninjabackend: Use rsp_file_syntax method
This also makes us of the new enum value in the backend, for better type
saftey.
Diffstat (limited to 'mesonbuild/compilers/d.py')
-rw-r--r-- | mesonbuild/compilers/d.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mesonbuild/compilers/d.py b/mesonbuild/compilers/d.py index d032809..bda1026 100644 --- a/mesonbuild/compilers/d.py +++ b/mesonbuild/compilers/d.py @@ -22,6 +22,7 @@ from ..mesonlib import ( ) from ..arglist import CompilerArgs +from ..linkers import RSPFileSyntax from .compilers import ( d_dmd_buildtype_args, d_gdc_buildtype_args, @@ -36,7 +37,7 @@ if T.TYPE_CHECKING: from ..dependencies import Dependency, ExternalProgram from ..envconfig import MachineInfo from ..environment import Environment - from ..linkers import DynamicLinker, RSPFileSyntax + from ..linkers import DynamicLinker else: CompilerMixinBase = object @@ -780,7 +781,7 @@ class LLVMDCompiler(DmdLikeCompilerMixin, DCompiler): def get_disable_assert_args(self) -> T.List[str]: return ['--release'] - def rsp_file_syntax(self) -> 'RSPFileSyntax': + def rsp_file_syntax(self) -> RSPFileSyntax: # We use `mesonlib.is_windows` here because we want to konw what the # build machine is, not the host machine. This really means whe whould # have the Environment not the MachineInfo in the compiler. @@ -867,5 +868,5 @@ class DmdDCompiler(DmdLikeCompilerMixin, DCompiler): def get_disable_assert_args(self) -> T.List[str]: return ['-release'] - def rsp_file_syntax(self) -> 'RSPFileSyntax': + def rsp_file_syntax(self) -> RSPFileSyntax: return RSPFileSyntax.MSVC |