hoon: improve $pith pattern mode syntax

Produce the correct type, support the ~ element, allow specifying an
open-ended type.
This commit is contained in:
fang 2022-07-06 16:33:28 +02:00
parent 5af620176e
commit 01a6b8a16a
No known key found for this signature in database
GPG Key ID: EB035760C1BBA972

View File

@ -13132,15 +13132,23 @@
;~ pose
:: /name=@aura
::
%+ stag %bcts
;~ plug sym
;~ pfix tis pat
(stag %base (stag %atom mota))
== ==
%+ cook
|= [=term =aura]
^- spec
:+ %bccl
[%leaf %tas aura]
[%bcts term [%base %atom aura]]~
;~(plug sym ;~(pfix tis pat mota))
::
:: /constant
::
(stag %leaf (stag %tas sym))
(stag %leaf (stag %tas ;~(pose sym (cold %$ buc))))
==
::
:: /~
::
:- '~'
(cold [%bccl [%leaf %tas %n] [%base %null] ~] sig)
==
::
;~ pose