mirror of
https://github.com/systemd/systemd.git
synced 2026-08-09 17:38:42 +00:00
meson: use modern syntax for dict checks
This commit is contained in:
@@ -2354,7 +2354,7 @@ foreach dict : executables
|
||||
sources += exe_sources
|
||||
endif
|
||||
|
||||
if dict.has_key('export')
|
||||
if 'export' in dict
|
||||
exported_by_name += {
|
||||
name : {
|
||||
'exported' : exe.extract_objects(dict['export']),
|
||||
@@ -2718,7 +2718,7 @@ if meson.version().version_compare('>=1.4.0')
|
||||
uniq = {}
|
||||
|
||||
foreach source : sources
|
||||
if uniq.has_key(source.full_path())
|
||||
if source.full_path() in uniq
|
||||
continue
|
||||
endif
|
||||
uniq += {source.full_path(): source}
|
||||
|
||||
@@ -98,7 +98,7 @@ endif
|
||||
############################################################
|
||||
|
||||
test_compare_versions_sh = files('test-compare-versions.sh')
|
||||
if want_tests != 'false' and executables_by_name.has_key('systemd-analyze')
|
||||
if want_tests != 'false' and 'systemd-analyze' in executables_by_name
|
||||
exe = executables_by_name.get('systemd-analyze')
|
||||
test('test-compare-versions',
|
||||
test_compare_versions_sh,
|
||||
@@ -156,7 +156,7 @@ endif
|
||||
############################################################
|
||||
|
||||
test_fstab_generator_sh = files('test-fstab-generator.sh')
|
||||
if want_tests != 'false' and executables_by_name.has_key('systemd-fstab-generator')
|
||||
if want_tests != 'false' and 'systemd-fstab-generator' in executables_by_name
|
||||
exe = executables_by_name.get('systemd-fstab-generator')
|
||||
test('test-fstab-generator',
|
||||
test_fstab_generator_sh,
|
||||
|
||||
Reference in New Issue
Block a user