From 9cb9ad88da3e837086753af03813b1f173a6d831 Mon Sep 17 00:00:00 2001 From: Andrew McNulty Date: Tue, 17 Sep 2024 00:28:34 +0100 Subject: [PATCH] compilers: Pass mode to determine_args, not its string value We always pass the string value of the mode to determine_args, which causes the check on the mode argument inside determine_args to always evaluate to false. Fix this by passing the mode itself, not its value. --- mesonbuild/compilers/mixins/clike.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mesonbuild/compilers/mixins/clike.py b/mesonbuild/compilers/mixins/clike.py index e982ca023..f0515a9bd 100644 --- a/mesonbuild/compilers/mixins/clike.py +++ b/mesonbuild/compilers/mixins/clike.py @@ -417,7 +417,7 @@ class CLikeCompiler(Compiler): else: # TODO: we want to do this in the caller extra_args = mesonlib.listify(extra_args) - extra_args = mesonlib.listify([e(mode.value) if callable(e) else e for e in extra_args]) + extra_args = mesonlib.listify([e(mode) if callable(e) else e for e in extra_args]) if dependencies is None: dependencies = []