aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/markdown/Syntax.md10
-rw-r--r--docs/markdown/snippets/fstrings.md2
2 files changed, 10 insertions, 2 deletions
diff --git a/docs/markdown/Syntax.md b/docs/markdown/Syntax.md
index 50287b2..9ed3227 100644
--- a/docs/markdown/Syntax.md
+++ b/docs/markdown/Syntax.md
@@ -198,7 +198,15 @@ s = f'int: @n@, string: @m@'
```
Currently only identity-expressions are supported inside of format
-strings.
+strings, meaning you cannot use arbitrary Meson expressions inside of them.
+
+```meson
+n = 10
+m = 5
+
+# The following is not a valid format string
+s = f'result: @n + m@'
+```
### String methods
diff --git a/docs/markdown/snippets/fstrings.md b/docs/markdown/snippets/fstrings.md
index df7dc2c..45a238c 100644
--- a/docs/markdown/snippets/fstrings.md
+++ b/docs/markdown/snippets/fstrings.md
@@ -1,7 +1,7 @@
## Introducing format strings to the Meson language
In addition to the conventional `'A string @0@ to be formatted @1@'.format(n, m)`
-method of formatting strings in the Meson DSL, there's now the additional
+method of formatting strings in the Meson language, there's now the additional
`f'A string @n@ to be formatted @m@'` notation that provides a non-positional
and clearer alternative. Meson's format strings are currently restricted to
identity-expressions, meaning `f'format @'m' + 'e'@'` will not parse.