Mercurial > repo
view src/ploki/examples/ref.pk @ 11952:bf859c78a439 draft
<kmc> addquote <ais523> (one nice thing about asking in #esoteric rather than #perl is that you don\'t have to attempt to justify what you\'re doing)
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Sun, 22 Sep 2019 02:09:55 +0000 |
parents | ac0403686959 |
children |
line wrap: on
line source
GOTO 496 FOR *&ref-assign*& LET $(\@ . 0) \@ . 1 KTHX \@ . 1 FOR *&ref-call&* LEET id \@ . 0 LEET arg \@ . 1 IF \L arg : "set" LEET ref $$ref$$(id) KTHX @OMFG @*&ref-assign*& #<ref \@#> FI KTHX $($$ref$$(id)) FOR ref LEET val \@ LET $$ref$cnt$$ += 1 LEET ref @OMFG @*&ref-call&* #<$$ref$cnt$$ \@#> LET $$ref$$($$ref$cnt$$) ref LET $(ref) \@ KTHX ref 496 #!