Document that add_languages() returns a boolean [skip ci] (#5600)

pull/5607/head
Xavier Claessens 5 years ago committed by GitHub
parent 0bf5c27b64
commit dd8f75ad93
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      docs/markdown/Reference-manual.md

@ -52,7 +52,7 @@ Like `add_global_arguments` but the arguments are passed to the linker.
### add_languages() ### add_languages()
``` meson ``` meson
add_languages(*langs*) bool add_languages(*langs*)
``` ```
Add support for new programming languages. Equivalent to having them Add support for new programming languages. Equivalent to having them
@ -64,6 +64,9 @@ project('foobar', 'c')
if compiling_for_osx if compiling_for_osx
add_languages('objc') add_languages('objc')
endif endif
if add_languages('cpp', required : false)
executable('cpp-app', 'main.cpp')
endif
``` ```
Takes one keyword argument, `required`. It defaults to `true`, which Takes one keyword argument, `required`. It defaults to `true`, which

Loading…
Cancel
Save