summaryrefslogtreecommitdiff
path: root/mesonbuild/modules
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2024-06-09 01:03:49 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2024-06-14 17:19:53 +0300
commit9a6fcd4d9a0c7bb248c5d0587632b741a3301e03 (patch)
treef066ab0ee942d2f12579bb075cb3afbdf3386f0b /mesonbuild/modules
parentc0d86024f5e647858f88bc400b45b3ad88a25c97 (diff)
downloadmeson-9a6fcd4d9a0c7bb248c5d0587632b741a3301e03.tar.gz
Replace direct indexing with named methods.
Diffstat (limited to 'mesonbuild/modules')
-rw-r--r--mesonbuild/modules/gnome.py2
-rw-r--r--mesonbuild/modules/python.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
index f46e4f520..cab7c76a3 100644
--- a/mesonbuild/modules/gnome.py
+++ b/mesonbuild/modules/gnome.py
@@ -906,7 +906,7 @@ class GnomeModule(ExtensionModule):
if state.project_args.get(lang):
cflags += state.project_args[lang]
if mesonlib.OptionKey('b_sanitize') in compiler.base_options:
- sanitize = state.environment.coredata.optstore[mesonlib.OptionKey('b_sanitize')].value
+ sanitize = state.environment.coredata.optstore.get_value('b_sanitize')
cflags += compiler.sanitizer_compile_args(sanitize)
sanitize = sanitize.split(',')
# These must be first in ldflags
diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py
index 3f7affe5e..b599a5eca 100644
--- a/mesonbuild/modules/python.py
+++ b/mesonbuild/modules/python.py
@@ -205,7 +205,7 @@ class PythonInstallation(_ExternalProgramHolder['PythonExternalProgram']):
new_link_args = mesonlib.extract_as_list(kwargs, 'link_args')
- is_debug = self.interpreter.environment.coredata.optstore[OptionKey('debug')].value
+ is_debug = self.interpreter.environment.coredata.optstore.get_value('debug')
if is_debug:
new_link_args.append(python_windows_debug_link_exception)
else: