(CommandList children: [ (C {(source)} { (CommandSubPart command_list: (CommandList children:[(C {(dirname)} {($ VSub_Number '$0')})]) left_token: <Left_CommandSub '$('> spids: [6 10] ) (/reader.sh) } ) (C {(source)} { (CommandSubPart command_list: (CommandList children:[(C {(dirname)} {($ VSub_Number '$0')})]) left_token: <Left_CommandSub '$('> spids: [15 19] ) (/printer.sh) } ) (C {(source)} { (CommandSubPart command_list: (CommandList children:[(C {(dirname)} {($ VSub_Number '$0')})]) left_token: <Left_CommandSub '$('> spids: [24 28] ) (/env.sh) } ) (FuncDef name: READ body: (BraceGroup children: [ (AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(Lit_Other '[')} {(DQ (${ VSub_Number 1))} {(Lit_Other ']')}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(DQ (${ VSub_Number 1))} spids: [55] ) ] spids: [55] ) (C {(READLINE)}) ] ) (C {(READ_STR)} {(DQ (${ VSub_Name r))}) ] spids: [40] ) spids: [35 39] ) (FuncDef name: EVAL_AST body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:ast) op: Equal rhs: {(DQ (${ VSub_Number 1))} spids: [91] ) (assign_pair lhs: (LhsName name:env) op: Equal rhs: {(DQ (${ VSub_Number 2))} spids: [98] ) ] spids: [89] ) (Sentence child: (C {(_obj_type)} {(DQ (${ VSub_Name ast))}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:ot) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [121] ) ] spids: [119] ) (Case to_match: {(DQ (${ VSub_Name ot))} arms: [ (case_arm pat_list: [{(symbol)}] action: [ (C {(ENV_GET)} {(DQ (${ VSub_Name env))} {(DQ (${ VSub_Name ast))}) (ControlFlow token:<ControlFlow_Return return>) ] spids: [140 141 161 16777215] ) (case_arm pat_list: [{(list)}] action: [ (C {(_map_with_type)} {(_list)} {(EVAL)} {(DQ (${ VSub_Name ast))} {(DQ (${ VSub_Name env))} ) ] spids: [164 165 186 16777215] ) (case_arm pat_list: [{(vector)}] action: [ (C {(_map_with_type)} {(_vector)} {(EVAL)} {(DQ (${ VSub_Name ast))} {(DQ (${ VSub_Name env))} ) ] spids: [189 190 211 16777215] ) (case_arm pat_list: [{(hash_map)}] action: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:res) op: Equal rhs: {(DQ )} spids: [220] ) (assign_pair lhs: (LhsName name:key) op: Equal rhs: {(EmptyPart)} spids: [224] ) (assign_pair lhs: (LhsName name:val) op: Equal rhs: {(DQ )} spids: [226] ) (assign_pair lhs: (LhsName name:hm) op: Equal rhs: { (DQ (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr:(ArithWord w:{(DQ (${ VSub_Name ast))})) spids: [232 241] ) ) } spids: [230] ) ] spids: [218] ) (Sentence child:(C {(_hash_map)}) terminator:<Op_Semi ';'>) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:new_hm) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [250] ) ] spids: [248] ) (C {(eval)} {(Assign_Local local)} {(Lit_VarLike 'keys=') (DQ (EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ('{!') (${ VSub_Name hm) ('[@]}') ) } ) (ForEach iter_name: key iter_words: [{(${ VSub_Name keys)}] do_arg_iter: F body: (DoGroup children: [ (C {(eval)} {(Lit_VarLike 'val=') (DQ (EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ('{') (${ VSub_Name hm) ('[') (EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (${ VSub_Name key) (EscapedLiteralPart token: <Lit_EscapedChar '\\"'> ) (']}') ) } ) (C {(EVAL)} {(DQ (${ VSub_Name val))} {(DQ (${ VSub_Name env))}) (C {(_assoc) (KW_Bang '!')} {(DQ (${ VSub_Name new_hm))} {(DQ (${ VSub_Name key))} {(DQ (${ VSub_Name r))} ) ] spids: [284 343] ) spids: [278 282] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(DQ (${ VSub_Name new_hm))} spids: [346] ) ] spids: [346] ) ] spids: [214 215 353 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(DQ (${ VSub_Name ast))} spids: [360] ) ] spids: [360] ) ] spids: [356 357 367 16777215] ) ] spids: [129 137 370] ) ] spids: [86] ) spids: [81 85] ) (FuncDef name: EVAL body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:ast) op: Equal rhs: {(DQ (${ VSub_Number 1))} spids: [385] ) (assign_pair lhs: (LhsName name:env) op: Equal rhs: {(DQ (${ VSub_Number 2))} spids: [392] ) ] spids: [383] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:r) op:Equal rhs:{(EmptyPart)} spids:[400])] spids: [400] ) (AndOr ops: [Op_DAmp] children: [ (DBracket expr:(WordTest w:{(DQ (${ VSub_Name __ERROR))})) (ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] ) (Sentence child: (C {(_obj_type)} {(DQ (${ VSub_Name ast))}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:ot) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [435] ) ] spids: [433] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobNEqual left: {(DQ (${ VSub_Name ot))} right: {(DQ (list))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(EVAL_AST)} {(DQ (${ VSub_Name ast))} {(DQ (${ VSub_Name env))}) (ControlFlow token:<ControlFlow_Return return>) ] spids: [16777215 462] ) ] spids: [16777215 483] ) (AndOr ops: [Op_DAmp Op_DAmp] children: [ (C {(_empty) (Lit_Other '?')} {(DQ (${ VSub_Name ast))}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(DQ (${ VSub_Name ast))} spids: [497] ) ] spids: [497] ) (ControlFlow token:<ControlFlow_Return return>) ] ) (Sentence child: (C {(_nth)} {(DQ (${ VSub_Name ast))} {(0)}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:a0) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [527] ) ] spids: [525] ) (Sentence child: (C {(_nth)} {(DQ (${ VSub_Name ast))} {(1)}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:a1) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [548] ) ] spids: [546] ) (Sentence child: (C {(_nth)} {(DQ (${ VSub_Name ast))} {(2)}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:a2) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [569] ) ] spids: [567] ) (Case to_match: { (DQ (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr:(ArithWord w:{(DQ (${ VSub_Name a0))})) spids: [580 589] ) ) } arms: [ (case_arm pat_list: [{(def) (KW_Bang '!')}] action: [ (C {(EVAL)} {(DQ (${ VSub_Name a2))} {(DQ (${ VSub_Name env))}) (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (WordTest w:{(DQ (${ VSub_Name __ERROR))}) ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) (C {(ENV_SET)} {(DQ (${ VSub_Name env))} {(DQ (${ VSub_Name a1))} {(DQ (${ VSub_Name r))} ) (ControlFlow token:<ControlFlow_Return return>) ] spids: [595 597 654 16777215] ) (case_arm pat_list: [{(let) (Lit_Other '*')}] action: [ (Sentence child: (C {(ENV)} {(DQ (${ VSub_Name env))}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:let_env) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [672] ) ] spids: [670] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:let_pairs) op: Equal rhs: { (ArrayLiteralPart words: [ { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Name a1))}) ) spids: [684 693] ) } ] ) } spids: [682] ) ] spids: [680] ) (Assignment keyword: Assign_Local pairs: [(assign_pair lhs:(LhsName name:idx) op:Equal rhs:{(0)} spids:[699])] spids: [697] ) (While cond: [ (Sentence child: (DBracket expr: (WordTest w: { (DQ (BracedVarSub token: <VSub_Name let_pairs> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Name idx))}) ) spids: [712 721] ) ) } ) ) terminator: <Op_Semi ';'> ) ] body: (DoGroup children: [ (C {(EVAL)} { (DQ (BracedVarSub token: <VSub_Name let_pairs> bracket_op: (ArrayIndex expr: (ArithWord w: { (ArithSubPart anode: (ArithBinary op_id: Arith_Plus left: (ArithVarRef name:idx) right: (ArithWord w:{(Lit_Digits 1)}) ) spids: [736 744] ) } ) ) spids: [733 746] ) ) } {(DQ (${ VSub_Name let_env))} ) (C {(ENV_SET)} {(DQ (${ VSub_Name let_env))} { (DQ (BracedVarSub token: <VSub_Name let_pairs> bracket_op: (ArrayIndex expr:(ArithWord w:{(${ VSub_Name idx)})) spids: [765 772] ) ) } {(DQ (${ VSub_Name r))} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:idx) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Plus left: (ArithVarRef name:idx) right: (ArithWord w:{(Lit_Digits 2)}) ) spids: [783 791] ) } spids: [782] ) ] spids: [782] ) ] spids: [727 794] ) ) (C {(EVAL)} {(DQ (${ VSub_Name a2))} {(DQ (${ VSub_Name let_env))}) (ControlFlow token:<ControlFlow_Return return>) ] spids: [657 659 814 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (C {(EVAL_AST)} {(DQ (${ VSub_Name ast))} {(DQ (${ VSub_Name env))}) (AndOr ops: [Op_DAmp Op_DAmp] children: [ (DBracket expr: (WordTest w:{(DQ (${ VSub_Name __ERROR))}) ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(EmptyPart)} spids: [847] ) ] spids: [847] ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:el) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [858] ) ] spids: [856] ) (Sentence child: (C {(_first)} {(DQ (${ VSub_Name el))}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:f) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [877] ) ] spids: [875] ) (Sentence child: (C {(_rest)} {(DQ (${ VSub_Name el))}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:args) op: Equal rhs: { (DQ (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr:(ArithWord w:{(DQ (${ VSub_Name r))})) spids: [898 907] ) ) } spids: [896] ) ] spids: [894] ) (C {(eval)} {(${ VSub_Name f)} {(${ VSub_Name args)}) (ControlFlow token:<ControlFlow_Return return>) ] spids: [817 818 928 16777215] ) ] spids: [577 592 931] ) ] spids: [380] ) spids: [375 379] ) (FuncDef name: PRINT body: (BraceGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr:(WordTest w:{(DQ (${ VSub_Name __ERROR))})) terminator: <Op_Semi ';'> ) ] action: [ (C {(_pr_str)} {(DQ (${ VSub_Name __ERROR))} {(yes)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: {(DQ ('Error: ') (${ VSub_Name r))} spids: [974] ) ] spids: [974] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:__ERROR) op: Equal rhs: {(EmptyPart)} spids: [983] ) ] spids: [983] ) ] spids: [16777215 960] ) ] else_action: [(C {(_pr_str)} {(DQ (${ VSub_Number 1))} {(yes)})] spids: [986 1000] ) ] spids: [944] ) spids: [939 943] ) (Sentence child:(C {(ENV)}) terminator:<Op_Semi ';'>) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:REPL_ENV) op: Equal rhs: {(DQ (${ VSub_Name r))} spids: [1011] ) ] spids: [1011] ) (FuncDef name: REP body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:r) op:Equal rhs:{(EmptyPart)} spids:[1026])] spids: [1026] ) (C {(READ)} {(DQ (${ VSub_Number 1))}) (C {(EVAL)} {(DQ (${ VSub_Name r))} {(DQ (${ VSub_Name REPL_ENV))}) (C {(PRINT)} {(DQ (${ VSub_Name r))}) ] spids: [1023] ) spids: [1018 1022] ) (FuncDef name: plus body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Plus left: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 1))}) ) spids: [1074 1083] ) } ) right: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 2))}) ) spids: [1087 1096] ) } ) ) spids: [1072 1099] ) } spids: [1071] ) ] spids: [1071] ) terminator: <Op_Semi ';'> ) (Sentence child: (C {(_number)} {(DQ (${ VSub_Name r))}) terminator: <Op_Semi ';'> ) ] spids: [1069] ) spids: [1064 1068] ) (FuncDef name: minus body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Minus left: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 1))}) ) spids: [1123 1132] ) } ) right: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 2))}) ) spids: [1136 1145] ) } ) ) spids: [1121 1148] ) } spids: [1120] ) ] spids: [1120] ) terminator: <Op_Semi ';'> ) (Sentence child: (C {(_number)} {(DQ (${ VSub_Name r))}) terminator: <Op_Semi ';'> ) ] spids: [1118] ) spids: [1113 1117] ) (FuncDef name: multiply body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Star left: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 1))}) ) spids: [1172 1181] ) } ) right: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 2))}) ) spids: [1185 1194] ) } ) ) spids: [1170 1197] ) } spids: [1169] ) ] spids: [1169] ) terminator: <Op_Semi ';'> ) (Sentence child: (C {(_number)} {(DQ (${ VSub_Name r))}) terminator: <Op_Semi ';'> ) ] spids: [1167] ) spids: [1162 1166] ) (FuncDef name: divide body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:r) op: Equal rhs: { (ArithSubPart anode: (ArithBinary op_id: Arith_Slash left: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 1))}) ) spids: [1221 1230] ) } ) right: (ArithWord w: { (BracedVarSub token: <VSub_Name ANON> bracket_op: (ArrayIndex expr: (ArithWord w:{(DQ (${ VSub_Number 2))}) ) spids: [1234 1243] ) } ) ) spids: [1219 1246] ) } spids: [1218] ) ] spids: [1218] ) terminator: <Op_Semi ';'> ) (Sentence child: (C {(_number)} {(DQ (${ VSub_Name r))}) terminator: <Op_Semi ';'> ) ] spids: [1216] ) spids: [1211 1215] ) (Sentence child:(C {(_symbol)} {(DQ ('+'))}) terminator:<Op_Semi ';'>) (C {(ENV_SET)} {(DQ (${ VSub_Name REPL_ENV))} {(DQ (${ VSub_Name r))} {(plus)}) (Sentence child:(C {(_symbol)} {(DQ (-))}) terminator:<Op_Semi ';'>) (C {(ENV_SET)} {(DQ (${ VSub_Name REPL_ENV))} {(DQ (${ VSub_Name r))} {(minus)}) (Sentence child:(C {(_symbol)} {(DQ (__STAR__))}) terminator:<Op_Semi ';'>) (C {(ENV_SET)} {(DQ (${ VSub_Name REPL_ENV))} {(DQ (${ VSub_Name r))} {(multiply)}) (Sentence child:(C {(_symbol)} {(DQ (/))}) terminator:<Op_Semi ';'>) (C {(ENV_SET)} {(DQ (${ VSub_Name REPL_ENV))} {(DQ (${ VSub_Name r))} {(divide)}) (While cond: [(Sentence child:(C {(true)}) terminator:<Op_Semi ';'>)] body: (DoGroup children: [ (AndOr ops: [Op_DPipe] children: [ (C {(READLINE)} {(DQ ('user> '))}) (ControlFlow token: <ControlFlow_Exit exit> arg_word: {(DQ ($ VSub_QMark '$?'))} ) ] ) (AndOr ops: [Op_DAmp Op_DAmp] children: [ (DBracket expr:(WordTest w:{(DQ (${ VSub_Name r))})) (C {(REP)} {(DQ (${ VSub_Name r))}) (C {(echo)} {(DQ (${ VSub_Name r))}) ] ) ] spids: [1362 1410] ) ) ] )