Skip to content

Commit

Permalink
extended args@ explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
qknight committed Jul 6, 2015
1 parent dd48c06 commit 4ef8e3e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions doc/manual/expressions/language-constructs.xml
Expand Up @@ -182,8 +182,11 @@ args@{ x, y, z, ... }: z + y + x + args.a</programlisting>

Here <varname>args</varname> is bound to the entire argument, which
is further matched against the pattern <literal>{ x, y, z,
... }</literal>.</para></listitem>

... }</literal>. This <literal>@</literal>-pattern makes only sense with an
ellipsis(<literal>...</literal>) as you can now access attribute names as
<literal>a</literal>, using <literal>args.a</literal>, which was given as an
additional attribute to the function.
</para></listitem>

</itemizedlist>

Expand Down

0 comments on commit 4ef8e3e

Please sign in to comment.