diff --git a/s.c b/s.c index b4b15c5..67d4519 100644 --- a/s.c +++ b/s.c @@ -372,6 +372,31 @@ char *s_code[] = { "A", "cons*", "list*", + "P", "list-diff", + "%2.0u,.0?{.0}{.2,.2q}_1?{n]2}${.3,.3d,@(y9:list-diff)[02},.1ac]2", + + "P", "list-head", + "%2.1,.1,,#0.0,&1{%2.1=0?{n]2}${'1,.4-,.3d,:0^[02},.1ac]2}.!0.0^_1[22", + + "P", "andmap", + "%2.1p?{${.3a,.3[01}?{.1d,.1,@(y6:andmap)[22}f]2}t]2", + + "P", "ormap", + "%2.1p?{${.3a,.3[01},.0?{.0]3}.2d,.2,@(y5:ormap)[32}f]2", + + "P", "memp", + "%2.1p?{${.3a,.3[01}?{.1]2}.1d,.1,@(y4:memp)[22}f]2", + + "P", "assp", + "%2.1p?{${.3aa,.3[01}?{.1a]2}.1d,.1,@(y4:assp)[22}f]2", + + "P", "posq", + "%2'0,.2,,#0.0,.4,&2{%2.0u?{f]2}.0a,:0q?{.1]2}'1,.2I+,.1d,:1^[22}.!0.0^" + "_1[22", + + "P", "rassq", + "%2.1p?{.1a,.0d,.2q?{.0]3}.2d,.2,@(y5:rassq)[32}f]2", + "P", "substring->list", "%3n,'1,.4I-,,#0.3,.1,.6,&3{%2:0,.1I?{'1,.1-,:2S4C1}{f}?{'1,.1-,:0^[11}'0,:3=?{:1,." + "1=}{f}?{:2]1}.0,:3,:2S7]1}.!0.0^_1[21}.!0.0^_1[12", + "P", "subvector->list", "%3n,'1,.4I-,,#0.3,.1,.6,&3{%2:0,.1I?^_~0123" - "456789+-.@),.1S8]1}.!(i12)&0{%1.0X8,'(i48),.1!}{f},.0?{." - "0]3}'(i65),.2!}{f},.0?{.0]4}'(i97),.3!]4}" - "f]4}.!(i13)&0{%1.0C1,.0?{.0]2}'(c)),.2C=,.0?{.0]3}'(c(),.3C=,.0?{.0]4}" - "'(c]),.4C=,.0?{.0]5}'(c[),.5C=,.0?{.0]6}'(c%22),.6C=,.0?{.0]7}'(c;),.7" - "C=]7}.!(i14).(i16),.(i12),&2{%1${.2,:1^[01},.0R8?{.1,'(y5:port:),'(s22" - ":unexpected end of file),@(y10:read-error)[23}${.2,:0^[01}?{.1,'(y5:po" - "rt:),.2d,'(s17:unexpected token:),@(y10:read-error)[24}.0]2}.!(i15).9," - ".(i13),.(i21),.3,.(i26),.(i21),.(i14),.(i24),.(i26),.(i29),.(i24),.(i1" - "4),.(i27),.(i15),.(i15),.(i39),&(i16){%1.0R0,.0R8?{.0]2}.0C1?{.1,:(i10" - ")^[21}'(c(),.1C=?{t,:9^,.3,.3,:8^[24}'(c)),.1C=?{:9^]2}'(c[),.1C=?{t,:" - "(i15)^,.3,.3,:8^[24}'(c]),.1C=?{:(i15)^]2}'(c'),.1C=?{${.3,:3^[01},'(y" - "5:quote),l2]2}'(c`),.1C=?{${.3,:3^[01},'(y10:quasiquote),l2]2}${.2,:(i" - "14)^[01}?{.1,.1,:(i11)^[22}'(c;),.1C=?{${.3R0,,#0.5,.1,&2{%1.0R8,.0?{." - "0]2}'(c%0a),.2C=,.0?{.0]3}:1R0,:0^[31}.!0.0^_1[01}.1,:(i10)^[21}'(c,)," - ".1C=?{.1R1,.0R8?{.2,'(y5:port:),'(s19:end of file after ,),@(y10:read-" - "error)[33}'(c@),.1C=?{.2R0${.4,:3^[01},'(y16:unquote-splicing),l2]3}${" - ".4,:3^[01},'(y7:unquote),l2]3}'(c%22),.1C=?{n,,#0.3,:(i13),.2,&3{%1:2R" - "0,.0R8?{:2,'(y5:port:),'(s27:end of file within a string),@(y10:read-e" - "rror)[23}'(c%5c),.1C=?{${'(y6:string),:2,:1^[02},.0?{.2,.1c}{.2},:0^[3" - "1}'(c%22),.1C=?{.1A9X3]2}.1,.1c,:0^[21}.!0.0^_1[21}'(c|),.1C=?{n,,#0.3" - ",:(i13),.2,&3{%1:2R0,.0R8?{:2,'(y5:port:),'(s29:end of file within a |" - "symbol|),@(y10:read-error)[23}'(c%5c),.1C=?{${'(y6:symbol),:2,:1^[02}," - ".0?{.2,.1c}{.2},:0^[31}'(c|),.1C=?{.1A9X3X5]2}.1,.1c,:0^[21}.!0.0^_1[2" - "1}'(c#),.1C=?{.1R1,.0R8?{.2,'(y5:port:),'(s19:end of file after #),@(y" - "10:read-error)[33}'(c!),.1C=?{.2R0${.4,:3^[01},.0,'(l2:y9:fold-case;y1" - "2:no-fold-case;),.1A1?{'(y9:fold-case),.2q:!(i12):(i12)^,.5P79.4,:(i10" - ")^[51}.1Y0?{.1Y6]5}.4,'(y5:port:),.3,'(s24:unexpected name after #!),@" - "(y10:read-error)[54}'(ct),.1Ci=,.0?{.0}{'(cf),.2Ci=}_1?{${.4,:3^[01},." - "0,'(l2:y1:t;y4:true;),.1A1?{t]5}'(l2:y1:f;y5:false;),.1A1?{f]5}.4,'(y5" - ":port:),.3,'(s23:unexpected name after #),@(y10:read-error)[54}'(cb),." - "1Ci=,.0?{.0}{'(co),.2Ci=,.0?{.0}{'(cd),.3Ci=,.0?{.0}{'(cx),.4Ci=,.0?{." - "0}{'(ci),.5Ci=,.0?{.0}{'(ce),.6Ci=}_1}_1}_1}_1}_1?{.2,'(c#),:(i11)^[32" - "}'(c&),.1C=?{.2R0${.4,:3^[01}b]3}'(c;),.1C=?{.2R0${.4,:3^[01}.2,:(i10)" - "^[31}'(c|),.1C=?{.2R0${,#0.5,.1,&2{%0:1R0,.0R8?{:1,'(y5:port:),'(s25:e" - "nd of file in #| comment),@(y10:read-error)[13}'(c|),.1C=?{:1R1,.0R8?{" - ":1,'(y5:port:),'(s25:end of file in #| comment),@(y10:read-error)[23}'" - "(c#),.1C=?{:1R0]2}:0^[20}'(c#),.1C=?{:1R1,.0R8?{:1,'(y5:port:),'(s25:e" - "nd of file in #| comment),@(y10:read-error)[23}'(c|),.1C=?{:1R0${:0^[0" - "0}:0^[20}:0^[20}:0^[10}.!0.0^_1[00}.2,:(i10)^[31}'(c(),.1C=?{.2R0${f,:" - "9^,.6,.5,:8^[04}X1]3}'(cu),.1C=?{.2R0'(c8),.3R0q?{'(c(),.3R0q}{f}?{${." - "4,:7^[01}E1]3}.2,'(y5:port:),'(s25:invalid bytevector syntax),@(y10:re" - "ad-error)[33}'(c%5c),.1C=?{.2R0.2R1,.0R8?{.3,'(y5:port:),'(s20:end of " - "file after #%5c),@(y10:read-error)[43}.0,'(cx)C=?{.3R0${.5R1,:5^[01}?{" - ".0]4}f,.4,:6^[42}.0C4?{${.5,:3^[01},'1,.1X4S3=?{.1]5}.0,'(y4:null),.1v" - "?{'0X9]6}'(y5:space),.1v?{'(c )]6}'(y5:alarm),.1v?{'(c%07)]6}'(y9:back" - "space),.1v?{'(c%08)]6}'(y6:delete),.1v?{'(i127)X9]6}'(y6:escape),.1v?{" - "'(i27)X9]6}'(y3:tab),.1v?{'(c%09)]6}'(l2:y7:newline;y8:linefeed;),.1A1" - "?{'(c%0a)]6}'(y4:vtab),.1v?{'(c%0b)]6}'(y4:page),.1v?{'(c%0c)]6}'(y6:r" - "eturn),.1v?{'(c%0d)]6}.5,'(y5:port:),.3,'(s15:unknown #%5c name),@(y10" - ":read-error)[64}.3R0.0]4}.0C5?{:0?{${.4,'(y5:port:),'(s44:#N=/#N# nota" - "tion is not allowed in this mode),@(y10:read-error)[03}}n,,#0.4,.1,:4," - ":3,:2,:1,&6{%1:5R0,.0R8?{:5,'(y5:port:),'(s32:end of file within a #N " - "notation),@(y10:read-error)[23}.0C5?{.1,.1c,:4^[21}'(c#),.1C=?{.1A9X3," - "'(i10),.1E9,.0I0?{:0^,.1A3}{f},.0?{.0d]5}'(s22:unknown #n# reference:)" - ",'(y5:port:),.4,@(y10:read-error)[53}'(c=),.1C=?{.1A9X3,'(i10),.1E9,.0" - "I0~?{${'(s22:invalid #n= reference:),'(y5:port:),.5,@(y10:read-error)[" - "03}}{:0^,.1A3?{${'(s18:duplicate #n= tag:),'(y5:port:),.4,@(y10:read-e" - "rror)[03}}{f}}fb,:0^,${.3,:1^[01},.3cc:!0${:5,:2^[01},${.2,:3^[01}?{'(" - "s31:#n= has another label as target),'(y5:port:),.5,@(y10:read-error)[" - "63}.0,.2sz.0]6}:5,'(y5:port:),'(s34:invalid terminator for #N notation" - "),@(y10:read-error)[23}.!0.0^_1[31}.2,'(y5:port:),.2,'(s16:unknown # s" - "yntax),@(y10:read-error)[34}.1,'(y5:port:),.2,'(s22:illegal character " - "read),@(y10:read-error)[24}.!(i16).(i16),.(i12),.(i17),.(i13),&4{%4${." - "3,:3^[01},:0^,.1q?{.2,'(y5:port:),'(s42:missing car -- ( immediately f" - "ollowed by .),@(y10:read-error)[53}.0,,#0.0,.5,:3,:2,.(i10),:1,.(i11)," - ":0,&8{%1.0R8?{:6,'(y5:port:),'(s41:eof inside list -- unbalanced paren" - "theses),@(y10:read-error)[13}:1,.1q?{n]1}:0^,.1q?{:3?{${:6,:2^[01},${:" - "6,:5^[01},:1,.1q?{.1]3}:6,'(y5:port:),.2,'(s31:randomness after form a" - "fter dot),@(y10:read-error)[34}:6,'(y5:port:),'(s13:dot in #(...)),@(y" - "10:read-error)[13}${.2,:4^[01}?{:6,'(y5:port:),.2d,'(s20:error inside " - "list --),@(y10:read-error)[14}${${:6,:5^[01},:7^[01},.1c]1}.!0.0^_1[51" - "}.!(i17).(i16),.9,.(i13),&3{%1${.2,:2^[01},,#0.0,.3,:2,:0,:1,&5{%1.0R8" - "?{:3,'(y5:port:),'(s21:eof inside bytevector),@(y10:read-error)[13}:0^" - ",.1q?{n]1}${.2,:1^[01}?{:3,'(y5:port:),.2d,'(s26:error inside bytevect" - "or --),@(y10:read-error)[14}.0I0~,.0?{.0}{'0,.2I<,.0?{.0}{'(i255),.3I>" - "}_1}_1?{:3,'(y5:port:),.2,'(s33:invalid byte inside bytevector --),@(y" - "10:read-error)[14}${${:3,:2^[01},:4^[01},.1c]1}.!0.0^_1[11}.!(i18).(i2" - "0),&1{%2.0R0,.0R8?{${.3,'(y5:port:),.6,'(s20:end of file within a),@(y" - "10:read-error)[04}}'(c%5c),.1C=,.0?{.0}{'(c%22),.2C=,.0?{.0}{'(c|),.3C" - "=}_1}_1?{.0]3}'(ca),.1C=?{'(c%07)]3}'(cb),.1C=?{'(c%08)]3}'(ct),.1C=?{" - "'(c%09)]3}'(cn),.1C=?{'(c%0a)]3}'(cv),.1C=?{'(c%0b)]3}'(cf),.1C=?{'(c%" - "0c)]3}'(cr),.1C=?{'(c%0d)]3}'(cx),.1C=?{t,.2,:0^[32}'(y6:string),.3q?{" - ".0C1}{f}?{.1R1,'(c%0a),.2C=,,#0.0,.5,&2{%2.1R8,.0?{.0}{.2C1~}_1?{.0?{f" - "]2}:0,'(y5:port:),'(s32:no newline in line ending escape),@(y10:read-e" - "rror)[23}.0?{'(c%0a),.2C=}{f}?{f]2}:0R0:0R1,.1,.0?{.0}{'(c%0a),.4C=}_1" - ",:1^[22}.!0.0^_1[32}.1,'(y5:port:),.2,'(y1::),.6,'(s22:invalid char es" - "cape in),@(y10:read-error)[36}.!(i19).(i14),.(i14),&2{%2,#0.1,&1{%1.0u" - "?{:0,'(y5:port:),'(s31:%5cx escape sequence is too short),@(y10:read-e" - "rror)[13}'(i16),.1A9X3X7X9]1}.!0'0,n,.3R1,,#0.0,.6,:0,.7,.(i10),:1,&6{" - "%3.0R8?{:1?{:4,'(y5:port:),'(s27:end of file within a string),@(y10:re" - "ad-error)[33}.1,:2^[31}:1?{'(c;),.1C=}{f}?{:4R0.1,:2^[31}:1~?{${.2,:0^" - "[01}}{f}?{.1,:2^[31}${.2,:3^[01}~?{:4,'(y5:port:),.2,'(s37:unexpected " - "char in %5cx escape sequence),@(y10:read-error)[34}'2,.3>?{:4,'(y5:por" - "t:),'(s30:%5cx escape sequence is too long),@(y10:read-error)[33}:4R0'" - "1,.3+,.2,.2c,:4R1,:5^[33}.!0.0^_1[33}.!(i20)&0{%4.0,.0?{.0}{.2C5}_1?{f" - "]4}'(s2:+i),.4Si=,.0?{.0}{'(s2:-i),.5Si=}_1?{f]4}'(s6:+nan.0),.4Si=,.0" - "?{.0}{'(s6:-nan.0),.5Si=}_1?{f]4}'(s6:+inf.0),.4Si=,.0?{.0}{'(s6:-inf." - "0),.5Si=}_1?{f]4}'(c+),.2C=,.0?{.0}{'(c-),.3C=}_1?{.2du?{t]4}'(c.),.3d" - "aC=?{.2ddp?{.2ddaC5~]4}f]4}.2daC5~]4}'(c.),.2C=?{.2dp?{.2daC5~]4}f]4}f" - "]4}.!(i21).(i14),.(i22),.(i12),.3,.(i16),&5{%2'(c#),.1C=,.1,l1,.3R1,,#" - "0.5,.1,:0,:1,:2,:3,:4,&7{%3.0R8,.0?{.0}{${.3,:0^[01}}_1?{.1A9,.0a,.1X3" - ",.5,.0?{.0}{.2C5,.0?{.0}{'(c+),.4C=,.0?{.0}{'(c-),.5C=,.0?{.0}{'(c.),." - "6C=}_1}_1}_1}_1?{'(s1:.),.1S=?{:2^]6}${.2,.5,.5,.(i10),:1^[04}?{:3^?{." - "0SfX5]6}.0X5]6}'(i10),.1E9,.0?{.0]7}:6,'(y5:port:),.3,'(s54:unsupporte" - "d number syntax (implementation restriction)),@(y10:read-error)[74}:3^" - "?{.0SfX5]6}.0X5]6}'(c#),.1C=?{:6R0t,.2,.2c,:6R1,:5^[33}${.2,:4^[01}?{:" - "6R0.2,.2,.2c,:6R1,:5^[33}:6,'(y5:port:),.2,'(s29:unexpected number/sym" - "bol char),@(y10:read-error)[34}.!0.0^_1[23}.!(i22)${.(i25),.(i19)^[01}" - ",${.2,.(i15)^[01}~?{.2^u?{.0](i26)}.0,.8^[(i26)1}.(i24),'(y5:port:),.2" - "d,'(s17:unexpected token:),@(y10:read-error)[(i26)4", + "%2,,,,,,,,,,,,,,,,,,,,,,,,#0#1#2#3#4#5#6#7#8#9#(i10)#(i11)#(i12)#(i13)" + "#(i14)#(i15)#(i16)#(i17)#(i18)#(i19)#(i20)#(i21)#(i22)#(i23).(i24)P78." + "!0n.!1&0{%1.0,&1{%0:0z]0}]1}.!2&0{%1.0K0]1}.!3.4,&1{%1.0K0?{${.2[00},:" + "0^[11}.0]1}.!4.5,.5,&2{%1.0p?{.0aK0?{${.2a,:0^[01},.1sa}{${.2a,:1^[01}" + "}.0dK0?{${.2d,:0^[01},.1sd]1}.0d,:1^[11}.0V0?{'0,,#0.2,:0,:1,.3,&4{%1:" + "3V3,.1I?" + "^_~0123456789+-.@),.1S8]1}.!(i12)&0{%1.0X8,'(i48),.1!}{f" + "},.0?{.0]3}'(i65),.2!}{f},.0?{.0]4}'(i97),.3!]4}f]4}.!(i13)&0{%1.0C1,.0?{.0]2}'(c)),.2C=,.0?{.0]3}'(c(),.3C=,.0" + "?{.0]4}'(c]),.4C=,.0?{.0]5}'(c[),.5C=,.0?{.0]6}'(c%22),.6C=,.0?{.0]7}'" + "(c;),.7C=]7}.!(i14).(i17),.(i12),&2{%1${.2,:1^[01},.0R8?{.1,'(y5:port:" + "),'(s22:unexpected end of file),@(y10:read-error)[23}${.2,:0^[01}?{.1," + "'(y5:port:),.2d,'(s17:unexpected token:),@(y10:read-error)[24}.0]2}.!(" + "i15).(i15),&1{%1'(c ),.1R1v?{${${.4,@(y9:read-line)[01},@(y22:string-t" + "rim-whitespace)[01}X5]1}.0,:0^[11}.!(i16).9,.(i13),.(i22),.3,.(i20),.(" + "i28),.(i23),.(i15),.(i26),.(i28),.(i31),.(i25),.(i15),.(i28),.(i16),.(" + "i16),.(i41),&(i17){%1.0R0,.0R8?{.0]2}.0C1?{.1,:(i10)^[21}'(c(),.1C=?{t" + ",:9^,.3,.3,:8^[24}'(c)),.1C=?{:9^]2}'(c[),.1C=?{t,:(i16)^,.3,.3,:8^[24" + "}'(c]),.1C=?{:(i16)^]2}'(c'),.1C=?{${.3,:3^[01},'(y5:quote),l2]2}'(c`)" + ",.1C=?{${.3,:3^[01},'(y10:quasiquote),l2]2}${.2,:(i15)^[01}?{.1,.1,:(i" + "11)^[22}'(c;),.1C=?{${.3R0,,#0.5,.1,&2{%1.0R8,.0?{.0]2}'(c%0a),.2C=,.0" + "?{.0]3}:1R0,:0^[31}.!0.0^_1[01}.1,:(i10)^[21}'(c,),.1C=?{.1R1,.0R8?{.2" + ",'(y5:port:),'(s19:end of file after ,),@(y10:read-error)[33}'(c@),.1C" + "=?{.2R0${.4,:3^[01},'(y16:unquote-splicing),l2]3}${.4,:3^[01},'(y7:unq" + "uote),l2]3}'(c%22),.1C=?{n,,#0.3,:(i14),.2,&3{%1:2R0,.0R8?{:2,'(y5:por" + "t:),'(s27:end of file within a string),@(y10:read-error)[23}'(c%5c),.1" + "C=?{${'(y6:string),:2,:1^[02},.0?{.2,.1c}{.2},:0^[31}'(c%22),.1C=?{.1A" + "9X3]2}.1,.1c,:0^[21}.!0.0^_1[21}'(c|),.1C=?{n,,#0.3,:(i14),.2,&3{%1:2R" + "0,.0R8?{:2,'(y5:port:),'(s29:end of file within a |symbol|),@(y10:read" + "-error)[23}'(c%5c),.1C=?{${'(y6:symbol),:2,:1^[02},.0?{.2,.1c}{.2},:0^" + "[31}'(c|),.1C=?{.1A9X3X5]2}.1,.1c,:0^[21}.!0.0^_1[21}'(c#),.1C=?{.1R1," + ".0R8?{.2,'(y5:port:),'(s19:end of file after #),@(y10:read-error)[33}'" + "(c!),.1C=?{.2R0${.4,:(i12)^[01},.0,'(l2:y9:fold-case;y12:no-fold-case;" + "),.1A1?{'(y9:fold-case),.2q:!(i13):(i13)^,.5P79.4,:(i10)^[51}.1Y0?{.1Y" + "6]5}.4,'(y5:port:),.3,'(s24:unexpected name after #!),@(y10:read-error" + ")[54}'(ct),.1Ci=,.0?{.0}{'(cf),.2Ci=}_1?{${.4,:3^[01},.0,'(l2:y1:t;y4:" + "true;),.1A1?{t]5}'(l2:y1:f;y5:false;),.1A1?{f]5}.4,'(y5:port:),.3,'(s2" + "3:unexpected name after #),@(y10:read-error)[54}'(cb),.1Ci=,.0?{.0}{'(" + "co),.2Ci=,.0?{.0}{'(cd),.3Ci=,.0?{.0}{'(cx),.4Ci=,.0?{.0}{'(ci),.5Ci=," + ".0?{.0}{'(ce),.6Ci=}_1}_1}_1}_1}_1?{.2,'(c#),:(i11)^[32}'(c&),.1C=?{.2" + "R0${.4,:3^[01}b]3}'(c;),.1C=?{.2R0${.4,:3^[01}.2,:(i10)^[31}'(c|),.1C=" + "?{.2R0${,#0.5,.1,&2{%0:1R0,.0R8?{:1,'(y5:port:),'(s25:end of file in #" + "| comment),@(y10:read-error)[13}'(c|),.1C=?{:1R1,.0R8?{:1,'(y5:port:)," + "'(s25:end of file in #| comment),@(y10:read-error)[23}'(c#),.1C=?{:1R0" + "]2}:0^[20}'(c#),.1C=?{:1R1,.0R8?{:1,'(y5:port:),'(s25:end of file in #" + "| comment),@(y10:read-error)[23}'(c|),.1C=?{:1R0${:0^[00}:0^[20}:0^[20" + "}:0^[10}.!0.0^_1[00}.2,:(i10)^[31}'(c(),.1C=?{.2R0${f,:9^,.6,.5,:8^[04" + "}X1]3}'(cu),.1C=?{.2R0'(c8),.3R0q?{'(c(),.3R0q}{f}?{${.4,:7^[01}E1]3}." + "2,'(y5:port:),'(s25:invalid bytevector syntax),@(y10:read-error)[33}'(" + "c%5c),.1C=?{.2R0.2R1,.0R8?{.3,'(y5:port:),'(s20:end of file after #%5c" + "),@(y10:read-error)[43}.0,'(cx)C=?{.3R0${.5R1,:5^[01}?{.0]4}f,.4,:6^[4" + "2}.0C4?{${.5,:3^[01},'1,.1X4S3=?{.1]5}.0,'(y4:null),.1v?{'0X9]6}'(y5:s" + "pace),.1v?{'(c )]6}'(y5:alarm),.1v?{'(c%07)]6}'(y9:backspace),.1v?{'(c" + "%08)]6}'(y6:delete),.1v?{'(i127)X9]6}'(y6:escape),.1v?{'(i27)X9]6}'(y3" + ":tab),.1v?{'(c%09)]6}'(l2:y7:newline;y8:linefeed;),.1A1?{'(c%0a)]6}'(y" + "4:vtab),.1v?{'(c%0b)]6}'(y4:page),.1v?{'(c%0c)]6}'(y6:return),.1v?{'(c" + "%0d)]6}.5,'(y5:port:),.3,'(s15:unknown #%5c name),@(y10:read-error)[64" + "}.3R0.0]4}.0C5?{:0?{${.4,'(y5:port:),'(s44:#N=/#N# notation is not all" + "owed in this mode),@(y10:read-error)[03}}n,,#0.4,.1,:4,:3,:2,:1,&6{%1:" + "5R0,.0R8?{:5,'(y5:port:),'(s32:end of file within a #N notation),@(y10" + ":read-error)[23}.0C5?{.1,.1c,:4^[21}'(c#),.1C=?{.1A9X3,'(i10),.1E9,.0I" + "0?{:0^,.1A3}{f},.0?{.0d]5}'(s22:unknown #n# reference:),'(y5:port:),.4" + ",@(y10:read-error)[53}'(c=),.1C=?{.1A9X3,'(i10),.1E9,.0I0~?{${'(s22:in" + "valid #n= reference:),'(y5:port:),.5,@(y10:read-error)[03}}{:0^,.1A3?{" + "${'(s18:duplicate #n= tag:),'(y5:port:),.4,@(y10:read-error)[03}}{f}}f" + "b,:0^,${.3,:1^[01},.3cc:!0${:5,:2^[01},${.2,:3^[01}?{'(s31:#n= has ano" + "ther label as target),'(y5:port:),.5,@(y10:read-error)[63}.0,.2sz.0]6}" + ":5,'(y5:port:),'(s34:invalid terminator for #N notation),@(y10:read-er" + "ror)[23}.!0.0^_1[31}.2,'(y5:port:),.2,'(s16:unknown # syntax),@(y10:re" + "ad-error)[34}.1,'(y5:port:),.2,'(s22:illegal character read),@(y10:rea" + "d-error)[24}.!(i17).(i17),.(i12),.(i17),.(i13),&4{%4${.3,:3^[01},:0^,." + "1q?{.2,'(y5:port:),'(s42:missing car -- ( immediately followed by .),@" + "(y10:read-error)[53}.0,,#0.0,.5,:3,:2,.(i10),:1,.(i11),:0,&8{%1.0R8?{:" + "6,'(y5:port:),'(s41:eof inside list -- unbalanced parentheses),@(y10:r" + "ead-error)[13}:1,.1q?{n]1}:0^,.1q?{:3?{${:6,:2^[01},${:6,:5^[01},:1,.1" + "q?{.1]3}:6,'(y5:port:),.2,'(s31:randomness after form after dot),@(y10" + ":read-error)[34}:6,'(y5:port:),'(s13:dot in #(...)),@(y10:read-error)[" + "13}${.2,:4^[01}?{:6,'(y5:port:),.2d,'(s20:error inside list --),@(y10:" + "read-error)[14}${${:6,:5^[01},:7^[01},.1c]1}.!0.0^_1[51}.!(i18).(i17)," + ".9,.(i13),&3{%1${.2,:2^[01},,#0.0,.3,:2,:0,:1,&5{%1.0R8?{:3,'(y5:port:" + "),'(s21:eof inside bytevector),@(y10:read-error)[13}:0^,.1q?{n]1}${.2," + ":1^[01}?{:3,'(y5:port:),.2d,'(s26:error inside bytevector --),@(y10:re" + "ad-error)[14}.0I0~,.0?{.0}{'0,.2I<,.0?{.0}{'(i255),.3I>}_1}_1?{:3,'(y5" + ":port:),.2,'(s33:invalid byte inside bytevector --),@(y10:read-error)[" + "14}${${:3,:2^[01},:4^[01},.1c]1}.!0.0^_1[11}.!(i19).(i21),&1{%2.0R0,.0" + "R8?{${.3,'(y5:port:),.6,'(s20:end of file within a),@(y10:read-error)[" + "04}}'(c%5c),.1C=,.0?{.0}{'(c%22),.2C=,.0?{.0}{'(c|),.3C=}_1}_1?{.0]3}'" + "(ca),.1C=?{'(c%07)]3}'(cb),.1C=?{'(c%08)]3}'(ct),.1C=?{'(c%09)]3}'(cn)" + ",.1C=?{'(c%0a)]3}'(cv),.1C=?{'(c%0b)]3}'(cf),.1C=?{'(c%0c)]3}'(cr),.1C" + "=?{'(c%0d)]3}'(cx),.1C=?{t,.2,:0^[32}'(y6:string),.3q?{.0C1}{f}?{.1R1," + "'(c%0a),.2C=,,#0.0,.5,&2{%2.1R8,.0?{.0}{.2C1~}_1?{.0?{f]2}:0,'(y5:port" + ":),'(s32:no newline in line ending escape),@(y10:read-error)[23}.0?{'(" + "c%0a),.2C=}{f}?{f]2}:0R0:0R1,.1,.0?{.0}{'(c%0a),.4C=}_1,:1^[22}.!0.0^_" + "1[32}.1,'(y5:port:),.2,'(y1::),.6,'(s22:invalid char escape in),@(y10:" + "read-error)[36}.!(i20).(i14),.(i14),&2{%2,#0.1,&1{%1.0u?{:0,'(y5:port:" + "),'(s31:%5cx escape sequence is too short),@(y10:read-error)[13}'(i16)" + ",.1A9X3X7X9]1}.!0'0,n,.3R1,,#0.0,.6,:0,.7,.(i10),:1,&6{%3.0R8?{:1?{:4," + "'(y5:port:),'(s27:end of file within a string),@(y10:read-error)[33}.1" + ",:2^[31}:1?{'(c;),.1C=}{f}?{:4R0.1,:2^[31}:1~?{${.2,:0^[01}}{f}?{.1,:2" + "^[31}${.2,:3^[01}~?{:4,'(y5:port:),.2,'(s37:unexpected char in %5cx es" + "cape sequence),@(y10:read-error)[34}'2,.3>?{:4,'(y5:port:),'(s30:%5cx " + "escape sequence is too long),@(y10:read-error)[33}:4R0'1,.3+,.2,.2c,:4" + "R1,:5^[33}.!0.0^_1[33}.!(i21)&0{%4.0,.0?{.0}{.2C5}_1?{f]4}'(s2:+i),.4S" + "i=,.0?{.0}{'(s2:-i),.5Si=}_1?{f]4}'(s6:+nan.0),.4Si=,.0?{.0}{'(s6:-nan" + ".0),.5Si=}_1?{f]4}'(s6:+inf.0),.4Si=,.0?{.0}{'(s6:-inf.0),.5Si=}_1?{f]" + "4}'(c+),.2C=,.0?{.0}{'(c-),.3C=}_1?{.2du?{t]4}'(c.),.3daC=?{.2ddp?{.2d" + "daC5~]4}f]4}.2daC5~]4}'(c.),.2C=?{.2dp?{.2daC5~]4}f]4}f]4}.!(i22).(i14" + "),.(i23),.(i12),.3,.(i16),&5{%2'(c#),.1C=,.1,l1,.3R1,,#0.5,.1,:0,:1,:2" + ",:3,:4,&7{%3.0R8,.0?{.0}{${.3,:0^[01}}_1?{.1A9,.0a,.1X3,.5,.0?{.0}{.2C" + "5,.0?{.0}{'(c+),.4C=,.0?{.0}{'(c-),.5C=,.0?{.0}{'(c.),.6C=}_1}_1}_1}_1" + "?{'(s1:.),.1S=?{:2^]6}${.2,.5,.5,.(i10),:1^[04}?{:3^?{.0SfX5]6}.0X5]6}" + "'(i10),.1E9,.0?{.0]7}:6,'(y5:port:),.3,'(s54:unsupported number syntax" + " (implementation restriction)),@(y10:read-error)[74}:3^?{.0SfX5]6}.0X5" + "]6}'(c#),.1C=?{:6R0t,.2,.2c,:6R1,:5^[33}${.2,:4^[01}?{:6R0.2,.2,.2c,:6" + "R1,:5^[33}:6,'(y5:port:),.2,'(s29:unexpected number/symbol char),@(y10" + ":read-error)[34}.!0.0^_1[23}.!(i23)${.(i26),.(i20)^[01},${.2,.(i15)^[0" + "1}~?{.2^u?{.0](i27)}.0,.8^[(i27)1}.(i25),'(y5:port:),.2d,'(s17:unexpec" + "ted token:),@(y10:read-error)[(i27)4", "C", 0, "&0{%1f,.1,@(y5:%25read)[12}%x,&0{%0f,Pi,@(y5:%25read)[02}%x,&2{|00|11%" diff --git a/src/s.scm b/src/s.scm index adf553b..75753b9 100644 --- a/src/s.scm +++ b/src/s.scm @@ -692,6 +692,40 @@ (define-syntax cons* list*) +(define (list-diff l t) ; + + (if (or (null? l) (eq? l t)) + '() + (cons (car l) (list-diff (cdr l) t)))) + +(define (list-head list index) ; + + (let loop ([list list] [index index]) + (if (zero? index) + '() + (cons (car list) (loop (cdr list) (- index 1)))))) + +(define (andmap p l) ; + + (if (pair? l) (and (p (car l)) (andmap p (cdr l))) #t)) + +(define (ormap p l) ; + + (if (pair? l) (or (p (car l)) (ormap p (cdr l))) #f)) + +(define (memp p l) ; + + (and (pair? l) (if (p (car l)) l (memp p (cdr l))))) + +(define (assp p l) ; + + (and (pair? l) (if (p (caar l)) (car l) (assp p (cdr l))))) + +(define (posq x l) ; + + (let loop ([l l] [n 0]) + (cond [(null? l) #f] + [(eq? x (car l)) n] + [else (loop (cdr l) (fx+ n 1))]))) + +(define (rassq x al) ; + + (and (pair? al) + (let ([a (car al)]) + (if (eq? x (cdr a)) a (rassq x (cdr al)))))) + ;--------------------------------------------------------------------------------------------- ; Symbols @@ -855,6 +889,17 @@ [(_ . r) (%string-append . r)] [_ %string-append])) +(define (string-trim-whitespace s) ; + + (let floop ([from 0] [len (string-length s)]) + (if (and (< from len) (char-whitespace? (string-ref s from))) + (floop (+ from 1) len) + (let tloop ([to len]) + (if (and (> to from) (char-whitespace? (string-ref s (- to 1)))) + (tloop (- to 1)) + (if (and (= from 0) (= to len)) + s + (substring s from to))))))) + ;--------------------------------------------------------------------------------------------- ; Vectors @@ -1609,6 +1654,11 @@ (r-error p "unexpected token:" (cdr form))] [else form]))) + (define (sub-read-shebang p) + (if (eqv? (peek-char p) #\space) + (string->symbol (string-trim-whitespace (read-line p))) + (sub-read-carefully p))) + (define (sub-read p) (let ([c (read-char p)]) (cond [(eof-object? c) c] @@ -1658,7 +1708,7 @@ (cond [(eof-object? c) (r-error p "end of file after #")] [(char=? c #\!) (read-char p) - (let ([name (sub-read-carefully p)]) + (let ([name (sub-read-shebang p)]) (case name [(fold-case no-fold-case) (set! fold-case? (eq? name 'fold-case)) diff --git a/src/t.scm b/src/t.scm index f1f915f..c892e64 100644 --- a/src/t.scm +++ b/src/t.scm @@ -120,17 +120,6 @@ (string-append (symbol->string (car args)) (string-append "#" (fixnum->string gsc 10)))))))) -(define (posq x l) - (let loop ([l l] [n 0]) - (cond [(null? l) #f] - [(eq? x (car l)) n] - [else (loop (cdr l) (fx+ n 1))]))) - -(define (rassq x al) - (and (pair? al) - (let ([a (car al)]) - (if (eq? x (cdr a)) a (rassq x (cdr al)))))) - (define (remove! x l pred?) ; applies (pred? x (car l)) (let loop ([f #f] [l #f] [r l]) (cond [(not (pair? r)) (if l (begin (set-cdr! l r) f) r)] @@ -138,17 +127,6 @@ [l (set-cdr! l r) (loop f r (cdr r))] [else (loop r r (cdr r))]))) -(define (list-diff l t) - (if (or (null? l) (eq? l t)) - '() - (cons (car l) (list-diff (cdr l) t)))) - -(define (list-head list index) - (let loop ([list list] [index index]) - (if (zero? index) - '() - (cons (car list) (loop (cdr list) (- index 1)))))) - (define (pair* x . more) (let loop ([x x] [r more]) (if (null? r) x (cons x (loop (car r) (cdr r)))))) @@ -161,23 +139,6 @@ (define (string-append* l) (apply string-append l)) -(define (string-trim-whitespace s) - (let floop ([from 0] [len (string-length s)]) - (if (and (< from len) (char-whitespace? (string-ref s from))) - (floop (+ from 1) len) - (let tloop ([to len]) - (if (and (> to from) (char-whitespace? (string-ref s (- to 1)))) - (tloop (- to 1)) - (if (and (= from 0) (= to len)) - s - (substring s from to))))))) - -(define (andmap p l) - (if (pair? l) (and (p (car l)) (andmap p (cdr l))) #t)) - -(define (ormap p l) - (if (pair? l) (or (p (car l)) (ormap p (cdr l))) #f)) - (define (list1? x) (and (pair? x) (null? (cdr x)))) (define (list1+? x) (and (pair? x) (list? (cdr x)))) (define (list2? x) (and (pair? x) (list1? (cdr x)))) @@ -2014,6 +1975,7 @@ (vector-cat) (bytevector=?) (bytevector->list) (list->bytevector) (subbytevector) (standard-input-port) (standard-output-port) (standard-error-port) (tty-port?) (port-fold-case?) (set-port-fold-case!) (rename-file) (void) (void?) (global-store) + (run-script) ; temporarily here for debugging purposes ;(xform) (compile-and-run-core-expr) (compile-to-thunk-code) (deserialize-code) ;(closure) (repl-environment) @@ -2331,6 +2293,33 @@ ; we aren't asked by the spec to call last expr tail-recursively, so this (void)) +; srfi-22 - like script processor (args is list of strings) +(define (run-script filename args) + (define env (interaction-environment)) + (define ci? #f) ; do not bother setting this + (define callmain #f) + (define main-args (cons filename args)) + (let* ([filepath (and (string? filename) (file-resolve-relative-to-current filename))] + [fileok? (and (string? filepath) (file-exists? filepath))]) + (unless fileok? (error "cannot run script" filename filepath)) + (with-current-file filepath + (lambda () + (call-with-input-file filepath + (lambda (port) + (when ci? (set-port-fold-case! port #t)) + (let ([x0 (read-code-sexp port)]) + (when (shebang? x0) ; TODO: set! env depending on x? + (set! callmain #t) + (set! x0 (read-code-sexp port))) + (let loop ([x x0]) + (unless (eof-object? x) + (eval x env) + (loop (read-code-sexp port)))) + (when callmain + ; if it is a real script, exit with main's return value + (eval `(exit (main (quote ,main-args))) env))))))) + (void))) + ;-------------------------------------------------------------------------------------------------- ; REPL diff --git a/t.c b/t.c index b877982..425120b 100644 --- a/t.c +++ b/t.c @@ -67,24 +67,11 @@ char *t_code[] = { "'0,#0.0,&1{%!0'1,:0^I+:!0.0u,.0?{.0}{.1aY0~}_1?{'(i10),:0^X6,'(s1:#)S6" "X5]1}'(i10),:0^X6,'(s1:#)S6,.1aX4S6X5]1}_1@!(y6:gensym)", - "P", "posq", - "%2'0,.2,,#0.0,.4,&2{%2.0u?{f]2}.0a,:0q?{.1]2}'1,.2I+,.1d,:1^[22}.!0.0^" - "_1[22", - - "P", "rassq", - "%2.1p?{.1a,.0d,.2q?{.0]3}.2d,.2,@(y5:rassq)[32}f]2", - "P", "remove!", "%3.1,f,f,,#0.0,.7,.6,&3{%3.2p~?{.1?{.2,.2sd.0]3}.2]3}${.4a,:0,:1[02}?{" ".2d,.2,.2,:2^[33}.1?{.2,.2sd.2d,.3,.2,:2^[33}.2d,.3,.4,:2^[33}.!0.0^_1" "[33", - "P", "list-diff", - "%2.0u,.0?{.0}{.2,.2q}_1?{n]2}${.3,.3d,@(y9:list-diff)[02},.1ac]2", - - "P", "list-head", - "%2.1,.1,,#0.0,&1{%2.1=0?{n]2}${'1,.4-,.3d,:0^[02},.1ac]2}.!0.0^_1[22", - "P", "pair*", "%!1.0,.2,,#0.0,&1{%2.1u?{.0]2}${.3d,.4a,:0^[02},.1c]2}.!0.0^_1[22", @@ -94,17 +81,6 @@ char *t_code[] = { "P", "string-append*", "%1.0,@(y14:%25string-append),@(y13:apply-to-list)[12", - "P", "string-trim-whitespace", - "%1.0S3,'0,,#0.3,.1,&2{%2.1,.1?{'1,.1-,:2S4C1}{f}?{'1,.1-,:0^[11}'0,:3=?{:1,." - "1=}{f}?{:2]1}.0,:3,:2S7]1}.!0.0^_1[21}.!0.0^_1[12", - - "P", "andmap", - "%2.1p?{${.3a,.3[01}?{.1d,.1,@(y6:andmap)[22}f]2}t]2", - - "P", "ormap", - "%2.1p?{${.3a,.3[01},.0?{.0]3}.2d,.2,@(y5:ormap)[32}f]2", - "P", "list1?", "%1.0p?{.0du]1}f]1", @@ -1112,7 +1088,7 @@ char *t_code[] = { "0:*root-name-registry*),@(y11:name-lookup)[03}", "C", 0, - "${'(l482:l3:y1:*;y1:v;y1:b;;l3:y1:+;y1:v;y1:b;;l3:y1:-;y1:v;y1:b;;l4:y" + "${'(l483:l3:y1:*;y1:v;y1:b;;l3:y1:+;y1:v;y1:b;;l3:y1:-;y1:v;y1:b;;l4:y" "3:...;y1:v;y1:u;y1:b;;l3:y1:/;y1:v;y1:b;;l3:y1:<;y1:v;y1:b;;l3:y2:<=;y" "1:v;y1:b;;l3:y1:=;y1:v;y1:b;;l4:y2:=>;y1:v;y1:u;y1:b;;l3:y1:>;y1:v;y1:" "b;;l3:y2:>=;y1:v;y1:b;;l2:y1:_;y1:b;;l3:y3:abs;y1:v;y1:b;;l4:y3:and;y1" @@ -1275,25 +1251,25 @@ char *t_code[] = { ";l1:y13:subbytevector;;l1:y19:standard-input-port;;l1:y20:standard-out" "put-port;;l1:y19:standard-error-port;;l1:y9:tty-port?;;l1:y15:port-fol" "d-case?;;l1:y19:set-port-fold-case!;;l1:y11:rename-file;;l1:y4:void;;l" - "1:y5:void?;;l1:y12:global-store;;),&0{%1,,,,#0#1#2#3&0{%1.0,'(y1:w),.1" - "v?{'(l2:y6:scheme;y5:write;)]2}'(y1:t),.1v?{'(l2:y6:scheme;y4:time;)]2" - "}'(y1:p),.1v?{'(l2:y6:scheme;y4:repl;)]2}'(y1:r),.1v?{'(l2:y6:scheme;y" - "4:read;)]2}'(y1:v),.1v?{'(l2:y6:scheme;y4:r5rs;)]2}'(y1:u),.1v?{'(l2:y" - "6:scheme;y9:r5rs-null;)]2}'(y1:d),.1v?{'(l2:y6:scheme;y4:load;)]2}'(y1" - ":z),.1v?{'(l2:y6:scheme;y4:lazy;)]2}'(y1:s),.1v?{'(l2:y6:scheme;y15:pr" - "ocess-context;)]2}'(y1:i),.1v?{'(l2:y6:scheme;y7:inexact;)]2}'(y1:f),." - "1v?{'(l2:y6:scheme;y4:file;)]2}'(y1:e),.1v?{'(l2:y6:scheme;y4:eval;)]2" - "}'(y1:o),.1v?{'(l2:y6:scheme;y7:complex;)]2}'(y1:h),.1v?{'(l2:y6:schem" - "e;y4:char;)]2}'(y1:l),.1v?{'(l2:y6:scheme;y11:case-lambda;)]2}'(y1:a)," - ".1v?{'(l2:y6:scheme;y3:cxr;)]2}'(y1:b),.1v?{'(l2:y6:scheme;y4:base;)]2" - "}'(y1:x),.1v?{'(l2:y6:scheme;y3:box;)]2}.1I0?{.1,'(y4:srfi),l2]2}.1,l1" - "]2}.!0&0{%1${&0{%1n,'(l1:y5:begin;),V12]1},.3,@(y20:*root-name-registr" - "y*),@(y11:name-lookup)[03}z]1}.!1&0{%3'1,.1V4,.0,.3A3,.0?{.4,.1sd]5}.1" - ",.5,.5cc,'1,.4V5]5}.!2&0{%1&0{%1.0,'(y5:const),l2]1},.1,@(y20:*root-na" - "me-registry*),@(y11:name-lookup)[13}.!3.4d,.5a,,#0.0,.6,.5,.7,.(i10),&" - "5{%2.1u?{${.2,:0^[01},.1,${'(l1:y5:skint;),:1^[01},:3^[23}${${.4,:0^[0" - "1},.3,${${.9a,:2^[01},:1^[01},:3^[03}.1d,.1,:4^[22}.!0.0^_1[52},@(y10:" - "%25for-each1)[02}", + "1:y5:void?;;l1:y12:global-store;;l1:y10:run-script;;),&0{%1,,,,#0#1#2#" + "3&0{%1.0,'(y1:w),.1v?{'(l2:y6:scheme;y5:write;)]2}'(y1:t),.1v?{'(l2:y6" + ":scheme;y4:time;)]2}'(y1:p),.1v?{'(l2:y6:scheme;y4:repl;)]2}'(y1:r),.1" + "v?{'(l2:y6:scheme;y4:read;)]2}'(y1:v),.1v?{'(l2:y6:scheme;y4:r5rs;)]2}" + "'(y1:u),.1v?{'(l2:y6:scheme;y9:r5rs-null;)]2}'(y1:d),.1v?{'(l2:y6:sche" + "me;y4:load;)]2}'(y1:z),.1v?{'(l2:y6:scheme;y4:lazy;)]2}'(y1:s),.1v?{'(" + "l2:y6:scheme;y15:process-context;)]2}'(y1:i),.1v?{'(l2:y6:scheme;y7:in" + "exact;)]2}'(y1:f),.1v?{'(l2:y6:scheme;y4:file;)]2}'(y1:e),.1v?{'(l2:y6" + ":scheme;y4:eval;)]2}'(y1:o),.1v?{'(l2:y6:scheme;y7:complex;)]2}'(y1:h)" + ",.1v?{'(l2:y6:scheme;y4:char;)]2}'(y1:l),.1v?{'(l2:y6:scheme;y11:case-" + "lambda;)]2}'(y1:a),.1v?{'(l2:y6:scheme;y3:cxr;)]2}'(y1:b),.1v?{'(l2:y6" + ":scheme;y4:base;)]2}'(y1:x),.1v?{'(l2:y6:scheme;y3:box;)]2}.1I0?{.1,'(" + "y4:srfi),l2]2}.1,l1]2}.!0&0{%1${&0{%1n,'(l1:y5:begin;),V12]1},.3,@(y20" + ":*root-name-registry*),@(y11:name-lookup)[03}z]1}.!1&0{%3'1,.1V4,.0,.3" + "A3,.0?{.4,.1sd]5}.1,.5,.5cc,'1,.4V5]5}.!2&0{%1&0{%1.0,'(y5:const),l2]1" + "},.1,@(y20:*root-name-registry*),@(y11:name-lookup)[13}.!3.4d,.5a,,#0." + "0,.6,.5,.7,.(i10),&5{%2.1u?{${.2,:0^[01},.1,${'(l1:y5:skint;),:1^[01}," + ":3^[23}${${.4,:0^[01},.3,${${.9a,:2^[01},:1^[01},:3^[03}.1d,.1,:4^[22}" + ".!0.0^_1[52},@(y10:%25for-each1)[02}", "C", 0, "@(y20:*root-name-registry*),${f,'(l1:y5:skint;),.4,@(y11:name-lookup)[" @@ -1461,6 +1437,17 @@ char *t_code[] = { "!0.0^_1[11},:0,@(y20:call-with-input-file)[02},.4,@(y17:with-current-f" "ile)[02}_1_1Y9]4", + "P", "run-script", + "%2,,,,#0#1#2#3${@(y23:interaction-environment)[00}.!0f.!1f.!2.5,.5c.!3" + ".4S0?{${.6,@(y32:file-resolve-relative-to-current)[01}}{f},.0S0?{.0F0}" + "{f},.0~?{${.3,.9,'(s17:cannot run script),@(y5:error)[03}}${.5,.8,.6,." + "9,.7,&5{%0:1,:2,:3,:4,&4{%1:0^?{t,.1P79}${.2,@(y14:read-code-sexp)[01}" + ",#0.0^Y5?{t:!3${.3,@(y14:read-code-sexp)[01}.!0}${.2^,,#0:2,.6,.2,&3{%" + "1.0R8~?{${:2^,.3,@(y4:eval)[02}${:1,@(y14:read-code-sexp)[01},:0^[11}]" + "1}.!0.0^_1[01}:3^?{:2^,n,n,n,:1^c,'(y5:quote)cc,'(y4:main)cc,'(y4:exit" + ")c,@(y4:eval)[22}]2},:0,@(y20:call-with-input-file)[02},.4,@(y17:with-" + "current-file)[02}Y9]8", + "P", "repl-evaluate-top-form", "%3,,#0#1.!0${.2,&1{%!0.0:!0]1},.6,.6,&2{%0:1,:0,@(y17:evaluate-top-for" "m)[02},@(y16:call-with-values)[02}.4,&1{%1:0,.1W5:0W6]1}.!1${.2^,@(y6:"