From c9ad98ef5ef8dd1931735f07015bf8ad199cd456 Mon Sep 17 00:00:00 2001 From: Laurin-Luis Lehning <65224843+e820@users.noreply.github.com> Date: Thu, 17 Jun 2021 21:02:51 +0200 Subject: interprter: Add required kwarg to add_(project|global)_arguments To avoid manual compiler support checks add_project_arguments and add_global_arguments receive a new keyword argument to perform them automatically. --- docs/markdown/snippets/required_project_arguments.md | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 docs/markdown/snippets/required_project_arguments.md (limited to 'docs/markdown') diff --git a/docs/markdown/snippets/required_project_arguments.md b/docs/markdown/snippets/required_project_arguments.md new file mode 100644 index 0000000..e5dae70 --- /dev/null +++ b/docs/markdown/snippets/required_project_arguments.md @@ -0,0 +1,8 @@ +# Required project & global arguments + +The `add_global_arguments` & `add_project_arguments` functions now +support an optional keyword argument named `required`. Setting it +to `true` will cause Meson to perform compiler support checks on +each of the passed arguments as if by calling `has_argument`, which +means manual checks can now be avoided and instead expressed more +tersely. -- cgit v1.1