{ box foos = [] fn foo! { () -> update! (foos, append (_, :foo) ) } fn foos! { () -> repeat 4 { { foo! () } } } foos! () unbox (foos) } closing over in type at 1: #{:list fn list/base... closing over in eq? at 1: #{:list fn list/base... closing over in eq? at 2: fn eq? closing over in first at 1: #{:list fn list/base... closing over in rest at 1: #{:list fn list/base... closing over in inc at 1: #{:list fn list/base... closing over in dec at 1: #{:list fn list/base... closing over in count at 1: #{:list fn list/base... closing over in any? at 1: fn empty? closing over in any? at 2: fn not closing over in list at 1: #{:list fn list/base... closing over in append at 1: #{:list fn list/base... closing over in fold at 1: fn fold closing over in fold at 2: fn first closing over in fold at 3: fn rest closing over in foldr at 1: fn foldr closing over in foldr at 2: fn first closing over in foldr at 3: fn rest closing over in map at 1: fn map closing over in map at 2: fn append closing over in map at 3: fn fold closing over in filter at 1: fn filter closing over in filter at 2: fn append closing over in filter at 3: fn fold closing over in keep at 1: fn some? closing over in keep at 2: fn filter closing over in concat at 1: #{:list fn list/base... closing over in concat at 2: fn concat closing over in concat at 3: fn fold closing over in contains? at 1: fn first closing over in contains? at 2: fn eq? closing over in contains? at 3: fn rest closing over in print! at 1: #{:list fn list/base... closing over in show at 1: #{:list fn list/base... closing over in report! at 1: fn print! closing over in report! at 2: fn show closing over in report! at 3: fn concat closing over in doc! at 1: #{:list fn list/base... closing over in doc! at 2: fn print! closing over in string at 1: fn show closing over in string at 2: fn string closing over in string at 3: fn concat closing over in join at 1: fn join closing over in join at 2: fn concat closing over in join at 3: fn fold closing over in split at 1: #{:list fn list/base... closing over in trim at 1: #{:list fn list/base... closing over in upcase at 1: #{:list fn list/base... closing over in downcase at 1: #{:list fn list/base... closing over in chars at 1: #{:list fn list/base... closing over in chars/safe at 1: #{:list fn list/base... closing over in strip at 1: fn strip closing over in words at 1: fn strip closing over in words at 2: fn split closing over in words at 3: fn empty? closing over in words at 4: fn append closing over in words at 5: fn fold closing over in sentence at 1: fn join closing over in to_number at 1: #{:list fn list/base... closing over in unbox at 1: #{:list fn list/base... closing over in store! at 1: #{:list fn list/base... closing over in update! at 1: fn unbox closing over in update! at 2: fn store! closing over in add at 1: #{:list fn list/base... closing over in add at 2: fn add closing over in add at 3: fn fold closing over in sub at 1: #{:list fn list/base... closing over in sub at 2: fn sub closing over in sub at 3: fn fold closing over in mult at 1: #{:list fn list/base... closing over in mult at 2: fn mult closing over in mult at 3: fn fold closing over in div at 1: #{:list fn list/base... closing over in div at 2: fn mult closing over in div at 3: fn fold closing over in div at 4: fn div closing over in div/0 at 1: #{:list fn list/base... closing over in div/0 at 2: fn mult closing over in div/0 at 3: fn fold closing over in div/0 at 4: fn div/0 closing over in div/safe at 1: fn div closing over in div/safe at 2: fn mult closing over in div/safe at 3: fn fold closing over in div/safe at 4: fn div/safe closing over in inv at 1: fn div closing over in inv/0 at 1: fn div/0 closing over in inv/safe at 1: fn div/safe closing over in neg at 1: fn mult closing over in gt? at 1: #{:list fn list/base... closing over in gte? at 1: #{:list fn list/base... closing over in lt? at 1: #{:list fn list/base... closing over in lte? at 1: #{:list fn list/base... closing over in between? at 1: fn gte? closing over in between? at 2: fn lt? closing over in neg? at 1: fn lt? closing over in pos? at 1: fn gt? closing over in abs at 1: fn neg? closing over in abs at 2: fn mult closing over in turn/deg at 1: fn mult closing over in deg/turn at 1: fn div closing over in turn/rad at 1: 6.283185307179586 closing over in turn/rad at 2: fn mult closing over in rad/turn at 1: 6.283185307179586 closing over in rad/turn at 2: fn div closing over in deg/rad at 1: 6.283185307179586 closing over in deg/rad at 2: fn div closing over in deg/rad at 3: fn mult closing over in rad/deg at 1: 6.283185307179586 closing over in rad/deg at 2: fn div closing over in rad/deg at 3: fn mult closing over in sin at 1: fn turn/rad closing over in sin at 2: #{:list fn list/base... closing over in sin at 3: fn deg/rad closing over in cos at 1: fn turn/rad closing over in cos at 2: #{:list fn list/base... closing over in cos at 3: fn deg/rad closing over in tan at 1: fn turn/rad closing over in tan at 2: #{:list fn list/base... closing over in tan at 3: fn deg/rad closing over in rotate at 1: fn rotate closing over in rotate at 2: fn cos closing over in rotate at 3: fn mult closing over in rotate at 4: fn sin closing over in rotate at 5: fn sub closing over in rotate at 6: fn add closing over in atan/2 at 1: #{:list fn list/base... closing over in atan/2 at 2: fn rad/turn closing over in atan/2 at 3: fn atan/2 closing over in atan/2 at 4: fn rad/deg closing over in angle at 1: fn atan/2 closing over in angle at 2: fn sub closing over in mod at 1: #{:list fn list/base... closing over in mod/0 at 1: #{:list fn list/base... closing over in mod/safe at 1: #{:list fn list/base... closing over in even? at 1: fn mod closing over in even? at 2: fn eq? closing over in odd? at 1: fn mod closing over in odd? at 2: fn eq? closing over in square at 1: fn mult closing over in sqrt at 1: fn neg? closing over in sqrt at 2: fn not closing over in sqrt at 3: #{:list fn list/base... closing over in sqrt/safe at 1: fn neg? closing over in sqrt/safe at 2: fn not closing over in sqrt/safe at 3: #{:list fn list/base... closing over in sum_of_squares at 1: fn square closing over in sum_of_squares at 2: fn add closing over in sum_of_squares at 3: fn sum_of_squares closing over in sum_of_squares at 4: fn fold closing over in dist at 1: fn sum_of_squares closing over in dist at 2: fn sqrt closing over in dist at 3: fn dist closing over in heading/vector at 1: fn neg closing over in heading/vector at 2: fn add closing over in heading/vector at 3: fn cos closing over in heading/vector at 4: fn sin closing over in floor at 1: #{:list fn list/base... closing over in ceil at 1: #{:list fn list/base... closing over in round at 1: #{:list fn list/base... closing over in range at 1: #{:list fn list/base... closing over in at at 1: #{:list fn list/base... closing over in second at 1: fn ordered? closing over in second at 2: fn at closing over in last at 1: fn ordered? closing over in last at 2: fn count closing over in last at 3: fn dec closing over in last at 4: fn at closing over in slice at 1: fn slice closing over in slice at 2: fn gte? closing over in slice at 3: fn count closing over in slice at 4: fn gt? closing over in slice at 5: fn neg? closing over in slice at 6: #{:list fn list/base... closing over in butlast at 1: fn count closing over in butlast at 2: fn dec closing over in butlast at 3: fn slice closing over in assoc at 1: #{:list fn list/base... closing over in dissoc at 1: #{:list fn list/base... closing over in get at 1: fn get closing over in get at 2: #{:list fn list/base... closing over in update at 1: fn get closing over in update at 2: fn assoc closing over in keys at 1: fn list closing over in keys at 2: fn first closing over in keys at 3: fn map closing over in values at 1: fn list closing over in values at 2: fn second closing over in values at 3: fn map closing over in has? at 1: fn has? closing over in has? at 2: fn get closing over in has? at 3: fn some? closing over in dict at 1: fn assoc closing over in dict at 2: fn fold closing over in dict at 3: fn list closing over in dict at 4: fn dict closing over in each! at 1: fn each! closing over in random at 1: #{:list fn list/base... closing over in random at 2: fn random closing over in random at 3: fn mult closing over in random at 4: fn sub closing over in random at 5: fn add closing over in random at 6: fn count closing over in random at 7: fn floor closing over in random at 8: fn at closing over in random at 9: fn keys closing over in random at 10: fn get closing over in random_int at 1: fn random closing over in random_int at 2: fn floor closing over in add_command! at 1: box { [] } closing over in add_command! at 2: fn append closing over in add_command! at 3: fn update! closing over in add_command! at 4: box { #{:position (0... closing over in add_command! at 5: fn unbox closing over in add_command! at 6: fn apply_command closing over in add_command! at 7: fn store! closing over in forward! at 1: fn add_command! closing over in back! at 1: fn add_command! closing over in left! at 1: fn add_command! closing over in right! at 1: fn add_command! closing over in penup! at 1: fn add_command! closing over in pendown! at 1: fn add_command! closing over in pencolor! at 1: fn add_command! closing over in penwidth! at 1: fn add_command! closing over in background! at 1: fn add_command! closing over in home! at 1: fn add_command! closing over in clear! at 1: fn add_command! closing over in goto! at 1: fn add_command! closing over in goto! at 2: fn goto! closing over in setheading! at 1: fn add_command! closing over in showturtle! at 1: fn add_command! closing over in hideturtle! at 1: fn add_command! closing over in loadstate! at 1: fn add_command! closing over in apply_command at 1: fn assoc closing over in apply_command at 2: fn add closing over in apply_command at 3: fn update closing over in apply_command at 4: fn sub closing over in apply_command at 5: fn heading/vector closing over in apply_command at 6: fn mult closing over in position at 1: box { #{:position (0... closing over in position at 2: fn unbox closing over in heading at 1: box { #{:position (0... closing over in heading at 2: fn unbox closing over in pendown? at 1: box { #{:position (0... closing over in pendown? at 2: fn unbox closing over in pencolor at 1: box { #{:position (0... closing over in pencolor at 2: fn unbox closing over in penwidth at 1: box { #{:position (0... closing over in penwidth at 2: fn unbox binding `foos` in sandbox stack depth: 1; match depth: 0 at stack index: 0 new locals: foos@0//0 binding `foo!` in sandbox stack depth: 2; match depth: 0 at stack index: 1 new locals: foos@0//0|foo!@1//0 ***function clause matching: : () ***calling function update! stack depth: 0 resolving binding `foos` in foo! locals: as enclosing upvalue 0 ***calling function append stack depth: 1 resolving binding `append` in foo! locals: as enclosing upvalue 1 resolving binding `update!` in foo! locals: as enclosing upvalue 2 ***after 2 args stack depth: 3 === function chuncktion: foo!/0 === IDX | CODE | INFO 0000: reset_match 0001: ***function clause matching: : () 0003: match 0004: jump 00000 0007: jump_if_no_match 00034 0010: ***calling function update! stack depth: 0 0012: resolving binding `foos` in foo! locals: 0014: as enclosing upvalue 0 0016: get_upvalue 000 0018: ***calling function append stack depth: 1 0020: nothing 0021: constant 00000: :foo 0024: resolving binding `append` in foo! locals: 0026: as enclosing upvalue 1 0028: get_upvalue 001 0030: partial 002 0032: resolving binding `update!` in foo! locals: 0034: as enclosing upvalue 2 0036: get_upvalue 002 0038: ***after 2 args stack depth: 3 0040: tail_call 002 0042: store 0043: return 0044: panic_no_match resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0 at locals position 0 resolving binding `append` in sandbox locals: foos@0//0|foo!@1//0 as global resolving binding `update!` in sandbox locals: foos@0//0|foo!@1//0 as global binding `foos!` in sandbox stack depth: 3; match depth: 0 at stack index: 2 new locals: foos@0//0|foo!@1//0|foos!@2//0 ***function clause matching: : () ***calling function foo! stack depth: 1 resolving binding `foo!` in foos! locals: as enclosing upvalue 0 ***after 0 args stack depth: 2 leaving scope 1 ***leaving block before pop stack depth: 1 popping back from 1 to 1 === function chuncktion: foos!/0 === IDX | CODE | INFO 0000: reset_match 0001: ***function clause matching: : () 0003: match 0004: jump 00000 0007: jump_if_no_match 00042 0010: constant 00000: 4 0013: truncate 0014: jump 00001 0017: decrement 0018: duplicate 0019: jump_if_zero 00024 0022: ***calling function foo! stack depth: 1 0024: resolving binding `foo!` in foos! locals: 0026: as enclosing upvalue 0 0028: get_upvalue 000 0030: ***after 0 args stack depth: 2 0032: tail_call 000 0034: store 0035: leaving scope 1 0037: ***leaving block before pop stack depth: 1 0039: popping back from 1 to 1 0041: load 0042: pop 0043: jump_back 00026 0046: pop 0047: constant 00001: nil 0050: store 0051: return 0052: panic_no_match resolving binding `foo!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 at locals position 1 ***calling function foos! stack depth: 3 resolving binding `foos!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 at locals position 2 ***after 0 args stack depth: 4 ***calling function unbox stack depth: 3 resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 at locals position 0 resolving binding `unbox` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 as global ***after 1 args stack depth: 5 leaving scope 0 releasing binding foos!@2//0 releasing binding foo!@1//0 releasing binding foos@0//0 ***leaving block before pop stack depth: 3 popping back from 3 to 0 === source code === box foos = [] fn foo! () -> update! (foos, append (_, :foo)) fn foos! () -> repeat 4 { foo! () } foos! () unbox (foos) === chunk: sandbox === IDX | CODE | INFO 0000: push_list 0001: push_box 082 0003: noop 0004: stack depth: 1; match depth: 0 0006: at stack index: 0 0008: new locals: foos@0//0 0010: constant 00000: fn foo! 0013: binding `foo!` in sandbox 0015: stack depth: 2; match depth: 0 0017: at stack index: 1 0019: new locals: foos@0//0|foo!@1//0 0021: resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0 0023: at locals position 0 0025: push_binding 000 0027: set_upvalue 0028: resolving binding `append` in sandbox locals: foos@0//0|foo!@1//0 0030: as global 0032: constant 00001: :append 0035: push_global 0036: set_upvalue 0037: resolving binding `update!` in sandbox locals: foos@0//0|foo!@1//0 0039: as global 0041: constant 00002: :update! 0044: push_global 0045: set_upvalue 0046: constant 00003: fn foos! 0049: binding `foos!` in sandbox 0051: stack depth: 3; match depth: 0 0053: at stack index: 2 0055: new locals: foos@0//0|foo!@1//0|foos!@2//0 0057: resolving binding `foo!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0059: at locals position 1 0061: push_binding 001 0063: set_upvalue 0064: ***calling function foos! stack depth: 3 0066: resolving binding `foos!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0068: at locals position 2 0070: push_binding 002 0072: ***after 0 args stack depth: 4 0074: call 000 0076: pop 0077: ***calling function unbox stack depth: 3 0079: resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0081: at locals position 0 0083: push_binding 000 0085: resolving binding `unbox` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0087: as global 0089: constant 00004: :unbox 0092: push_global 0093: ***after 1 args stack depth: 5 0095: call 001 0097: store 0098: leaving scope 0 0100: releasing binding foos!@2//0 0102: releasing binding foo!@1//0 0104: releasing binding foos@0//0 0106: ***leaving block before pop stack depth: 3 0108: popping back from 3 to 0 0110: pop_n 003 0112: load === vm run === 0000: [] (_,_,_,_,_,_,_,_) 0000: push_list 0001: [->[]<-] (_,_,_,_,_,_,_,_) 0001: push_box 082 0002: [->box { [] }<-] (_,_,_,_,_,_,_,_) 0002: binding `foos` in sandbox 0004: [->box { [] }<-] (_,_,_,_,_,_,_,_) 0004: stack depth: 1; match depth: 0 0006: [->box { [] }<-] (_,_,_,_,_,_,_,_) 0006: at stack index: 0 0008: [->box { [] }<-] (_,_,_,_,_,_,_,_) 0008: new locals: foos@0//0 0010: [->box { [] }<-] (_,_,_,_,_,_,_,_) 0010: constant 00000: fn foo! 0013: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0013: binding `foo!` in sandbox 0015: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0015: stack depth: 2; match depth: 0 0017: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0017: at stack index: 1 0019: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0019: new locals: foos@0//0|foo!@1//0 0021: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0021: resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0 0023: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0023: at locals position 0 0025: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0025: push_binding 000 0027: [->box { [] }<-|fn foo!|box { [] }] (_,_,_,_,_,_,_,_) 0027: set_upvalue closing over in foo! at 1: box { [] } 0028: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0028: resolving binding `append` in sandbox locals: foos@0//0|foo!@1//0 0030: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0030: as global 0032: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0032: constant 00001: :append 0035: [->box { [] }<-|fn foo!|:append] (_,_,_,_,_,_,_,_) 0035: push_global 0036: [->box { [] }<-|fn foo!|fn append] (_,_,_,_,_,_,_,_) 0036: set_upvalue closing over in foo! at 2: fn append 0037: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0037: resolving binding `update!` in sandbox locals: foos@0//0|foo!@1//0 0039: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0039: as global 0041: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0041: constant 00002: :update! 0044: [->box { [] }<-|fn foo!|:update!] (_,_,_,_,_,_,_,_) 0044: push_global 0045: [->box { [] }<-|fn foo!|fn update!] (_,_,_,_,_,_,_,_) 0045: set_upvalue closing over in foo! at 3: fn update! 0046: [->box { [] }<-|fn foo!] (_,_,_,_,_,_,_,_) 0046: constant 00003: fn foos! 0049: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0049: binding `foos!` in sandbox 0051: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0051: stack depth: 3; match depth: 0 0053: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0053: at stack index: 2 0055: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0055: new locals: foos@0//0|foo!@1//0|foos!@2//0 0057: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0057: resolving binding `foo!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0059: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0059: at locals position 1 0061: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0061: push_binding 001 0063: [->box { [] }<-|fn foo!|fn foos!|fn foo!] (_,_,_,_,_,_,_,_) 0063: set_upvalue closing over in foos! at 1: fn foo! 0064: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0064: ***calling function foos! stack depth: 3 0066: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0066: resolving binding `foos!` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0068: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0068: at locals position 2 0070: [->box { [] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0070: push_binding 002 0072: [->box { [] }<-|fn foo!|fn foos!|fn foos!] (_,_,_,_,_,_,_,_) 0072: ***after 0 args stack depth: 4 0074: [->box { [] }<-|fn foo!|fn foos!|fn foos!] (_,_,_,_,_,_,_,_) 0074: call 000 === calling into fn foos!/0 === 0000: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0001: ***function clause matching: : () 0003: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0003: match 0004: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0004: jump 00000 0007: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00042 0010: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0010: constant 00000: 4 0013: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0013: truncate 0014: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0014: jump 00001 0018: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0018: duplicate 0019: [box { [] }|fn foo!|fn foos!|->4<-|4] (_,_,_,_,_,_,_,_) 0019: jump_if_zero 00024 0022: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0022: ***calling function foo! stack depth: 1 0024: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0024: resolving binding `foo!` in foos! locals: 0026: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0026: as enclosing upvalue 0 0028: [box { [] }|fn foo!|fn foos!|->4<-] (_,_,_,_,_,_,_,_) 0028: get_upvalue 000 0030: [box { [] }|fn foo!|fn foos!|->4<-|fn foo!] (_,_,_,_,_,_,_,_) 0030: ***after 0 args stack depth: 2 0032: [box { [] }|fn foo!|fn foos!|->4<-|fn foo!] (_,_,_,_,_,_,_,_) 0032: tail_call 000 === tail call into fn foo!/0 from foos! === 0000: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0001: ***function clause matching: : () 0003: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0003: match 0004: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0004: jump 00000 0007: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00034 0010: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0010: ***calling function update! stack depth: 0 0012: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0012: resolving binding `foos` in foo! locals: 0014: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0014: as enclosing upvalue 0 0016: [box { [] }|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0016: get_upvalue 000 0018: [box { [] }|fn foo!|fn foos!|->box { [] }<-] (_,_,_,_,_,_,_,_) 0018: ***calling function append stack depth: 1 0020: [box { [] }|fn foo!|fn foos!|->box { [] }<-] (_,_,_,_,_,_,_,_) 0020: nothing 0021: [box { [] }|fn foo!|fn foos!|->box { [] }<-|_] (_,_,_,_,_,_,_,_) 0021: constant 00000: :foo 0024: [box { [] }|fn foo!|fn foos!|->box { [] }<-|_|:foo] (_,_,_,_,_,_,_,_) 0024: resolving binding `append` in foo! locals: 0026: [box { [] }|fn foo!|fn foos!|->box { [] }<-|_|:foo] (_,_,_,_,_,_,_,_) 0026: as enclosing upvalue 1 0028: [box { [] }|fn foo!|fn foos!|->box { [] }<-|_|:foo] (_,_,_,_,_,_,_,_) 0028: get_upvalue 001 0030: [box { [] }|fn foo!|fn foos!|->box { [] }<-|_|:foo|fn append] (_,_,_,_,_,_,_,_) 0030: partial 002 0032: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0032: resolving binding `update!` in foo! locals: 0034: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0034: as enclosing upvalue 2 0036: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0036: get_upvalue 002 0038: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|fn update!] (_,_,_,_,_,_,_,_) 0038: ***after 2 args stack depth: 3 0040: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|fn update!] (_,_,_,_,_,_,_,_) 0040: tail_call 002 === tail call into fn update!/2 from foo! === 0000: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0001: match_depth 001 0003: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0003: constant 00000: :box 0006: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|:box] (_,_,_,_,_,_,_,_) 0006: match_type 0007: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00012 0010: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0010: match_depth 000 0012: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0012: constant 00001: :fn 0015: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|:fn] (_,_,_,_,_,_,_,_) 0015: match_type 0016: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0016: jump_if_no_match 00003 0019: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0019: jump 00000 0022: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0022: jump_if_no_match 00034 0025: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial] (_,_,_,_,_,_,_,_) 0025: push_binding 000 0027: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|box { [] }] (_,_,_,_,_,_,_,_) 0027: get_upvalue 000 0029: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|box { [] }|fn unbox] (_,_,_,_,_,_,_,_) 0029: call 001 === calling into fn unbox/1 === 0000: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0001: match_depth 000 0003: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0003: constant 00000: :box 0006: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|:box] (_,_,_,_,_,_,_,_) 0006: match_type 0007: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00003 0010: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0010: jump 00000 0013: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0013: jump_if_no_match 00015 0016: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (_,_,_,_,_,_,_,_) 0016: get_upvalue 000 0018: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|#{:list fn list/base...] (_,_,_,_,_,_,_,_) 0018: constant 00001: :unbox 0021: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|#{:list fn list/base...|:unbox] (_,_,_,_,_,_,_,_) 0021: get_key 0022: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|fn unbox/base] (_,_,_,_,_,_,_,_) 0022: store 0023: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] (fn unbox/base,_,_,_,_,_,_,_) 0023: push_binding 000 0025: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|box { [] }] (fn unbox/base,_,_,_,_,_,_,_) 0025: load 0026: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|box { [] }|fn unbox/base] (_,_,_,_,_,_,_,_) 0026: tail_call 001 === tail call into fn unbox/base/1 from unbox === 0028: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-|[]] (_,_,_,_,_,_,_,_) 0028: store 0029: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|->box { [] }<-] ([],_,_,_,_,_,_,_) 0029: pop 0030: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial] ([],_,_,_,_,_,_,_) 0030: return == returning from fn unbox == 0031: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]] (_,_,_,_,_,_,_,_) 0031: reset_match 0032: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]] (_,_,_,_,_,_,_,_) 0032: match 0033: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]] (_,_,_,_,_,_,_,_) 0033: panic_if_no_match 0034: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]] (_,_,_,_,_,_,_,_) 0034: push_binding 002 0036: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[]] (_,_,_,_,_,_,_,_) 0036: push_binding 001 0038: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[]|fn append/partial] (_,_,_,_,_,_,_,_) 0038: call 001 === calling into fn append/partial/1 === 0000: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0001: match_depth 001 0003: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0003: constant 00000: :list 0006: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|:list] (_,_,_,_,_,_,_,_) 0006: match_type 0007: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00009 0010: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0010: match_depth 000 0012: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0012: match 0013: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0013: jump_if_no_match 00003 0016: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0016: jump 00000 0019: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0019: jump_if_no_match 00018 0022: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (_,_,_,_,_,_,_,_) 0022: get_upvalue 000 0024: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|#{:list fn list/base...] (_,_,_,_,_,_,_,_) 0024: constant 00001: :append 0027: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|#{:list fn list/base...|:append] (_,_,_,_,_,_,_,_) 0027: get_key 0028: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|fn append/base] (_,_,_,_,_,_,_,_) 0028: store 0029: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] (fn append/base,_,_,_,_,_,_,_) 0029: push_binding 000 0031: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|[]] (fn append/base,_,_,_,_,_,_,_) 0031: push_binding 001 0033: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|[]|:foo] (fn append/base,_,_,_,_,_,_,_) 0033: load 0034: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|[]|:foo|fn append/base] (_,_,_,_,_,_,_,_) 0034: tail_call 002 === tail call into fn append/base/2 from append === 0036: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo|[:foo]] (_,_,_,_,_,_,_,_) 0036: store 0037: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]|->[]<-|:foo] ([:foo],_,_,_,_,_,_,_) 0037: pop_n 002 0039: [box { [] }|fn foo!|fn foos!|box { [] }|fn append/partial|[]] ([:foo],_,_,_,_,_,_,_) 0039: return == returning from fn append == 0040: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]] (_,_,_,_,_,_,_,_) 0040: reset_match 0041: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]] (_,_,_,_,_,_,_,_) 0041: match 0042: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]] (_,_,_,_,_,_,_,_) 0042: panic_if_no_match 0043: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]] (_,_,_,_,_,_,_,_) 0043: push_binding 000 0045: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]|box { [] }] (_,_,_,_,_,_,_,_) 0045: push_binding 003 0047: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]|box { [] }|[:foo]] (_,_,_,_,_,_,_,_) 0047: get_upvalue 001 0049: [box { [] }|fn foo!|fn foos!|->box { [] }<-|fn append/partial|[]|[:foo]|box { [] }|[:foo]|fn store!] (_,_,_,_,_,_,_,_) 0049: tail_call 002 === tail call into fn store!/2 from update! === 0000: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0001: match_depth 001 0003: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0003: constant 00000: :box 0006: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|:box] (_,_,_,_,_,_,_,_) 0006: match_type 0007: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00009 0010: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0010: match_depth 000 0012: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0012: match 0013: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0013: jump_if_no_match 00003 0016: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0016: jump 00000 0019: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0019: jump_if_no_match 00023 0022: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0022: get_upvalue 000 0024: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|#{:list fn list/base...] (_,_,_,_,_,_,_,_) 0024: constant 00001: :store! 0027: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|#{:list fn list/base...|:store!] (_,_,_,_,_,_,_,_) 0027: get_key 0028: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|fn store!/base] (_,_,_,_,_,_,_,_) 0028: store 0029: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]] (fn store!/base,_,_,_,_,_,_,_) 0029: push_binding 000 0031: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|box { [] }] (fn store!/base,_,_,_,_,_,_,_) 0031: push_binding 001 0033: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|box { [] }|[:foo]] (fn store!/base,_,_,_,_,_,_,_) 0033: load 0034: [box { [] }|fn foo!|fn foos!|->box { [] }<-|[:foo]|box { [] }|[:foo]|fn store!/base] (_,_,_,_,_,_,_,_) 0034: call 002 === calling into fn store!/base/2 === 0036: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]|[:foo]] (_,_,_,_,_,_,_,_) 0036: pop 0037: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0037: push_binding 001 0039: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]|[:foo]] (_,_,_,_,_,_,_,_) 0039: store 0040: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]] ([:foo],_,_,_,_,_,_,_) 0040: load 0041: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]|[:foo]] (_,_,_,_,_,_,_,_) 0041: store 0042: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]] ([:foo],_,_,_,_,_,_,_) 0042: pop_n 002 0044: [box { [:foo] }|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0044: return == returning from fn store! == 0076: [->box { [:foo] }<-|fn foo!|fn foos!|[:foo]] (_,_,_,_,_,_,_,_) 0076: pop 0077: [->box { [:foo] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0077: ***calling function unbox stack depth: 3 0079: [->box { [:foo] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0079: resolving binding `foos` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0081: [->box { [:foo] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0081: at locals position 0 0083: [->box { [:foo] }<-|fn foo!|fn foos!] (_,_,_,_,_,_,_,_) 0083: push_binding 000 0085: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }] (_,_,_,_,_,_,_,_) 0085: resolving binding `unbox` in sandbox locals: foos@0//0|foo!@1//0|foos!@2//0 0087: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }] (_,_,_,_,_,_,_,_) 0087: as global 0089: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }] (_,_,_,_,_,_,_,_) 0089: constant 00004: :unbox 0092: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }|:unbox] (_,_,_,_,_,_,_,_) 0092: push_global 0093: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }|fn unbox] (_,_,_,_,_,_,_,_) 0093: ***after 1 args stack depth: 5 0095: [->box { [:foo] }<-|fn foo!|fn foos!|box { [:foo] }|fn unbox] (_,_,_,_,_,_,_,_) 0095: call 001 === calling into fn unbox/1 === 0000: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0000: reset_match 0001: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0001: match_depth 000 0003: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0003: constant 00000: :box 0006: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|:box] (_,_,_,_,_,_,_,_) 0006: match_type 0007: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0007: jump_if_no_match 00003 0010: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0010: jump 00000 0013: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0013: jump_if_no_match 00015 0016: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (_,_,_,_,_,_,_,_) 0016: get_upvalue 000 0018: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|#{:list fn list/base...] (_,_,_,_,_,_,_,_) 0018: constant 00001: :unbox 0021: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|#{:list fn list/base...|:unbox] (_,_,_,_,_,_,_,_) 0021: get_key 0022: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|fn unbox/base] (_,_,_,_,_,_,_,_) 0022: store 0023: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] (fn unbox/base,_,_,_,_,_,_,_) 0023: push_binding 000 0025: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|box { [:foo] }] (fn unbox/base,_,_,_,_,_,_,_) 0025: load 0026: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|box { [:foo] }|fn unbox/base] (_,_,_,_,_,_,_,_) 0026: tail_call 001 === tail call into fn unbox/base/1 from unbox === 0028: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-|[:foo]] (_,_,_,_,_,_,_,_) 0028: store 0029: [box { [:foo] }|fn foo!|fn foos!|->box { [:foo] }<-] ([:foo],_,_,_,_,_,_,_) 0029: pop 0030: [box { [:foo] }|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0030: return == returning from fn unbox == 0097: [->box { [:foo] }<-|fn foo!|fn foos!|[:foo]] (_,_,_,_,_,_,_,_) 0097: store 0098: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0098: leaving scope 0 0100: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0100: releasing binding foos!@2//0 0102: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0102: releasing binding foo!@1//0 0104: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0104: releasing binding foos@0//0 0106: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0106: ***leaving block before pop stack depth: 3 0108: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0108: popping back from 3 to 0 0110: [->box { [:foo] }<-|fn foo!|fn foos!] ([:foo],_,_,_,_,_,_,_) 0110: pop_n 003 0112: [] ([:foo],_,_,_,_,_,_,_) 0112: load 0112: [] (_,_,_,_,_,_,_,_) [:foo]