meson: drop 'name' argument in cc.has_argument() (#8823)

This fixes the following warning with clang and meson-0.46.0,
```
WARNING: Passed invalid keyword argument "name".
WARNING: This will become a hard error in the future.
WARNING: Passed invalid keyword argument "name".
WARNING: This will become a hard error in the future.
Compiler for C supports arguments -Wno-typedef-redefinition: YES
WARNING: Passed invalid keyword argument "name".
WARNING: This will become a hard error in the future.
WARNING: Passed invalid keyword argument "name".
WARNING: This will become a hard error in the future.
Compiler for C supports arguments -Wno-gnu-variable-sized-type-not-at-end: YES
```
This commit is contained in:
Yu Watanabe 2018-04-26 17:53:10 +09:00 committed by Zbigniew Jędrzejewski-Szmek
parent ad628501b9
commit 8ac42236b0
1 changed files with 1 additions and 2 deletions

View File

@ -374,8 +374,7 @@ if cc.get_id() == 'clang'
foreach arg : ['-Wno-typedef-redefinition',
'-Wno-gnu-variable-sized-type-not-at-end',
]
if cc.has_argument(arg,
name : '@0@ is supported'.format(arg))
if cc.has_argument(arg)
add_project_arguments(arg, language : 'c')
endif
endforeach