summaryrefslogtreecommitdiff
path: root/doc/syntax/assignment.rdoc
diff options
context:
space:
mode:
Diffstat (limited to 'doc/syntax/assignment.rdoc')
-rw-r--r--doc/syntax/assignment.rdoc4
1 files changed, 4 insertions, 0 deletions
diff --git a/doc/syntax/assignment.rdoc b/doc/syntax/assignment.rdoc
index 037c2032a8..e30cb35adf 100644
--- a/doc/syntax/assignment.rdoc
+++ b/doc/syntax/assignment.rdoc
@@ -403,6 +403,10 @@ assigning. This is similar to multiple assignment:
p a # prints [1, 2, 3]
+ b = *1
+
+ p b # prints [1]
+
You can splat anywhere in the right-hand side of the assignment:
a = 1, *[2, 3]