Refactor peek.

This commit is contained in:
C. Guy Yarvin 2014-01-05 16:02:34 -08:00
parent dbb5ca3673
commit 59815373bd

View File

@ -7361,7 +7361,7 @@
~& %hoon-load ~& %hoon-load
=^ rey +>+ (^load +<) =^ rey +>+ (^load +<)
[rey +>.$] [rey +>.$]
++ peek |=(* (^peek ((hard ,[@p @da path]) +<))) :: 87 ++ peek |=(* (^peek ((hard ,[@da path]) +<))) :: 87
++ poke |= * :: 42 ++ poke |= * :: 42
^- [(list ovum) *] ^- [(list ovum) *]
=> .(+< ((hard ,[now=@da ovo=ovum]) +<)) => .(+< ((hard ,[now=@da ovo=ovum]) +<))
@ -7405,9 +7405,9 @@
=+(avo=$(ova t.ova) [[i.ova -.avo] +.avo]) =+(avo=$(ova t.ova) [[i.ova -.avo] +.avo])
:: ::
++ peek :: external inspect ++ peek :: external inspect
|= [our=@p now=@da hap=path] |= [now=@da hap=path]
^- (unit) ^- (unit)
?~ hap ~ ?~ hap [~ stub]
((~(beck (is eny vil bud fan) now) ~) hap) ((~(beck (is eny vil bud fan) now) ~) hap)
:: ::
++ poke :: external apply ++ poke :: external apply
@ -7422,7 +7422,7 @@
^- [p=(list ovum) q=*] ^- [p=(list ovum) q=*]
=+ pax=(weld hap `path`[%hoon ~]) =+ pax=(weld hap `path`[%hoon ~])
~& [%vega-start hap] ~& [%vega-start hap]
=+ src=((hard ,@t) (need (peek ~zod now cx/pax))) =+ src=((hard ,@t) (need (peek now cx/pax)))
=+ saz=(shax src) =+ saz=(shax src)
=+ gen=(rain hap src) =+ gen=(rain hap src)
~& %vega-parsed ~& %vega-parsed