aboutsummaryrefslogtreecommitdiff
path: root/lessons/src/lesson029_pattern_aliases/text.html
blob: 5aa8a81c9e2895a10953ff14647fa713f7914248 (plain)
1
2
3
4
5
6
7
<p>
  The <code>as</code> operator can be used to assign sub patterns to variables.
</p>
<p>
  For example, the pattern <code>[_, ..] as it</code> will match any non-empty
  list and assign that list to the variable <code>it</code>.
</p>