@@ -4611,6 +4611,7 @@
4611 [%tag id=@ud literal=lit constructor=?]
4611 [%tag id=@ud literal=lit constructor=?]
4612 [%const literal=lit]
4612 [%const literal=lit]
4613 [%collection name=term args=(list itype)]
4613 [%collection name=term args=(list itype)]
4614+ [%recursive module=term name=term label=(unit @t)]
4614 [%union cases=(list itype) origin=(unit [at=path name=term]) label=(unit @t) args=(list itype)]
4615 [%union cases=(list itype) origin=(unit [at=path name=term]) label=(unit @t) args=(list itype)]
4615 [%face name=term body=itype]
4616 [%face name=term body=itype]
4616 [%fn sample=itype product=itype]
4617 [%fn sample=itype product=itype]
@@ -4663,6 +4664,7 @@
4663 %tag =(n id.t)
4664 %tag =(n id.t)
4664 %const |
4665 %const |
4665 %union |((lien cases.t |=(c=itype (itype-occurs n c sub))) (lien args.t |=(c=itype (itype-occurs n c sub))))
4666 %union |((lien cases.t |=(c=itype (itype-occurs n c sub))) (lien args.t |=(c=itype (itype-occurs n c sub))))
4666 %collection (lien args.t |=(c=itype (itype-occurs n c sub)))
4668 %collection (lien args.t |=(c=itype (itype-occurs n c sub)))
4667 %face $(t body.t)
4669 %face $(t body.t)
4668 %fn |($(t sample.t) $(t product.t))
4670 %fn |($(t sample.t) $(t product.t))
@@ -4681,6 +4683,8 @@
4681 =. a (itype-walk a sub)
4683 =. a (itype-walk a sub)
4682 =. b (itype-walk b sub)
4684 =. b (itype-walk b sub)
4683 ?: =(a b) `sub
4685 ?: =(a b) `sub
4686+ ?: &(?=(%recursive -.a) ?=(%recursive -.b))
4687+ ?:(&(=(module.a module.b) =(name.a name.b)) `sub ~)
4684 ?: &(?=(%union -.a) ?=(%union -.b))
4688 ?: &(?=(%union -.a) ?=(%union -.b))
4685 ?. =(origin.a origin.b) ~
4689 ?. =(origin.a origin.b) ~
4686 ?: &(?=(~ args.a) ?=(~ args.b)) ?:(=(cases.a cases.b) `sub ~)
4690 ?: &(?=(~ args.a) ?=(~ args.b)) ?:(=(cases.a cases.b) `sub ~)
@@ -4756,6 +4760,7 @@
4757 %const |
4761 %const |
4758 %union |((lien cases.t |=(c=itype (itype-has-any-atom c sub))) (lien args.t |=(c=itype (itype-has-any-atom c sub))))
4762 %union |((lien cases.t |=(c=itype (itype-has-any-atom c sub))) (lien args.t |=(c=itype (itype-has-any-atom c sub))))
4759 %collection (lien args.t |=(c=itype (itype-has-any-atom c sub)))
4764 %collection (lien args.t |=(c=itype (itype-has-any-atom c sub)))
4760 %face $(t body.t)
4765 %face $(t body.t)
4761 %fn |($(t sample.t) $(t product.t))
4766 %fn |($(t sample.t) $(t product.t))
@@ -4825,6 +4830,7 @@
4826 %const &
4831 %const &
4827 %union |((lien cases.typ |=(c=itype (itype-has-fixed-atom c))) (lien args.typ |=(c=itype (itype-has-fixed-atom c))))
4832 %union |((lien cases.typ |=(c=itype (itype-has-fixed-atom c))) (lien args.typ |=(c=itype (itype-has-fixed-atom c))))
4828 %collection (lien args.typ |=(c=itype (itype-has-fixed-atom c)))
4834 %collection (lien args.typ |=(c=itype (itype-has-fixed-atom c)))
4829 %face $(typ body.typ)
4835 %face $(typ body.typ)
4830 %fn |($(typ sample.typ) $(typ product.typ))
4836 %fn |($(typ sample.typ) $(typ product.typ))
@@ -4909,6 +4915,7 @@
4911 %union &
4917 %union &
4912 %collection &
4919 %collection &
4913 %face $(t body.t)
4920 %face $(t body.t)
4914 %fn |($(t sample.t) $(t product.t))
4921 %fn |($(t sample.t) $(t product.t))
@@ -4975,6 +4982,32 @@
4985+++ itype-has-recursive
4990+ %collection (lien args.t |=(c=itype (itype-has-recursive c)))
4991+ %union (lien (weld args.t cases.t) |=(c=itype (itype-has-recursive c)))
4993+ %cell |($(t hed.t) $(t tal.t))
4994+ %fn |($(t sample.t) $(t product.t))
4998+++ itype-has-hidden-recursive
5002+ %recursive ?=(~ label.t)
5003+ %collection (lien args.t |=(c=itype (itype-has-hidden-recursive c)))
5004+ %union (lien (weld args.t cases.t) |=(c=itype (itype-has-hidden-recursive c)))
5006+ %cell |($(t hed.t) $(t tal.t))
5007+ %fn |($(t sample.t) $(t product.t))
4978++ itype-fit-cases
5011++ itype-fit-cases
4979 |= [actual=itype cases=(list itype) sub=isub next=@ud]
5012 |= [actual=itype cases=(list itype) sub=isub next=@ud]
@@ -5022,6 +5055,9 @@
5022 =. actual (itype-walk actual sub)
5055 =. actual (itype-walk actual sub)
5023 =. expected (itype-walk expected sub)
5056 =. expected (itype-walk expected sub)
5024 ?: =(actual expected) [%ok sub next]
5057 ?: =(actual expected) [%ok sub next]
5058+ ?: &(?=(%recursive -.actual) ?=(%recursive -.expected))
5059+ ?:(&(=(module.actual module.expected) =(name.actual name.expected)) [%ok sub next] [%bad ~])
5060+ ?: &(|(?=(%recursive -.actual) ?=(%recursive -.expected)) !|(?=(%var -.actual) ?=(%var -.expected))) [%unknown ~]
5025 ?: &(?=(%union -.actual) ?=(%union -.expected))
5061 ?: &(?=(%union -.actual) ?=(%union -.expected))
5026 ?. =(origin.actual origin.expected) [%unknown ~]
5062 ?. =(origin.actual origin.expected) [%unknown ~]
5027 ?: &(?=(~ args.actual) ?=(~ args.expected))
5063 ?: &(?=(~ args.actual) ?=(~ args.expected))
@@ -5112,6 +5148,7 @@
5112 =/ unified=(unit isub) (itype-unify actual expected sub)
5148 =/ unified=(unit isub) (itype-unify actual expected sub)
5113 ?~ unified
5149 ?~ unified
5114 ?: |(?=(%face -.actual) ?=(%face -.expected)) [%unknown ~]
5150 ?: |(?=(%face -.actual) ?=(%face -.expected)) [%unknown ~]
5151+ ?: |((itype-has-recursive (itype-normalize actual sub)) (itype-has-recursive (itype-normalize expected sub))) [%unknown ~]
5115 ?: (itype-family-related actual expected sub) [%unknown ~]
5152 ?: (itype-family-related actual expected sub) [%unknown ~]
5116 [%bad ~]
5153 [%bad ~]
5117 [%ok u.unified next]
5154 [%ok u.unified next]
@@ -5126,6 +5163,7 @@
5126 =/ unified=(unit isub) (itype-unify actual expected sub)
5163 =/ unified=(unit isub) (itype-unify actual expected sub)
5127 ?~ unified
5164 ?~ unified
5128 ?: |((itype-has-union (itype-normalize actual sub)) (itype-has-union (itype-normalize expected sub))) [%unknown ~]
5165 ?: |((itype-has-union (itype-normalize actual sub)) (itype-has-union (itype-normalize expected sub))) [%unknown ~]
5166+ ?: |((itype-has-recursive (itype-normalize actual sub)) (itype-has-recursive (itype-normalize expected sub))) [%unknown ~]
5129 ?: (itype-family-related actual expected sub) [%unknown ~]
5167 ?: (itype-family-related actual expected sub) [%unknown ~]
5130 [%bad ~]
5168 [%bad ~]
5131 [%ok u.unified next]
5169 [%ok u.unified next]
@@ -5171,6 +5209,20 @@
5171 ["collection arguments should preserve aura-family uncertainty" problems]
5209 ["collection arguments should preserve aura-family uncertainty" problems]
5172 =? problems !(itype-face-asym [%collection %list ~[[%face %x txt]]] list-t ~)
5210 =? problems !(itype-face-asym [%collection %list ~[[%face %x txt]]] list-t ~)
5173 ["collection arguments should preserve face uncertainty" problems]
5211 ["collection arguments should preserve face uncertainty" problems]
5212+ =/ recursive=itype [%recursive %fixture %chain `'chain.fixture']
5213+ =/ same-recursive=itype [%recursive %fixture %chain ~]
5214+ =/ other-recursive=itype [%recursive %other %chain `'chain.other']
5215+ =? problems ?=(~ (itype-unify recursive same-recursive ~))
5216+ ["recursive identity should not depend on its visible name" problems]
5217+ =? problems ?=(^ (itype-unify recursive other-recursive ~))
5218+ ["recursive identity should include the source module" problems]
5219+ =/ recursive-fit=ifit (itype-fit recursive txt ~ 0)
5220+ =? problems !?=(%unknown -.recursive-fit)
5221+ ["opaque recursive types should not be unfolded by a fit" problems]
5223+ (itype-fit [%collection %list ~[a]] list-t ~[[0 recursive]] 1)
5224+ =? problems !?=(%unknown -.nested-fit)
5225+ ["recursive types behind substitutions should remain uncertain" problems]
5174 problems
5226 problems
5176:: The expression inference below is deliberately a fragment: bindings,
5228:: The expression inference below is deliberately a fragment: bindings,
@@ -5231,6 +5283,7 @@
5233 %cell |($(t hed.t) $(t tal.t))
5285 %cell |($(t hed.t) $(t tal.t))
5234 %collection (lien args.t |=(c=itype (itype-has-gate c)))
5287 %collection (lien args.t |=(c=itype (itype-has-gate c)))
5235 %face $(t body.t)
5288 %face $(t body.t)
5236 %union (lien cases.t |=(c=itype (itype-has-gate c)))
5289 %union (lien cases.t |=(c=itype (itype-has-gate c)))
@@ -5269,6 +5322,7 @@
5270 %const ~
5323 %const ~
5271 %union (zing (turn (weld args.t cases.t) |=(c=itype (itype-vars c))))
5324 %union (zing (turn (weld args.t cases.t) |=(c=itype (itype-vars c))))
5272 %collection (zing (turn args.t |=(c=itype (itype-vars c))))
5326 %collection (zing (turn args.t |=(c=itype (itype-vars c))))
5273 %face $(t body.t)
5327 %face $(t body.t)
5274 %fn (weld $(t sample.t) $(t product.t))
5328 %fn (weld $(t sample.t) $(t product.t))
@@ -5306,6 +5360,7 @@
5307 %const t
5361 %const t
5308 %union [%union (turn cases.t |=(c=itype (itype-rename c ren))) origin.t label.t (turn args.t |=(c=itype (itype-rename c ren)))]
5362 %union [%union (turn cases.t |=(c=itype (itype-rename c ren))) origin.t label.t (turn args.t |=(c=itype (itype-rename c ren)))]
5309 %collection [%collection name.t (turn args.t |=(c=itype (itype-rename c ren)))]
5364 %collection [%collection name.t (turn args.t |=(c=itype (itype-rename c ren)))]
5310 %face [%face name.t $(t body.t)]
5365 %face [%face name.t $(t body.t)]
5311 %fn [%fn $(t sample.t) $(t product.t)]
5366 %fn [%fn $(t sample.t) $(t product.t)]
@@ -5328,6 +5383,7 @@
5329 %const |
5384 %const |
5330 %union |((lien cases.t |=(c=itype (itype-var-is-atom n c))) (lien args.t |=(c=itype (itype-var-is-atom n c))))
5385 %union |((lien cases.t |=(c=itype (itype-var-is-atom n c))) (lien args.t |=(c=itype (itype-var-is-atom n c))))
5331 %collection (lien args.t |=(c=itype (itype-var-is-atom n c)))
5387 %collection (lien args.t |=(c=itype (itype-var-is-atom n c)))
5332 %face $(t body.t)
5388 %face $(t body.t)
5333 %fn |($(t sample.t) $(t product.t))
5389 %fn |($(t sample.t) $(t product.t))
@@ -5405,6 +5461,69 @@
5405 ?. (is-lower i.chars) |
5461 ?. (is-lower i.chars) |
5406 (levy t.chars |=(c=@tD (in c name-mask)))
5462 (levy t.chars |=(c=@tD (in c name-mask)))
5464+:: A source-aware reader result is trusted for origin. Validate every
5465+:: supplied branch and keep the recursive mold opaque: unfolding its
5466+:: root while naming only its tail would change its type identity.
5467++$ irec-pattern [pat=upat has=?]
5469+ |= [node=* module=term name=term]
5470+ ^- (unit irec-pattern)
5474+ ?: ?=([%atom %n [~ @]] node)
5477+ ?: ?=([%atom %tas [~ @]] node)
5478+ =/ value=@ +>+.node
5479+ ?. |(=(value 0) (jibb-face-name value)) ~
5480+ `[[%atom `value] |]
5481+ ?. ?=([%atom @ ~] node) ~
5482+ =/ aura=@ta (@ta +<.node)
5483+ ?. |(?=(?(%u %ud %ux %uv %t %ta %tas %p %da %dr) aura) =('tD' aura)) ~
5486+ ?. ?=([%ref @ @] node) ~
5487+ ?. &(=(module +<.node) =(name +>.node)) ~
5490+ ?. ?=([%face @ *] node) ~
5491+ ?. (jibb-face-name +<.node) ~
5494+ ?. ?=([%cell * *] node) ~
5495+ =/ left $(node +<.node)
5497+ =/ right $(node +>.node)
5499+ `[[%cell pat.u.left pat.u.right] |(has.u.left has.u.right)]
5501+ =/ cases (rec-patterns +.node module name)
5504+ ?~ t.pats.u.cases ~
5505+ ?. (rec-patterns-disjoint pats.u.cases) ~
5506+ `[[%or pats.u.cases] has.u.cases]
5510+ |= [nodes=* module=term name=term]
5511+ ^- (unit [pats=(list upat) has=?])
5512+ ?@ nodes ?:(=(nodes 0) `[~ |] ~)
5513+ =/ first (rec-pattern -.nodes module name)
5515+ =/ rest $(nodes +.nodes)
5517+ `[[pat.u.first pats.u.rest] |(has.u.first has.u.rest)]
5519+++ rec-patterns-disjoint
5520+ |= pats=(list upat)
5523+ ?. (levy t.pats |=(p=upat =(%disjoint (union-relate i.pats p)))) |
5408++ import-to-itype
5527++ import-to-itype
5409 |= node=*
5528 |= node=*
5410 ^- (unit itype)
5529 ^- (unit itype)
@@ -5496,7 +5615,14 @@
5496 =/ result=* result.i.found
5615 =/ result=* result.i.found
5497 ?@ result ~
5616 ?@ result ~
5498 ?. ?=(%& -.result) ~
5617 ?. ?=(%& -.result) ~
5499− (import-to-itype +.result)
5618+ =/ node=* +.result
5619+ ?@ node (import-to-itype node)
5620+ ?: ?=(%ref -.node) (import-to-itype node)
5621+ =/ pattern=(unit irec-pattern) (rec-pattern node module name)
5622+ ?~ pattern (import-to-itype node)
5623+ ?. has.u.pattern (import-to-itype node)
5624+ `[%recursive module name `(crip "{(trip name)}.{(trip module)}")]
5501++ collect-sur-imports
5627++ collect-sur-imports
5502 |= imports=(list import)
5628 |= imports=(list import)
@@ -5571,6 +5697,7 @@
5571 ?~ alias ~
5697 ?~ alias ~
5572 `(crip "{(trip u.alias)}.{(trip face)}")
5698 `(crip "{(trip u.alias)}.{(trip face)}")
5573 [%union (turn cases.t |=(c=itype (itype-in-import c iface face))) origin.t label (turn args.t |=(c=itype (itype-in-import c iface face)))]
5699 [%union (turn cases.t |=(c=itype (itype-in-import c iface face))) origin.t label (turn args.t |=(c=itype (itype-in-import c iface face)))]
5700+ %recursive [%recursive module.t name.t ~]
5574 %collection [%collection name.t (turn args.t |=(c=itype (itype-in-import c iface face)))]
5701 %collection [%collection name.t (turn args.t |=(c=itype (itype-in-import c iface face)))]
5575 %face [%face name.t $(t body.t)]
5702 %face [%face name.t $(t body.t)]
5576 %fn [%fn $(t sample.t) $(t product.t)]
5703 %fn [%fn $(t sample.t) $(t product.t)]
@@ -6006,6 +6133,85 @@
6006 [%| ["branch arm does not fit its expected union" ~[[context "expected union"] [(span-of e) "branch arm"]]]]
6133 [%| ["branch arm does not fit its expected union" ~[[context "expected union"] [(span-of e) "branch arm"]]]]
6007 [%& expected state.p.value(sub sub.fit, next next.fit)]
6134 [%& expected state.p.value(sub sub.fit, next next.fit)]
6136+:: The supported unit pattern covers exactly an atom zero and a cell
6137+:: headed by zero, with a single binder for its payload. Unresolved
6138+:: subjects and all other pattern matrices stay outside this fragment.
6140+++ unit-empty-pattern
6144+ =(%null form.lit.p)
6146+++ unit-payload-pattern
6153+ ?. (unit-empty-pattern i.items.p) ~
6154+ ?. ?=(%bind -.i.t.items.p) ~
6160+ ?. ?=(%const -.t) |
6163+++ unit-payload-case
6167+ ?. (unit-empty-case hed.t) ~
6168+ =/ payload=itype tal.t
6169+ =? payload ?=(%face -.payload) body.payload
6172+++ unit-union-payload
6175+ ?. ?=(%union -.t) ~
6179+ ?: (unit-empty-case i.cases.t) (unit-payload-case i.t.cases.t)
6180+ ?: (unit-empty-case i.t.cases.t) (unit-payload-case i.cases.t)
6183+++ infer-unit-branch
6184+ |= [e=expr env=ienv state=istate]
6187+ ?~ arms.e [%| ["unit branch is not supported by partial inference" ~]]
6188+ ?~ t.arms.e [%| ["unit branch is not supported by partial inference" ~]]
6189+ ?^ t.t.arms.e [%| ["unit branch is not supported by partial inference" ~]]
6191+ =/ y=arm i.t.arms.e
6192+ =/ first-empty=? (unit-empty-pattern pat.x)
6193+ =/ first-name=(unit term) (unit-payload-pattern pat.x)
6194+ =/ second-name=(unit term) (unit-payload-pattern pat.y)
6195+ ?. |(&(first-empty ?=(^ second-name)) &((unit-empty-pattern pat.y) ?=(^ first-name)))
6196+ [%| ["unit branch pattern is not supported by partial inference" ~]]
6197+ =/ binder=(unit term) ?:(first-empty second-name first-name)
6198+ ?~ binder [%| ["unit branch pattern is not supported by partial inference" ~]]
6199+ ?: |(?=(^ (ienv-lookup u.binder env)) (lien globals.state |=(n=term =(n u.binder))))
6200+ [%| ["pattern binder shadows a name" ~]]
6201+ =/ subject=iresult (infer-fragment subject.e env state)
6202+ ?: ?=(%| -.subject) subject
6203+ =/ typ=itype (itype-normalize typ.p.subject sub.state.p.subject)
6204+ =/ payload=(unit itype) (unit-union-payload typ)
6205+ ?~ payload [%| ["unit branch subject is not supported by partial inference" ~]]
6206+ =/ extended=ienv [[u.binder [u.payload ~]] env]
6207+ =/ left=iresult (infer-fragment val.x ?:(first-empty env extended) state.p.subject)
6208+ ?: ?=(%| -.left) left
6209+ =/ right=iresult (infer-fragment val.y ?:(first-empty extended env) state.p.left)
6210+ ?: ?=(%| -.right) right
6211+ =/ joined=(unit isub) (itype-unify typ.p.left typ.p.right sub.state.p.right)
6212+ ?~ joined [%| ["unit branch results need unsupported inference" ~]]
6213+ [%& typ.p.left state.p.right(sub u.joined)]
6009++ infer-fragment
6215++ infer-fragment
6010 |= [e=expr env=ienv state=istate]
6216 |= [e=expr env=ienv state=istate]
6011 ^- iresult
6217 ^- iresult
@@ -6073,6 +6279,8 @@
6073 ?^ t.t.arms.e [%| ["branch is not supported by partial inference" ~]]
6279 ?^ t.t.arms.e [%| ["branch is not supported by partial inference" ~]]
6074 =/ x=arm i.arms.e
6280 =/ x=arm i.arms.e
6075 =/ y=arm i.t.arms.e
6281 =/ y=arm i.t.arms.e
6282+ ?: |((unit-empty-pattern pat.x) (unit-empty-pattern pat.y))
6283+ (infer-unit-branch e env state)
6076 ?. ?=(%lit -.pat.x) [%| ["branch pattern is not supported by partial inference" ~]]
6284 ?. ?=(%lit -.pat.x) [%| ["branch pattern is not supported by partial inference" ~]]
6077 ?. ?=(%lit -.pat.y) [%| ["branch pattern is not supported by partial inference" ~]]
6285 ?. ?=(%lit -.pat.y) [%| ["branch pattern is not supported by partial inference" ~]]
6078 ?. &(=(%loobean form.lit.pat.x) =(%loobean form.lit.pat.y))
6286 ?. &(=(%loobean form.lit.pat.x) =(%loobean form.lit.pat.y))
@@ -6093,6 +6301,8 @@
6093 [%| ["branch widening is not supported by partial inference" ~]]
6301 [%| ["branch widening is not supported by partial inference" ~]]
6094 =/ joined=(unit isub) (itype-unify typ.p.left typ.p.right sub.state.p.right)
6302 =/ joined=(unit isub) (itype-unify typ.p.left typ.p.right sub.state.p.right)
6095 ?~ joined
6303 ?~ joined
6304+ ?: |((itype-has-recursive ltype) (itype-has-recursive rtype))
6305+ [%| ["recursive branch matching is not supported by partial inference" ~]]
6096 ?: |((itype-has-tag ltype) (itype-has-tag rtype) (itype-has-union ltype) (itype-has-union rtype))
6306 ?: |((itype-has-tag ltype) (itype-has-tag rtype) (itype-has-union ltype) (itype-has-union rtype))
6097 [%| ["branch tag or union context is not supported by partial inference" ~]]
6307 [%| ["branch tag or union context is not supported by partial inference" ~]]
6098 =/ common=(unit itype) (itype-concrete-join typ.p.left typ.p.right sub.state.p.right)
6308 =/ common=(unit itype) (itype-concrete-join typ.p.left typ.p.right sub.state.p.right)
@@ -6197,6 +6407,8 @@
6197 =/ subject=iresult (infer-fragment subject.e env state)
6407 =/ subject=iresult (infer-fragment subject.e env state)
6198 ?: ?=(%| -.subject) subject
6408 ?: ?=(%| -.subject) subject
6199 =/ st=istate state.p.subject
6409 =/ st=istate state.p.subject
6410+ ?: (itype-has-recursive (itype-normalize typ.p.subject sub.st))
6411+ [%| ["recursive pattern is not supported by partial inference" ~]]
6200 ?: (itype-has-face typ.p.subject sub.st)
6412 ?: (itype-has-face typ.p.subject sub.st)
6201 [%| ["record patterns are not supported by partial inference" ~]]
6413 [%| ["record patterns are not supported by partial inference" ~]]
6202 =/ head=itype [%var next.st]
6414 =/ head=itype [%var next.st]
@@ -6228,6 +6440,7 @@
6228 ?~ label.t (show-itype-cases cases.t sub)
6440 ?~ label.t (show-itype-cases cases.t sub)
6229 ?~ args.t (trip u.label.t)
6441 ?~ args.t (trip u.label.t)
6230 "({(trip u.label.t)} {(show-itype-cases args.t sub)})"
6442 "({(trip u.label.t)} {(show-itype-cases args.t sub)})"
6443+ %recursive ?~(label.t "recursive mold" (trip u.label.t))
6231 %collection "({(trip name.t)} {(show-itype-cases args.t sub)})"
6444 %collection "({(trip name.t)} {(show-itype-cases args.t sub)})"
6232 %face "[{(trip name.t)}={(show-itype-context body.t sub)}]"
6445 %face "[{(trip name.t)}={(show-itype-context body.t sub)}]"
6233 %fn "$-({(show-itype-context sample.t sub)} {(show-itype-context product.t sub)})"
6446 %fn "$-({(show-itype-context sample.t sub)} {(show-itype-context product.t sub)})"
@@ -6271,6 +6484,7 @@
6272 %const |
6485 %const |
6273 %union |((lien cases.typ |=(c=itype (itype-has-nvar c))) (lien args.typ |=(c=itype (itype-has-nvar c))))
6486 %union |((lien cases.typ |=(c=itype (itype-has-nvar c))) (lien args.typ |=(c=itype (itype-has-nvar c))))
6274 %collection (lien args.typ |=(c=itype (itype-has-nvar c)))
6488 %collection (lien args.typ |=(c=itype (itype-has-nvar c)))
6275 %face $(typ body.typ)
6489 %face $(typ body.typ)
6276 %fn |($(typ sample.typ) $(typ product.typ))
6490 %fn |($(typ sample.typ) $(typ product.typ))
@@ -6282,6 +6496,7 @@
6283 =/ normalized=itype (itype-normalize typ sub)
6497 =/ normalized=itype (itype-normalize typ sub)
6284 ?: |(?=(%var -.normalized) ?=(%avar -.normalized) (itype-has-nvar normalized) (itype-has-tag normalized) (itype-has-union normalized)) label
6498 ?: |(?=(%var -.normalized) ?=(%avar -.normalized) (itype-has-nvar normalized) (itype-has-tag normalized) (itype-has-union normalized)) label
6499+ ?: (itype-has-hidden-recursive normalized) label
6285 =/ vars=(list @ud) (unique-type-vars (itype-vars normalized))
6500 =/ vars=(list @ud) (unique-type-vars (itype-vars normalized))
6286 ?: (gth (lent vars) 26) label
6501 ?: (gth (lent vars) 26) label
6287 =/ printable=itype (canonical-itype normalized vars)
6502 =/ printable=itype (canonical-itype normalized vars)
@@ -6348,6 +6563,7 @@
6349 %const |
6564 %const |
6350 %union |((lien cases.t |=(c=itype (has-atom-var n c))) (lien args.t |=(c=itype (has-atom-var n c))))
6565 %union |((lien cases.t |=(c=itype (has-atom-var n c))) (lien args.t |=(c=itype (has-atom-var n c))))
6351 %collection (lien args.t |=(c=itype (has-atom-var n c)))
6567 %collection (lien args.t |=(c=itype (has-atom-var n c)))
6352 %face $(t body.t)
6568 %face $(t body.t)
6353 %fn |($(t sample.t) $(t product.t))
6569 %fn |($(t sample.t) $(t product.t))
@@ -6820,6 +7036,8 @@
6820 $(ds t.ds, lines [(crip "++ {(trip name.d)}: `~` needs context in partial inference") lines])
7036 $(ds t.ds, lines [(crip "++ {(trip name.d)}: `~` needs context in partial inference") lines])
6821 ?: |((pending-tags tags.state.p.result sub.state.p.result) (itype-has-tag typ))
7037 ?: |((pending-tags tags.state.p.result sub.state.p.result) (itype-has-tag typ))
6822 $(ds t.ds, lines [(crip "++ {(trip name.d)}: tag needs context in partial inference") lines])
7038 $(ds t.ds, lines [(crip "++ {(trip name.d)}: tag needs context in partial inference") lines])
7039+ ?: (itype-has-hidden-recursive typ)
7040+ $(ds t.ds, lines [(crip "++ {(trip name.d)}: recursive mold name is not available in this scope") lines])
6823 ?: (itype-has-hidden-generic typ)
7041 ?: (itype-has-hidden-generic typ)
6824 $(ds t.ds, lines [(crip "++ {(trip name.d)}: generic union name is not available in this scope") lines])
7042 $(ds t.ds, lines [(crip "++ {(trip name.d)}: generic union name is not available in this scope") lines])
6825 ?: (unsupported-atom-vars typ caps.state.p.result binders.state.p.result sub.state.p.result)
7043 ?: (unsupported-atom-vars typ caps.state.p.result binders.state.p.result sub.state.p.result)