aboutsummaryrefslogtreecommitdiff
path: root/docs/markdown
diff options
context:
space:
mode:
authorXavier Claessens <xavier.claessens@collabora.com>2018-07-18 09:57:34 -0400
committerJussi Pakkanen <jpakkane@gmail.com>2018-08-14 23:46:42 +0300
commit4f088365e49d28e0d413d42eb024c3ff6cbfee35 (patch)
tree819356912328d5ffd278fbad2f63bc29b2d12e11 /docs/markdown
parent219dec39c09789f2b296e5af00305fe05fa3362b (diff)
downloadmeson-4f088365e49d28e0d413d42eb024c3ff6cbfee35.zip
meson-4f088365e49d28e0d413d42eb024c3ff6cbfee35.tar.gz
meson-4f088365e49d28e0d413d42eb024c3ff6cbfee35.tar.bz2
interpreter: Add support for dict addition
Diffstat (limited to 'docs/markdown')
-rw-r--r--docs/markdown/Reference-manual.md3
-rw-r--r--docs/markdown/snippets/dict_add.md10
2 files changed, 13 insertions, 0 deletions
diff --git a/docs/markdown/Reference-manual.md b/docs/markdown/Reference-manual.md
index a7b8a2b..3ae740d 100644
--- a/docs/markdown/Reference-manual.md
+++ b/docs/markdown/Reference-manual.md
@@ -1859,6 +1859,9 @@ statement](Syntax.md#foreach-statements).
Dictionaries are available since 0.47.0.
+Since 0.48.0 dictionaries can be added (e.g. `d1 = d2 + d3` and `d1 += d2`).
+Values from the second dictionary overrides values from the first.
+
## Returned objects
These are objects returned by the [functions listed above](#functions).
diff --git a/docs/markdown/snippets/dict_add.md b/docs/markdown/snippets/dict_add.md
new file mode 100644
index 0000000..cde5b57
--- /dev/null
+++ b/docs/markdown/snippets/dict_add.md
@@ -0,0 +1,10 @@
+## Dictionary addition
+
+Dictionaries can now be added, values from the second dictionary overrides values
+from the first
+
+```meson
+d1 = {'a' : 'b'}
+d3 = d1 + {'a' : 'c'}
+d3 += {'d' : 'e'}
+```