diff options
| author | Dylan Baker <dylan@pnwbakers.com> | 2025-11-13 11:34:44 -0800 |
|---|---|---|
| committer | Dylan Baker <dylan@pnwbakers.com> | 2025-11-19 10:48:48 -0800 |
| commit | 68b959c2c7a2cfb88ebf2205f25bf77abe318cb9 (patch) | |
| tree | dc0758cbcd98778d27ae6d91960deaa16b43107d /mesonbuild | |
| parent | a76dae2d9b22d53e72343e9ea86cd79c9fa39310 (diff) | |
| download | meson-68b959c2c7a2cfb88ebf2205f25bf77abe318cb9.tar.gz | |
compilers: Remove Environment parameter from RustCompiler.get_rustdoc
Diffstat (limited to 'mesonbuild')
| -rw-r--r-- | mesonbuild/backend/ninjabackend.py | 2 | ||||
| -rw-r--r-- | mesonbuild/compilers/rust.py | 2 | ||||
| -rw-r--r-- | mesonbuild/modules/rust.py | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py index 62897b101..f7e17bde6 100644 --- a/mesonbuild/backend/ninjabackend.py +++ b/mesonbuild/backend/ninjabackend.py @@ -2224,7 +2224,7 @@ class NinjaBackend(backends.Backend): if target.doctests: assert target.doctests.target is not None - rustdoc = rustc.get_rustdoc(self.environment) + rustdoc = rustc.get_rustdoc() args = rustdoc.get_exe_args() args += self.get_rust_compiler_args(target.doctests.target, rustdoc, target.rust_crate_type) o, _ = self.flatten_object_list(target.doctests.target) diff --git a/mesonbuild/compilers/rust.py b/mesonbuild/compilers/rust.py index 0a1aea93e..b214a218d 100644 --- a/mesonbuild/compilers/rust.py +++ b/mesonbuild/compilers/rust.py @@ -456,7 +456,7 @@ class RustCompiler(Compiler): return self.compiles('fn main() { std::process::exit(0) }\n', extra_args=args, mode=CompileCheckMode.LINK) @functools.lru_cache(maxsize=None) - def get_rustdoc(self, env: 'Environment') -> T.Optional[RustdocTestCompiler]: + def get_rustdoc(self) -> T.Optional[RustdocTestCompiler]: exelist = self.get_rust_tool('rustdoc') if not exelist: return None diff --git a/mesonbuild/modules/rust.py b/mesonbuild/modules/rust.py index a22c4317e..a8fcc86a0 100644 --- a/mesonbuild/modules/rust.py +++ b/mesonbuild/modules/rust.py @@ -272,7 +272,7 @@ class RustModule(ExtensionModule): if self.rustdoc[base_target.for_machine] is None: rustc = T.cast('RustCompiler', base_target.compilers['rust']) - rustdoc = rustc.get_rustdoc(state.environment) + rustdoc = rustc.get_rustdoc() if rustdoc: self.rustdoc[base_target.for_machine] = ExternalProgram(rustdoc.get_exe()) else: |
