2015-08-13 03:26:22 +03:00
|
|
|
wutpat, `?@`, %wtpt
|
2015-02-18 06:03:21 +03:00
|
|
|
============================
|
|
|
|
|
|
|
|
If atom
|
|
|
|
|
|
|
|
`?@` is a synthetic rune that produces `q` if `p` is an atom, `r`
|
|
|
|
otherwise.
|
|
|
|
|
|
|
|
Produces
|
|
|
|
--------
|
|
|
|
|
|
|
|
Twig: `[%wtpt p=wing q=twig r=twig]`
|
|
|
|
|
|
|
|
Sample
|
|
|
|
------
|
|
|
|
|
|
|
|
`p` is a [`++wing`](). `q` and `r` are [twig]()s.
|
|
|
|
|
|
|
|
Tall form
|
|
|
|
---------
|
|
|
|
|
|
|
|
Kingside:
|
|
|
|
|
|
|
|
?@ p
|
|
|
|
q
|
|
|
|
r
|
|
|
|
|
|
|
|
Wide form
|
|
|
|
---------
|
|
|
|
|
|
|
|
?@(p q r)
|
|
|
|
|
|
|
|
Irregular form
|
|
|
|
--------------
|
|
|
|
|
|
|
|
None
|
|
|
|
|
|
|
|
Examples
|
|
|
|
--------
|
|
|
|
|
|
|
|
~zod/try=> ?@(~ 1 2)
|
|
|
|
! mint-vain
|
|
|
|
! exit
|
|
|
|
~zod/try=> ?@(%ha 1 2)
|
|
|
|
1
|
|
|
|
~zod/try=> ?@("" 1 2)
|
|
|
|
1
|
|
|
|
~zod/try=> ?@("a" 1 2)
|
|
|
|
2
|
|
|
|
~zod/try=> ?@([1 1] 1 2)
|
|
|
|
! mint-vain
|
|
|
|
! exit
|
|
|
|
~zod/try=> ?@(`*`[1 1] 1 2)
|
|
|
|
2
|
2015-11-30 06:01:07 +03:00
|
|
|
|
|
|
|
Equivalent to
|
|
|
|
-------------
|
|
|
|
|
|
|
|
?:(?=(@ p) q r)
|