(command.CommandList children: [ (command.FuncDef name: test_set_editor body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:FAKE_EDITOR spids:[95]) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [95] ) ] spids: [95] ) (C {(export)} {(FAKE_EDITOR)}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:EDITOR spids:[106]) op: Equal rhs: {(SQ <'"$FAKE_EDITOR"'>)} spids: [106] ) ] spids: [106] ) (C {(export)} {(EDITOR)}) ] spids: [92] ) spids: [87 91] ) (command.FuncDef name: test_set_index_version body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:GIT_INDEX_VERSION spids:[127]) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [127] ) ] spids: [127] ) (C {(export)} {(GIT_INDEX_VERSION)}) ] spids: [124] ) spids: [119 123] ) (command.FuncDef name: test_decode_color body: (command.BraceGroup children: [ (C {(awk)} { (SQ <'\n'> <'\t\tfunction name(n) {\n'> <'\t\t\tif (n == 0) return "RESET";\n'> <'\t\t\tif (n == 1) return "BOLD";\n'> <'\t\t\tif (n == 30) return "BLACK";\n'> <'\t\t\tif (n == 31) return "RED";\n'> <'\t\t\tif (n == 32) return "GREEN";\n'> <'\t\t\tif (n == 33) return "YELLOW";\n'> <'\t\t\tif (n == 34) return "BLUE";\n'> <'\t\t\tif (n == 35) return "MAGENTA";\n'> <'\t\t\tif (n == 36) return "CYAN";\n'> <'\t\t\tif (n == 37) return "WHITE";\n'> <'\t\t\tif (n == 40) return "BLACK";\n'> <'\t\t\tif (n == 41) return "BRED";\n'> <'\t\t\tif (n == 42) return "BGREEN";\n'> <'\t\t\tif (n == 43) return "BYELLOW";\n'> <'\t\t\tif (n == 44) return "BBLUE";\n'> <'\t\t\tif (n == 45) return "BMAGENTA";\n'> <'\t\t\tif (n == 46) return "BCYAN";\n'> <'\t\t\tif (n == 47) return "BWHITE";\n'> <'\t\t}\n'> <'\t\t{\n'> <'\t\t\twhile (match($0, /\\033\\[[0-9;]*m/) != 0) {\n'> <'\t\t\t\tprintf "%s<", substr($0, 1, RSTART-1);\n'> <'\t\t\t\tcodes = substr($0, RSTART+2, RLENGTH-3);\n'> <'\t\t\t\tif (length(codes) == 0)\n'> <'\t\t\t\t\tprintf "%s", name(0)\n'> <'\t\t\t\telse {\n'> <'\t\t\t\t\tn = split(codes, ary, ";");\n'> <'\t\t\t\t\tsep = "";\n'> <'\t\t\t\t\tfor (i = 1; i <= n; i++) {\n'> <'\t\t\t\t\t\tprintf "%s%s", sep, name(ary[i]);\n'> <'\t\t\t\t\t\tsep = ";"\n'> <'\t\t\t\t\t}\n'> <'\t\t\t\t}\n'> <'\t\t\t\tprintf ">";\n'> < '\t\t\t\t$0 = substr($0, RSTART + RLENGTH, length($0) - RSTART - RLENGTH + 1);\n' > <'\t\t\t}\n'> <'\t\t\tprint\n'> <'\t\t}\n'> <'\t'> ) } ) ] spids: [145] ) spids: [140 144] ) (command.FuncDef name: lf_to_nul body: (command.BraceGroup children: [(C {(perl)} {(-pe)} {(SQ <'y/\\012/\\000/'>)})] spids: [202] ) spids: [197 201] ) (command.FuncDef name: nul_to_q body: (command.BraceGroup children:[(C {(perl)} {(-pe)} {(SQ <'y/\\000/Q/'>)})] spids:[221]) spids: [216 220] ) (command.FuncDef name: q_to_nul body: (command.BraceGroup children:[(C {(perl)} {(-pe)} {(SQ <'y/Q/\\000/'>)})] spids:[240]) spids: [235 239] ) (command.FuncDef name: q_to_cr body: (command.BraceGroup children:[(C {(tr)} {(Q)} {(SQ <'\\015'>)})] spids:[259]) spids: [254 258] ) (command.FuncDef name: q_to_tab body: (command.BraceGroup children:[(C {(tr)} {(Q)} {(SQ <'\\011'>)})] spids:[278]) spids: [273 277] ) (command.FuncDef name: qz_to_tab_space body: (command.BraceGroup children:[(C {(tr)} {(QZ)} {(SQ <'\\011\\040'>)})] spids:[297]) spids: [292 296] ) (command.FuncDef name: append_cr body: (command.BraceGroup children: [ (command.Pipeline children: [(C {(sed)} {(-e)} {(SQ <'s/$/Q/'>)}) (C {(tr)} {(Q)} {(SQ <'\\015'>)})] negated: F ) ] spids: [316] ) spids: [311 315] ) (command.FuncDef name: remove_cr body: (command.BraceGroup children: [ (command.Pipeline children: [(C {(tr)} {(SQ <'\\015'>)} {(Q)}) (C {(sed)} {(-e)} {(SQ <'s/Q$//'>)})] negated: F ) ] spids: [345] ) spids: [340 344] ) (command.FuncDef name: sane_unset body: (command.BraceGroup children: [ (C {(unset)} {(DQ ($ VSub_At '$@'))}) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] spids: [390] ) spids: [385 389] ) (command.FuncDef name: test_tick body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (C {(test)} {(-z)} { (DQ (word_part.BracedVarSub token: <VSub_Name test_tick> suffix_op: (suffix_op.StringUnary op_id:VTest_Plus arg_word:{(set)}) spids: [422 426] ) ) } ) ] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_tick spids:[433]) op: Equal rhs: {(1112911993)} spids: [433] ) ] spids: [433] ) ] spids: [16777215 430] ) ] else_action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_tick spids:[440]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{($ VSub_Name '$test_tick')}) right: (arith_expr.ArithWord w:{(Lit_Digits 60)}) ) spids: [441 448] ) } spids: [440] ) ] spids: [440] ) ] spids: [437 451] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:GIT_COMMITTER_DATE spids:[454]) op: Equal rhs: {(DQ ($ VSub_Name '$test_tick') (' -0700'))} spids: [454] ) ] spids: [454] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:GIT_AUTHOR_DATE spids:[461]) op: Equal rhs: {(DQ ($ VSub_Name '$test_tick') (' -0700'))} spids: [461] ) ] spids: [461] ) (C {(export)} {(GIT_COMMITTER_DATE)} {(GIT_AUTHOR_DATE)}) ] spids: [412] ) spids: [407 411] ) (command.FuncDef name: test_pause body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {(DQ ($ VSub_Name '$verbose'))} {(Lit_Other '=')} {(t)}) terminator: <Op_Semi ';'> ) ] action: [ (command.SimpleCommand words: [{(DQ ($ VSub_Name '$SHELL_PATH'))}] redirects: [ (redir.Redir op: <Redir_LessAnd '<&'> fd: 16777215 arg_word: {(6)} ) (redir.Redir op: <Redir_GreatAnd '>&'> fd: 16777215 arg_word: {(3)} ) (redir.Redir op: <Redir_GreatAnd '2>&'> fd: 2 arg_word: {(4)} ) ] ) ] spids: [16777215 511] ) ] else_action: [ (command.SimpleCommand words: [{(error)} {(DQ ('test_pause requires --verbose'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(5)})] ) ] spids: [528 541] ) ] spids: [495] ) spids: [490 494] ) (command.FuncDef name: debug body: (command.BraceGroup children: [ (command.SimpleCommand words: [{(DQ ($ VSub_At '$@'))}] more_env: [(env_pair name:GIT_TEST_GDB val:{(1)} spids:[566])] ) ] spids: [563] ) spids: [558 562] ) (command.FuncDef name: test_commit body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DAmp Op_DAmp] children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:notick spids:[603]) op: Equal rhs: (word.EmptyWord) spids: [603] ) ] spids: [603] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:signoff spids:[608]) op: Equal rhs: (word.EmptyWord) spids: [608] ) ] spids: [608] ) (command.WhileUntil keyword: <KW_While while> cond: [(C {(test)} {($ VSub_Pound '$#')} {(KW_Bang '!') (Lit_Other '=')} {(0)})] body: (command.DoGroup children: [ (command.Case to_match: {(DQ ($ VSub_Number '$1'))} arms: [ (case_arm pat_list: [{(--notick)}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:notick spids:[641]) op: Equal rhs: {(yes)} spids: [641] ) ] spids: [641] ) ] spids: [637 638 645 16777215] ) (case_arm pat_list: [{(--signoff)}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:signoff spids:[652]) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [652] ) ] spids: [652] ) ] spids: [648 649 658 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [(command.ControlFlow token:<ControlFlow_Break break>)] spids: [661 662 668 16777215] ) ] spids: [628 634 671] ) (C {(shift)}) ] spids: [625 677] ) ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:file spids:[682]) op: Equal rhs: { (word_part.BracedVarSub token: <VSub_Number 2> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonHyphen arg_word: {(DQ ($ VSub_Number '$1') (.t))} ) spids: [683 690] ) } spids: [682] ) ] spids: [682] ) (command.SimpleCommand words: [ {(echo)} { (DQ (word_part.BracedVarSub token: <VSub_Number 3> suffix_op: (suffix_op.StringUnary op_id: VTest_Hyphen arg_word: {($ VSub_Number '$1')} ) spids: [698 702] ) ) } ] redirects: [ (redir.Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(DQ ($ VSub_Name '$file'))} ) ] ) (C {(git)} {(add)} {(DQ ($ VSub_Name '$file'))}) (command.If arms: [ (if_arm cond: [(C {(test)} {(-z)} {(DQ ($ VSub_Name '$notick'))})] action: [(C {(test_tick)})] spids: [16777215 736] ) ] spids: [16777215 742] ) (C {(git)} {(commit)} {($ VSub_Name '$signoff')} {(-m)} {(DQ ($ VSub_Number '$1'))}) (C {(git)} {(tag)} { (DQ (word_part.BracedVarSub token: <VSub_Number 4> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonHyphen arg_word: {($ VSub_Number '$1')} ) spids: [767 771] ) ) } ) ] ) ] spids: [600] ) spids: [595 599] ) (command.FuncDef name: test_merge body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp Op_DAmp] children: [ (C {(test_tick)}) (C {(git)} {(merge)} {(-m)} {(DQ ($ VSub_Number '$1'))} {(DQ ($ VSub_Number '$2'))}) (C {(git)} {(tag)} {(DQ ($ VSub_Number '$1'))}) ] ) ] spids: [789] ) spids: [784 788] ) (command.FuncDef name: test_chmod body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(chmod)} {(DQ ($ VSub_At '$@'))}) (C {(git)} {(update-index)} {(--add)} {(DQ ('--chmod=') ($ VSub_At '$@'))}) ] ) ] spids: [840] ) spids: [835 839] ) (command.FuncDef name: test_unconfig body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_dir spids:[877]) op: Equal rhs: (word.EmptyWord) spids: [877] ) ] spids: [877] ) (command.If arms: [ (if_arm cond: [(C {(test)} {(DQ ($ VSub_Number '$1'))} {(Lit_Other '=')} {(-C)})] action: [ (C {(shift)}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_dir spids:[899]) op: Equal rhs: {($ VSub_Number '$1')} spids: [899] ) ] spids: [899] ) (C {(shift)}) ] spids: [16777215 893] ) ] spids: [16777215 906] ) (C {(git)} { (word_part.BracedVarSub token: <VSub_Name config_dir> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {('-C ') (DQ ($ VSub_Name '$config_dir'))} ) spids: [911 918] ) } {(config)} {(--unset-all)} {(DQ ($ VSub_At '$@'))} ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_status spids:[929]) op: Equal rhs: {($ VSub_QMark '$?')} spids: [929] ) ] spids: [929] ) (command.Case to_match: {(DQ ($ VSub_Name '$config_status'))} arms: [ (case_arm pat_list: [{(5)}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_status spids:[949]) op: Equal rhs: {(0)} spids: [949] ) ] spids: [949] ) ] spids: [942 943 953 16777215] ) ] spids: [933 939 956] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {($ VSub_Name '$config_status')} ) ] spids: [874] ) spids: [869 873] ) (command.FuncDef name: test_config body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_dir spids:[977]) op: Equal rhs: (word.EmptyWord) spids: [977] ) ] spids: [977] ) (command.If arms: [ (if_arm cond: [(C {(test)} {(DQ ($ VSub_Number '$1'))} {(Lit_Other '=')} {(-C)})] action: [ (C {(shift)}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:config_dir spids:[999]) op: Equal rhs: {($ VSub_Number '$1')} spids: [999] ) ] spids: [999] ) (C {(shift)}) ] spids: [16777215 993] ) ] spids: [16777215 1006] ) (command.AndOr ops: [Op_DAmp] children: [ (C {(test_when_finished)} { (DQ ('test_unconfig ') (word_part.BracedVarSub token: <VSub_Name config_dir> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {("-C '") ($ VSub_Name '$config_dir') ("'")} ) spids: [1013 1019] ) (" '") ($ VSub_Number '$1') ("'") ) } ) (C {(git)} { (word_part.BracedVarSub token: <VSub_Name config_dir> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {('-C ') (DQ ($ VSub_Name '$config_dir'))} ) spids: [1030 1037] ) } {(config)} {(DQ ($ VSub_At '$@'))} ) ] ) ] spids: [974] ) spids: [969 973] ) (command.FuncDef name: test_config_global body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test_when_finished)} {(DQ ("test_unconfig --global '") ($ VSub_Number '$1') ("'"))}) (C {(git)} {(config)} {(--global)} {(DQ ($ VSub_At '$@'))}) ] ) ] spids: [1053] ) spids: [1048 1052] ) (command.FuncDef name: write_script body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(echo)} { (DQ ('#!') (word_part.BracedVarSub token: <VSub_Number 2> suffix_op: (suffix_op.StringUnary op_id: VTest_Hyphen arg_word: {(DQ ($ VSub_Name '$SHELL_PATH'))} ) spids: [1095 1101] ) ) } ) (C {(cat)}) ] ) ] redirects: [ (redir.Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$1'))} ) ] spids: [1088] ) (C {(chmod)} {(Lit_Other '+') (x)} {(DQ ($ VSub_Number '$1'))}) ] ) ] spids: [1085] ) spids: [1080 1084] ) (command.FuncDef name: test_set_prereq body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:satisfied_prereq spids:[1171]) op: Equal rhs: {(DQ ($ VSub_Name '$satisfied_prereq') ($ VSub_Number '$1') (' '))} spids: [1171] ) ] spids: [1171] ) ] spids: [1168] ) spids: [1163 1167] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:satisfied_prereq spids:[1180]) op: Equal rhs: {(DQ (' '))} spids: [1180] ) ] spids: [1180] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:lazily_testable_prereq spids:[1185]) op: Equal rhs: (word.EmptyWord) spids: [1185] ) (assign_pair lhs: (lhs_expr.LhsName name:lazily_tested_prereq spids:[1187]) op: Equal rhs: (word.EmptyWord) spids: [1187] ) ] spids: [1185] ) (command.FuncDef name: test_lazy_prereq body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:lazily_testable_prereq spids:[1201]) op: Equal rhs: {(DQ ($ VSub_Name '$lazily_testable_prereq') ($ VSub_Number '$1') (' '))} spids: [1201] ) ] spids: [1201] ) (C {(eval)} {(test_prereq_lazily_) ($ VSub_Number '$1') (Lit_Other '=') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) (2) } ) ] spids: [1198] ) spids: [1193 1197] ) (command.FuncDef name: test_run_lazy_prereq_ body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:script spids:[1228]) op: Equal rhs: { (SQ <'\n'> <'mkdir -p "$TRASH_DIRECTORY/prereq-test-dir" &&\n'> <'(\n'> <'\tcd "$TRASH_DIRECTORY/prereq-test-dir" &&'> ) (DQ ($ VSub_Number '$2')) (SQ <'\n'> <')'>) } spids: [1228] ) ] spids: [1228] ) (command.SimpleCommand words: [{(say)} {(DQ ('checking prerequisite: ') ($ VSub_Number '$1'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) (command.SimpleCommand words: [{(say)} {(DQ ($ VSub_Name '$script'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) (C {(test_eval_)} {(DQ ($ VSub_Name '$script'))}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:eval_ret spids:[1272]) op: Equal rhs: {($ VSub_QMark '$?')} spids: [1272] ) ] spids: [1272] ) (C {(rm)} {(-rf)} {(DQ ($ VSub_Name '$TRASH_DIRECTORY') (/prereq-test-dir))}) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {(DQ ($ VSub_Name '$eval_ret'))} {(Lit_Other '=')} {(0)}) terminator: <Op_Semi ';'> ) ] action: [ (command.SimpleCommand words: [{(say)} {(DQ ('prerequisite ') ($ VSub_Number '$1') (' ok'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) ] spids: [16777215 1299] ) ] else_action: [ (command.SimpleCommand words: [{(say)} {(DQ ('prerequisite ') ($ VSub_Number '$1') (' not satisfied'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) ] spids: [1314 1329] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {($ VSub_Name '$eval_ret')} ) ] spids: [1225] ) spids: [1220 1224] ) (command.FuncDef name: test_have_prereq body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:save_IFS spids:[1351]) op: Equal rhs: {($ VSub_Name '$IFS')} spids: [1351] ) ] spids: [1351] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:IFS spids:[1355]) op: Equal rhs: {(Lit_Comma ',')} spids: [1355] ) ] spids: [1355] ) (C {(set)} {(--)} {($ VSub_Star '$*')}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:IFS spids:[1366]) op: Equal rhs: {($ VSub_Name '$save_IFS')} spids: [1366] ) ] spids: [1366] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:total_prereq spids:[1371]) op: Equal rhs: {(0)} spids: [1371] ) ] spids: [1371] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:ok_prereq spids:[1375]) op: Equal rhs: {(0)} spids: [1375] ) ] spids: [1375] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:missing_prereq spids:[1379]) op: Equal rhs: (word.EmptyWord) spids: [1379] ) ] spids: [1379] ) (command.ForEach iter_name: prerequisite do_arg_iter: T body: (command.DoGroup children: [ (command.Case to_match: {(DQ ($ VSub_Name '$prerequisite'))} arms: [ (case_arm pat_list: [{(KW_Bang '!') (Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:negative_prereq spids:[1405]) op: Equal rhs: {(t)} spids: [1405] ) ] spids: [1405] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:prerequisite spids:[1409]) op: Equal rhs: { (word_part.BracedVarSub token: <VSub_Name prerequisite> suffix_op: (suffix_op.StringUnary op_id: VOp1_Pound arg_word: {('!')} ) spids: [1410 1414] ) } spids: [1409] ) ] spids: [1409] ) ] spids: [1400 1402 1417 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:negative_prereq spids:[1424]) op: Equal rhs: (word.EmptyWord) spids: [1424] ) ] spids: [1424] ) ] spids: [1420 1421 16777215 1427] ) ] spids: [1391 1397 1427] ) (command.Case to_match: {(DQ (' ') ($ VSub_Name '$lazily_tested_prereq') (' '))} arms: [ (case_arm pat_list: [ {(Lit_Other '*') (DQ (' ') ($ VSub_Name '$prerequisite') (' ')) (Lit_Other '*') } ] spids: [1442 1449 1452 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (command.Case to_match: {(DQ (' ') ($ VSub_Name '$lazily_testable_prereq') (' '))} arms: [ (case_arm pat_list: [ {(Lit_Other '*') (DQ (' ') ($ VSub_Name '$prerequisite') (' ')) (Lit_Other '*') } ] action: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(eval)} { (DQ ('script=') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\$'> ) (test_prereq_lazily_) ($ VSub_Name '$prerequisite') ) } ) (command.If arms: [ (if_arm cond: [ (C {(test_run_lazy_prereq_)} {(DQ ($ VSub_Name '$prerequisite'))} {(DQ ($ VSub_Name '$script'))} ) ] action: [ (C {(test_set_prereq)} {($ VSub_Name '$prerequisite')}) ] spids: [16777215 1505] ) ] spids: [16777215 1513] ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name: lazily_tested_prereq spids: [1516] ) op: Equal rhs: { (DQ ($ VSub_Name '$lazily_tested_prereq') ($ VSub_Name '$prerequisite') (' ') ) } spids: [1516] ) ] spids: [1516] ) ] spids: [1470 1477 16777215 1524] ) ] spids: [1459 1467 1524] ) ] spids: [1455 1456 1527 16777215] ) ] spids: [1431 1439 1530] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:total_prereq spids:[1534]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{($ VSub_Name '$total_prereq')}) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [1535 1542] ) } spids: [1534] ) ] spids: [1534] ) (command.Case to_match: {(DQ ($ VSub_Name '$satisfied_prereq'))} arms: [ (case_arm pat_list: [ {(Lit_Other '*') (DQ (' ') ($ VSub_Name '$prerequisite') (' ')) (Lit_Other '*') } ] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:satisfied_this_prereq spids:[1564]) op: Equal rhs: {(t)} spids: [1564] ) ] spids: [1564] ) ] spids: [1554 1561 1568 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:satisfied_this_prereq spids:[1575]) op: Equal rhs: (word.EmptyWord) spids: [1575] ) ] spids: [1575] ) ] spids: [1571 1572 16777215 1578] ) ] spids: [1545 1551 1578] ) (command.Case to_match: { (DQ ($ VSub_Name '$satisfied_this_prereq') (',') ($ VSub_Name '$negative_prereq') ) } arms: [ (case_arm pat_list: [{(t) (Lit_Comma ',')} {(Lit_Comma ',') (t)}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:ok_prereq spids:[1601]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{($ VSub_Name '$ok_prereq')}) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [1602 1609] ) } spids: [1601] ) ] spids: [1601] ) ] spids: [1593 1598 1612 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:prerequisite spids:[1627]) op: Equal rhs: { (word_part.BracedVarSub token: <VSub_Name negative_prereq> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {('!')} ) spids: [1628 1632] ) ($ VSub_Name '$prerequisite') } spids: [1627] ) ] spids: [1627] ) (command.If arms: [ (if_arm cond: [(C {(test)} {(-z)} {(DQ ($ VSub_Name '$missing_prereq'))})] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:missing_prereq spids:[1650]) op: Equal rhs: {($ VSub_Name '$prerequisite')} spids: [1650] ) ] spids: [1650] ) ] spids: [16777215 1647] ) ] else_action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:missing_prereq spids:[1657]) op: Equal rhs: { (DQ ($ VSub_Name '$prerequisite') (',') ($ VSub_Name '$missing_prereq') ) } spids: [1657] ) ] spids: [1657] ) ] spids: [1654 1665] ) ] spids: [1615 1616 16777215 1668] ) ] spids: [1582 1590 1668] ) ] spids: [1388 1671] ) spids: [16777215 16777215] ) (C {(test)} {($ VSub_Name '$total_prereq')} {(Lit_Other '=')} {($ VSub_Name '$ok_prereq')}) ] spids: [1344] ) spids: [1339 1343] ) (command.FuncDef name: test_declared_prereq body: (command.BraceGroup children: [ (command.Case to_match: {(DQ (',') ($ VSub_Name '$test_prereq') (','))} arms: [ (case_arm pat_list: [ {(Lit_Other '*') (Lit_Comma ',') ($ VSub_Number '$1') (Lit_Comma ',') (Lit_Other '*') } ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [1705 1710 1718 16777215] ) ] spids: [1694 1702 1721] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [1691] ) spids: [1686 1690] ) (command.FuncDef name: test_verify_prereq body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DPipe Op_DPipe] children: [ (C {(test)} {(-z)} {(DQ ($ VSub_Name '$test_prereq'))}) (command.SimpleCommand words: [ {(expr)} {(DQ ($ VSub_Name '$test_prereq'))} {(Lit_Other ':')} {(SQ <'[A-Z0-9_,!]*$'>)} ] redirects: [(redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(/dev/null)})] ) (C {(error)} { (DQ ("bug in the test script: '") ($ VSub_Name '$test_prereq') ("' does not look like a prereq") ) } ) ] ) ] spids: [1736] ) spids: [1731 1735] ) (command.FuncDef name: test_expect_failure body: (command.BraceGroup children: [ (C {(test_start_)}) (command.AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(3)}) (command.BraceGroup children: [ (command.Sentence child: (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[1804]) op: Equal rhs: {($ VSub_Number '$1')} spids: [1804] ) ] spids: [1804] ) terminator: <Op_Semi ';'> ) (command.Sentence child: (C {(shift)}) terminator: <Op_Semi ';'> ) ] spids: [1802] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[1815]) op: Equal rhs: (word.EmptyWord) spids: [1815] ) ] spids: [1815] ) ] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(2)}) (C {(error)} {(DQ ('bug in the test script: not 2 or 3 parameters to test-expect-failure'))} ) ] ) (C {(test_verify_prereq)}) (C {(export)} {(test_prereq)}) (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {(test_skip)} {(DQ ($ VSub_At '$@'))})] negated: T ) ] action: [ (command.SimpleCommand words: [{(say)} {(DQ ('checking known breakage: ') ($ VSub_Number '$2'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) (command.If arms: [ (if_arm cond: [(C {(test_run_)} {(DQ ($ VSub_Number '$2'))} {(expecting_failure)})] action: [(C {(test_known_broken_ok_)} {(DQ ($ VSub_Number '$1'))})] spids: [16777215 1882] ) ] else_action: [(C {(test_known_broken_failure_)} {(DQ ($ VSub_Number '$1'))})] spids: [1892 1902] ) ] spids: [16777215 1857] ) ] spids: [16777215 1905] ) (C {(test_finish_)}) ] spids: [1784] ) spids: [1779 1783] ) (command.FuncDef name: test_expect_success body: (command.BraceGroup children: [ (C {(test_start_)}) (command.AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(3)}) (command.BraceGroup children: [ (command.Sentence child: (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[1938]) op: Equal rhs: {($ VSub_Number '$1')} spids: [1938] ) ] spids: [1938] ) terminator: <Op_Semi ';'> ) (command.Sentence child: (C {(shift)}) terminator: <Op_Semi ';'> ) ] spids: [1936] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[1949]) op: Equal rhs: (word.EmptyWord) spids: [1949] ) ] spids: [1949] ) ] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(2)}) (C {(error)} {(DQ ('bug in the test script: not 2 or 3 parameters to test-expect-success'))} ) ] ) (C {(test_verify_prereq)}) (C {(export)} {(test_prereq)}) (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {(test_skip)} {(DQ ($ VSub_At '$@'))})] negated: T ) ] action: [ (command.SimpleCommand words: [{(say)} {(DQ ('expecting success: ') ($ VSub_Number '$2'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) (command.If arms: [ (if_arm cond: [(C {(test_run_)} {(DQ ($ VSub_Number '$2'))})] action: [(C {(test_ok_)} {(DQ ($ VSub_Number '$1'))})] spids: [16777215 2014] ) ] else_action: [(C {(test_failure_)} {(DQ ($ VSub_At '$@'))})] spids: [2024 2034] ) ] spids: [16777215 1991] ) ] spids: [16777215 2037] ) (C {(test_finish_)}) ] spids: [1918] ) spids: [1913 1917] ) (command.FuncDef name: test_external body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(4)}) (command.BraceGroup children: [ (command.Sentence child: (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[2091]) op: Equal rhs: {($ VSub_Number '$1')} spids: [2091] ) ] spids: [2091] ) terminator: <Op_Semi ';'> ) (command.Sentence child: (C {(shift)}) terminator: <Op_Semi ';'> ) ] spids: [2089] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_prereq spids:[2102]) op: Equal rhs: (word.EmptyWord) spids: [2102] ) ] spids: [2102] ) ] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(3)}) (command.SimpleCommand words: [ {(error)} {(DQ ('bug in the test script: not 3 or 4 parameters to test_external'))} ] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(5)})] ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:descr spids:[2128]) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [2128] ) ] spids: [2128] ) (C {(shift)}) (C {(test_verify_prereq)}) (C {(export)} {(test_prereq)}) (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {(test_skip)} {(DQ ($ VSub_Name '$descr'))} {(DQ ($ VSub_At '$@'))})] negated: T ) ] action: [ (C {(say_color)} {(DQ )} { (DQ ('# run ') ($ VSub_Name '$test_count') (': ') ($ VSub_Name '$descr') (' (') ($ VSub_Star '$*') (')') ) } ) (C {(export)} {(TEST_DIRECTORY)} {(TRASH_DIRECTORY)} {(GIT_TEST_LONG)}) (command.SimpleCommand words: [{(DQ ($ VSub_At '$@'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '2>&'> fd:2 arg_word:{(4)})] ) (command.If arms: [ (if_arm cond: [(C {(test)} {(DQ ($ VSub_QMark '$?'))} {(Lit_Other '=')} {(0)})] action: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {($ VSub_Name '$test_external_has_tap')} {(-eq)} {(0)} ) terminator: <Op_Semi ';'> ) ] action: [(C {(test_ok_)} {(DQ ($ VSub_Name '$descr'))})] spids: [16777215 2251] ) ] else_action: [ (C {(say_color)} {(DQ )} {(DQ ('# test_external test ') ($ VSub_Name '$descr') (' was ok'))} ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_success spids:[2276]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w: {($ VSub_Name '$test_success')} ) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [2277 2284] ) } spids: [2276] ) ] spids: [2276] ) ] spids: [2261 2287] ) ] spids: [16777215 2237] ) ] else_action: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {($ VSub_Name '$test_external_has_tap')} {(-eq)} {(0)}) terminator: <Op_Semi ';'> ) ] action: [ (C {(test_failure_)} {(DQ ($ VSub_Name '$descr'))} {(DQ ($ VSub_At '$@'))} ) ] spids: [16777215 2304] ) ] else_action: [ (C {(say_color)} {(error)} { (DQ ('# test_external test ') ($ VSub_Name '$descr') (' failed: ') ($ VSub_At '$@') ) } ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_failure spids:[2333]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w: {($ VSub_Name '$test_failure')} ) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [2334 2341] ) } spids: [2333] ) ] spids: [2333] ) ] spids: [2318 2344] ) ] spids: [2290 2347] ) ] spids: [16777215 2160] ) ] spids: [16777215 2350] ) ] spids: [2074] ) spids: [2069 2073] ) (command.FuncDef name: test_external_without_stderr body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:tmp spids:[2377]) op: Equal rhs: { (word_part.BracedVarSub token: <VSub_Name TMPDIR> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonHyphen arg_word: {(Lit_Slash /) (tmp)} ) spids: [2378 2383] ) } spids: [2377] ) ] spids: [2377] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:stderr spids:[2386]) op: Equal rhs: {(DQ ($ VSub_Name '$tmp') (/git-external-stderr.) ($ VSub_Dollar '$$') (.tmp))} spids: [2386] ) ] spids: [2386] ) (command.SimpleCommand words: [{(test_external)} {(DQ ($ VSub_At '$@'))}] redirects: [ (redir.Redir op: <Redir_Great '4>'> fd: 4 arg_word: {(DQ ($ VSub_Name '$stderr'))} ) ] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} {(-f)} {(DQ ($ VSub_Name '$stderr'))}) (C {(error)} {(DQ ('Internal error: ') ($ VSub_Name '$stderr') (' disappeared.'))}) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:descr spids:[2427]) op: Equal rhs: {(DQ ('no stderr: ') ($ VSub_Number '$1'))} spids: [2427] ) ] spids: [2427] ) (C {(shift)}) (command.SimpleCommand words: [{(say)} {(DQ ('# expecting no stderr from previous command'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(3)})] ) (command.If arms: [ (if_arm cond: [(C {(test)} {(KW_Bang '!')} {(-s)} {(DQ ($ VSub_Name '$stderr'))})] action: [ (C {(rm)} {(DQ ($ VSub_Name '$stderr'))}) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {($ VSub_Name '$test_external_has_tap')} {(-eq)} {(0)}) terminator: <Op_Semi ';'> ) ] action: [(C {(test_ok_)} {(DQ ($ VSub_Name '$descr'))})] spids: [16777215 2482] ) ] else_action: [ (C {(say_color)} {(DQ )} { (DQ ('# test_external_without_stderr test ') ($ VSub_Name '$descr') (' was ok') ) } ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_success spids:[2507]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{($ VSub_Name '$test_success')}) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [2508 2515] ) } spids: [2507] ) ] spids: [2507] ) ] spids: [2492 2518] ) ] spids: [16777215 2460] ) ] else_action: [ (command.If arms: [ (if_arm cond: [(C {(test)} {(DQ ($ VSub_Name '$verbose'))} {(Lit_Other '=')} {(t)})] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:output spids:[2540]) op: Equal rhs: { (word_part.CommandSubPart command_list: (command.CommandList children: [ (command.Sentence child: (C {(echo)}) terminator: <Op_Semi ';'> ) (command.Sentence child: (C {(echo)} {(DQ ('# Stderr is:'))}) terminator: <Op_Semi ';'> ) (C {(cat)} {(DQ ($ VSub_Name '$stderr'))}) ] ) left_token: <Left_CommandSub '$('> spids: [2541 2557] ) } spids: [2540] ) ] spids: [2540] ) ] spids: [16777215 2537] ) ] else_action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:output spids:[2563]) op: Equal rhs: (word.EmptyWord) spids: [2563] ) ] spids: [2563] ) ] spids: [2560 2566] ) (C {(rm)} {(DQ ($ VSub_Name '$stderr'))}) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(test)} {($ VSub_Name '$test_external_has_tap')} {(-eq)} {(0)}) terminator: <Op_Semi ';'> ) ] action: [ (C {(test_failure_)} {(DQ ($ VSub_Name '$descr'))} {(DQ ($ VSub_At '$@'))} {(DQ ($ VSub_Name '$output'))} ) ] spids: [16777215 2591] ) ] else_action: [ (C {(say_color)} {(error)} { (DQ ('# test_external_without_stderr test ') ($ VSub_Name '$descr') (' failed: ') ($ VSub_At '$@') (': ') ($ VSub_Name '$output') ) } ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_failure spids:[2626]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{($ VSub_Name '$test_failure')}) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [2627 2634] ) } spids: [2626] ) ] spids: [2626] ) ] spids: [2609 2637] ) ] spids: [2521 2640] ) ] spids: [2366] ) spids: [2361 2365] ) (command.FuncDef name: test_path_is_file body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {(test)} {(-f)} {(DQ ($ VSub_Number '$1'))})] negated: T ) ] action: [ (C {(echo)} {(DQ ('File ') ($ VSub_Number '$1') (" doesn't exist. ") ($ VSub_Number '$2'))} ) (C {(false)}) ] spids: [16777215 2675] ) ] spids: [16777215 2691] ) ] spids: [2659] ) spids: [2654 2658] ) (command.FuncDef name: test_path_is_dir body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Pipeline children: [(C {(test)} {(-d)} {(DQ ($ VSub_Number '$1'))})] negated: T ) ] action: [ (C {(echo)} { (DQ ('Directory ') ($ VSub_Number '$1') (" doesn't exist. ") ($ VSub_Number '$2') ) } ) (C {(false)}) ] spids: [16777215 2717] ) ] spids: [16777215 2733] ) ] spids: [2701] ) spids: [2696 2700] ) (command.FuncDef name: test_dir_is_empty body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test_path_is_dir)} {(DQ ($ VSub_Number '$1'))}) (command.If arms: [ (if_arm cond: [ (C {(test)} {(-n)} { (DQ (word_part.CommandSubPart command_list: (command.CommandList children: [ (command.Pipeline children: [ (C {(ls)} {(-a1)} {(DQ ($ VSub_Number '$1'))}) (C {(egrep)} {(-v)} {(SQ <'^\\.\\.?$'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [2765 2783] ) ) } ) ] action: [ (C {(echo)} { (DQ ("Directory '") ($ VSub_Number '$1') ("' is not empty, it contains:")) } ) (C {(ls)} {(-la)} {(DQ ($ VSub_Number '$1'))}) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 2787] ) ] spids: [16777215 2813] ) ] ) ] spids: [2746] ) spids: [2741 2745] ) (command.FuncDef name: test_path_is_missing body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [(C {(test)} {(-e)} {(DQ ($ VSub_Number '$1'))})] action: [ (C {(echo)} {(DQ ('Path exists:'))}) (C {(ls)} {(-ld)} {(DQ ($ VSub_Number '$1'))}) (command.If arms: [ (if_arm cond: [(C {(test)} {($ VSub_Pound '$#')} {(-ge)} {(1)})] action: [(C {(echo)} {(DQ ($ VSub_Star '$*'))})] spids: [16777215 2867] ) ] spids: [16777215 2877] ) (C {(false)}) ] spids: [16777215 2837] ) ] spids: [16777215 2883] ) ] spids: [2823] ) spids: [2818 2822] ) (command.FuncDef name: test_line_count body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [(C {(test)} {($ VSub_Pound '$#')} {(KW_Bang '!') (Lit_Other '=')} {(3)})] action: [ (C {(error)} {(DQ ('bug in the test script: not 3 parameters to test_line_count'))}) ] spids: [16777215 2939] ) (if_arm cond: [ (command.Pipeline children: [ (C {(test)} { (word_part.CommandSubPart command_list: (command.CommandList children: [ (command.SimpleCommand words: [{(wc)} {(-l)}] redirects: [ (redir.Redir op: <Redir_Less '<'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$3'))} ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [2955 2964] ) } {(DQ ($ VSub_Number '$1'))} {(DQ ($ VSub_Number '$2'))} ) ] negated: T ) ] action: [ (C {(echo)} { (DQ ('test_line_count: line count for ') ($ VSub_Number '$3') (' !') ($ VSub_Number '$1') (' ') ($ VSub_Number '$2') ) } ) (C {(cat)} {(DQ ($ VSub_Number '$3'))}) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [2949 2975] ) ] spids: [16777215 3002] ) ] spids: [2924] ) spids: [2919 2923] ) (command.FuncDef name: list_contains body: (command.BraceGroup children: [ (command.Case to_match: {(DQ (',') ($ VSub_Number '$1') (','))} arms: [ (case_arm pat_list: [ {(Lit_Other '*') (Lit_Comma ',') ($ VSub_Number '$2') (Lit_Comma ',') (Lit_Other '*') } ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [3042 3047 3055 16777215] ) ] spids: [3031 3039 3058] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [3028] ) spids: [3023 3027] ) (command.FuncDef name: test_must_fail body: (command.BraceGroup children: [ (command.Case to_match: {(DQ ($ VSub_Number '$1'))} arms: [ (case_arm pat_list: [{(Lit_VarLike 'ok=') (Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:_test_ok spids:[3124]) op: Equal rhs: { (word_part.BracedVarSub token: <VSub_Number 1> suffix_op: (suffix_op.StringUnary op_id:VOp1_Pound arg_word:{('ok=')}) spids: [3125 3129] ) } spids: [3124] ) ] spids: [3124] ) (C {(shift)}) ] spids: [3119 3121 3135 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:_test_ok spids:[3142]) op: Equal rhs: (word.EmptyWord) spids: [3142] ) ] spids: [3142] ) ] spids: [3138 3139 3145 16777215] ) ] spids: [3110 3116 3148] ) (C {(DQ ($ VSub_At '$@'))}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:exit_code spids:[3156]) op: Equal rhs: {($ VSub_QMark '$?')} spids: [3156] ) ] spids: [3156] ) (command.If arms: [ (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test)} {($ VSub_Name '$exit_code')} {(-eq)} {(0)}) (command.Pipeline children: [(C {(list_contains)} {(DQ ($ VSub_Name '$_test_ok'))} {(success)})] negated: T ) ] ) ] action: [ (command.SimpleCommand words: [{(echo)} {(DQ ('test_must_fail: command succeeded: ') ($ VSub_Star '$*'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 3183] ) (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test_match_signal)} {(13)} {($ VSub_Name '$exit_code')}) (C {(list_contains)} {(DQ ($ VSub_Name '$_test_ok'))} {(sigpipe)}) ] ) ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [3202 3221] ) (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test)} {($ VSub_Name '$exit_code')} {(-gt)} {(129)}) (C {(test)} {($ VSub_Name '$exit_code')} {(-le)} {(192)}) ] ) ] action: [ (command.SimpleCommand words: [ {(echo)} { (DQ ('test_must_fail: died by signal ') (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Minus left: (arith_expr.ArithWord w:{($ VSub_Name '$exit_code')}) right: (arith_expr.ArithWord w:{(Lit_Digits 128)}) ) spids: [3260 3267] ) (': ') ($ VSub_Star '$*') ) } ] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [3229 3250] ) (if_arm cond: [(C {(test)} {($ VSub_Name '$exit_code')} {(-eq)} {(127)})] action: [ (command.SimpleCommand words: [{(echo)} {(DQ ('test_must_fail: command not found: ') ($ VSub_Star '$*'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [3278 3289] ) (if_arm cond: [(C {(test)} {($ VSub_Name '$exit_code')} {(-eq)} {(126)})] action: [ (command.SimpleCommand words: [{(echo)} {(DQ ('test_must_fail: valgrind error: ') ($ VSub_Star '$*'))}] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [3308 3319] ) ] spids: [16777215 3338] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] spids: [3107] ) spids: [3102 3106] ) (command.FuncDef name: test_might_fail body: (command.BraceGroup children: [(C {(test_must_fail)} {(Lit_VarLike 'ok=') (success)} {(DQ ($ VSub_At '$@'))})] spids: [3384] ) spids: [3379 3383] ) (command.FuncDef name: test_expect_code body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:want_code spids:[3426]) op: Equal rhs: {($ VSub_Number '$1')} spids: [3426] ) ] spids: [3426] ) (C {(shift)}) (C {(DQ ($ VSub_At '$@'))}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:exit_code spids:[3438]) op: Equal rhs: {($ VSub_QMark '$?')} spids: [3438] ) ] spids: [3438] ) (command.If arms: [ (if_arm cond: [ (C {(test)} {($ VSub_Name '$exit_code')} {(Lit_Other '=')} {($ VSub_Name '$want_code')} ) ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [16777215 3453] ) ] spids: [16777215 3461] ) (command.SimpleCommand words: [ {(echo)} { (DQ ('test_expect_code: command exited with ') ($ VSub_Name '$exit_code') (', we wanted ') ($ VSub_Name '$want_code') (' ') ($ VSub_Star '$*') ) } ] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [3423] ) spids: [3418 3422] ) (command.FuncDef name: test_cmp body: (command.BraceGroup children: [(C {($ VSub_Name '$GIT_TEST_CMP')} {(DQ ($ VSub_At '$@'))})] spids: [3528] ) spids: [3524 3527] ) (command.FuncDef name: test_cmp_bin body: (command.BraceGroup children:[(C {(cmp)} {(DQ ($ VSub_At '$@'))})] spids:[3548]) spids: [3544 3547] ) (command.FuncDef name: verbose body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(DQ ($ VSub_At '$@'))}) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)}) ] ) (command.SimpleCommand words: [ {(echo)} { (DQ ('command failed: ') (word_part.CommandSubPart command_list: (command.CommandList children: [(C {(git)} {(rev-parse)} {(--sq-quote)} {(DQ ($ VSub_At '$@'))})] ) left_token: <Left_CommandSub '$('> spids: [3595 3605] ) ) } ] redirects: [(redir.Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [3574] ) spids: [3569 3573] ) (command.FuncDef name: test_must_be_empty body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [(C {(test)} {(-s)} {(DQ ($ VSub_Number '$1'))})] action: [ (C {(echo)} {(DQ ("'") ($ VSub_Number '$1') ("' is not empty, it contains:"))}) (C {(cat)} {(DQ ($ VSub_Number '$1'))}) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(1)} ) ] spids: [16777215 3642] ) ] spids: [16777215 3666] ) ] spids: [3628] ) spids: [3623 3627] ) (command.FuncDef name: test_cmp_rev body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp Op_DAmp] children: [ (command.SimpleCommand words: [{(git)} {(rev-parse)} {(--verify)} {(DQ ($ VSub_Number '$1'))}] redirects: [(redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expect.rev)})] ) (command.SimpleCommand words: [{(git)} {(rev-parse)} {(--verify)} {(DQ ($ VSub_Number '$2'))}] redirects: [(redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(actual.rev)})] ) (C {(test_cmp)} {(expect.rev)} {(actual.rev)}) ] ) ] spids: [3679] ) spids: [3674 3678] ) (command.FuncDef name: test_seq body: (command.BraceGroup children: [ (command.Case to_match: {($ VSub_Pound '$#')} arms: [ (case_arm pat_list: [{(1)}] action: [(C {(set)} {(1)} {(DQ ($ VSub_At '$@'))})] spids: [3760 3761 3771 16777215] ) (case_arm pat_list:[{(2)}] spids:[3774 3775 3777 16777215]) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (C {(error)} {(DQ ('bug in the test script: not 1 or 2 parameters to test_seq'))}) ] spids: [3780 3781 3789 16777215] ) ] spids: [3753 3757 3792] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_seq_counter__ spids:[3795]) op: Equal rhs: {($ VSub_Number '$1')} spids: [3795] ) ] spids: [3795] ) (command.WhileUntil keyword: <KW_While while> cond: [ (C {(test)} {(DQ ($ VSub_Name '$test_seq_counter__'))} {(-le)} {(DQ ($ VSub_Number '$2'))}) ] body: (command.DoGroup children: [ (C {(echo)} {(DQ ($ VSub_Name '$test_seq_counter__'))}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_seq_counter__ spids:[3824]) op: Equal rhs: { (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w: {($ VSub_Name '$test_seq_counter__')} ) right: (arith_expr.ArithWord w:{(Lit_Digits 1)}) ) spids: [3825 3834] ) } spids: [3824] ) ] spids: [3824] ) ] spids: [3814 3837] ) ) ] spids: [3750] ) spids: [3745 3749] ) (command.FuncDef name: test_when_finished body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} { (DQ (word_part.BracedVarSub token: <VSub_Name BASH_SUBSHELL> suffix_op: (suffix_op.StringUnary op_id:VTest_Hyphen arg_word:{(0)}) spids: [3932 3936] ) ) } {(Lit_Other '=')} {(0)} ) (C {(error)} {(DQ ('bug in test script: test_when_finished does nothing in a subshell'))} ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_cleanup spids:[3953]) op: Equal rhs: { (DQ ('{ ') ($ VSub_Star '$*') ('\n') ('\t\t} && (exit ') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\"'> ) (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) (eval_ret) (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\"'> ) ('); eval_ret=') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ('?; ') ($ VSub_Name '$test_cleanup') ) } spids: [3953] ) ] spids: [3953] ) ] spids: [3914] ) spids: [3909 3913] ) (command.FuncDef name: test_create_repo body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DPipe] children: [ (C {(test)} {(DQ ($ VSub_Pound '$#'))} {(Lit_Other '=')} {(1)}) (C {(error)} {(DQ ('bug in the test script: not 1 parameter to test-create-repo'))}) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:repo spids:[4006]) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [4006] ) ] spids: [4006] ) (C {(mkdir)} {(-p)} {(DQ ($ VSub_Name '$repo'))}) (command.AndOr ops: [Op_DPipe] children: [ (command.Subshell child: (command.CommandList children: [ (command.AndOr ops: [Op_DPipe] children: [ (C {(cd)} {(DQ ($ VSub_Name '$repo'))}) (C {(error)} {(DQ ('Cannot setup test environment'))}) ] ) (command.AndOr ops: [Op_DPipe] children: [ (command.SimpleCommand words: [ {(DQ ($ VSub_Name '$GIT_EXEC_PATH') (/git-init))} { (DQ ('--template=') ($ VSub_Name '$GIT_BUILD_DIR') (/templates/blt/)) } ] redirects: [ (redir.Redir op: <Redir_GreatAnd '>&'> fd: 16777215 arg_word: {(3)} ) (redir.Redir op: <Redir_GreatAnd '2>&'> fd: 2 arg_word: {(4)} ) ] ) (C {(error)} {(DQ ('cannot run git init -- have you built things yet?'))}) ] ) (C {(mv)} {(.git/hooks)} {(.git/hooks-disabled)}) ] ) spids: [4021 4073] ) (command.ControlFlow token:<ControlFlow_Exit exit>) ] ) ] spids: [3983] ) spids: [3978 3982] ) (command.FuncDef name: test_ln_s_add body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [(C {(test_have_prereq)} {(SYMLINKS)})] action: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(ln)} {(-s)} {(DQ ($ VSub_Number '$1'))} {(DQ ($ VSub_Number '$2'))}) (C {(git)} {(update-index)} {(--add)} {(DQ ($ VSub_Number '$2'))}) ] ) ] spids: [16777215 4110] ) ] else_action: [ (command.AndOr ops: [Op_DAmp Op_DAmp Op_DAmp] children: [ (command.SimpleCommand words: [{(printf)} {(SQ <'%s'>)} {(DQ ($ VSub_Number '$1'))}] redirects: [ (redir.Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$2'))} ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:ln_s_obj spids:[4160]) op: Equal rhs: { (word_part.CommandSubPart command_list: (command.CommandList children: [ (C {(git)} {(hash-object)} {(-w)} {(DQ ($ VSub_Number '$2'))}) ] ) left_token: <Left_CommandSub '$('> spids: [4161 4171] ) } spids: [4160] ) ] spids: [4160] ) (C {(git)} {(update-index)} {(--add)} {(--cacheinfo)} {(120000)} {($ VSub_Name '$ln_s_obj')} {(DQ ($ VSub_Number '$2'))} ) (C {(git)} {(update-index)} {(DQ ($ VSub_Number '$2'))}) ] ) ] spids: [4139 4208] ) ] spids: [4100] ) spids: [4095 4099] ) (command.FuncDef name: test_write_lines body: (command.BraceGroup children: [(C {(printf)} {(DQ ('%s') (Lit_Other '\\') (n))} {(DQ ($ VSub_At '$@'))})] spids: [4221] ) spids: [4216 4220] ) (command.FuncDef name: perl body: (command.BraceGroup children: [(C {(command)} {(DQ ($ VSub_Name '$PERL_PATH'))} {(DQ ($ VSub_At '$@'))})] spids: [4244] ) spids: [4239 4243] ) (command.FuncDef name: test_normalize_bool body: (command.BraceGroup children: [ (command.SimpleCommand words: [ {(git)} {(-c)} {(magic.variable) (Lit_Other '=') (DQ ($ VSub_Number '$1'))} {(config)} {(--bool)} {(magic.variable)} ] redirects: [(redir.Redir op:<Redir_Great '2>'> fd:2 arg_word:{(/dev/null)})] ) ] spids: [4268] ) spids: [4263 4267] ) (command.FuncDef name: test_tristate body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (C {(eval)} { (DQ ('test x') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\$'> ) ('{') ($ VSub_Number '$1') ('+isset}') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (' = xisset') ) } ) ] action: [ (C {(eval)} { (DQ ('\n') ('\t\t\tcase ') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\"'> ) (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ($ VSub_Number '$1') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\"'> ) (' in\n') ("\t\t\t'')\t") ($ VSub_Number '$1') ('=false ;;\n') ('\t\t\tauto)\t;;\n') ('\t\t\t*)\t') ($ VSub_Number '$1') ('=') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ('(test_normalize_bool ') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\$'> ) ($ VSub_Number '$1') (' || echo true) ;;\n') ('\t\t\tesac\n') ('\t\t') ) } ) ] spids: [16777215 4363] ) ] else_action: [(C {(eval)} {(DQ ($ VSub_Number '$1') ('=auto'))})] spids: [4397 4408] ) ] spids: [4344] ) spids: [4339 4343] ) (command.FuncDef name: test_skip_or_die body: (command.BraceGroup children: [ (command.Case to_match: {(DQ ($ VSub_Number '$1'))} arms: [ (case_arm pat_list: [{(auto)}] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:skip_all spids:[4455]) op: Equal rhs: {($ VSub_Number '$2')} spids: [4455] ) ] spids: [4455] ) (C {(test_done)}) ] spids: [4451 4452 4462 16777215] ) (case_arm pat_list: [{(true)}] action: [(C {(error)} {(DQ ($ VSub_Number '$2'))})] spids: [4465 4466 4476 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (C {(error)} { (DQ ("BUG: test tristate is '") ($ VSub_Number '$1') ("' (real error: ") ($ VSub_Number '$2') (')') ) } ) ] spids: [4479 4480 16777215 4494] ) ] spids: [4442 4448 4494] ) ] spids: [4439] ) spids: [4434 4438] ) (command.FuncDef name: mingw_test_cmp body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:test_cmp_a spids:[4530]) op: Equal rhs: (word.EmptyWord) spids: [4530] ) (assign_pair lhs: (lhs_expr.LhsName name:test_cmp_b spids:[4532]) op: Equal rhs: (word.EmptyWord) spids: [4532] ) ] spids: [4528] ) (command.Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:stdin_for_diff spids:[4546]) op: Equal rhs: (word.EmptyWord) spids: [4546] ) ] spids: [4544] ) (command.If arms: [ (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test)} {(-s)} {(DQ ($ VSub_Number '$1'))}) (C {(test)} {(-s)} {(DQ ($ VSub_Number '$2'))}) ] ) ] action: [ (command.SimpleCommand words: [{(mingw_read_file_strip_cr_)} {(test_cmp_a)}] redirects: [ (redir.Redir op: <Redir_Less '<'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$1'))} ) ] ) (command.SimpleCommand words: [{(mingw_read_file_strip_cr_)} {(test_cmp_b)}] redirects: [ (redir.Redir op: <Redir_Less '<'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$2'))} ) ] ) ] spids: [16777215 4583] ) (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test)} {(-s)} {(DQ ($ VSub_Number '$1'))}) (C {(test)} {(DQ ($ VSub_Number '$2'))} {(Lit_Other '=')} {(-)}) ] ) ] action: [ (command.SimpleCommand words: [{(mingw_read_file_strip_cr_)} {(test_cmp_a)}] redirects: [ (redir.Redir op: <Redir_Less '<'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$1'))} ) ] ) (C {(mingw_read_file_strip_cr_)} {(test_cmp_b)}) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:stdin_for_diff spids:[4655]) op: Equal rhs: {(SQ <'<<<"$test_cmp_b"'>)} spids: [4655] ) ] spids: [4655] ) ] spids: [4610 4633] ) (if_arm cond: [ (command.AndOr ops: [Op_DAmp] children: [ (C {(test)} {(DQ ($ VSub_Number '$1'))} {(Lit_Other '=')} {(-)}) (C {(test)} {(-s)} {(DQ ($ VSub_Number '$2'))}) ] ) ] action: [ (C {(mingw_read_file_strip_cr_)} {(test_cmp_a)}) (command.SimpleCommand words: [{(mingw_read_file_strip_cr_)} {(test_cmp_b)}] redirects: [ (redir.Redir op: <Redir_Less '<'> fd: 16777215 arg_word: {(DQ ($ VSub_Number '$2'))} ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:stdin_for_diff spids:[4706]) op: Equal rhs: {(SQ <'<<<"$test_cmp_a"'>)} spids: [4706] ) ] spids: [4706] ) ] spids: [4661 4684] ) ] spids: [16777215 4712] ) (command.AndOr ops: [Op_DAmp Op_DAmp Op_DPipe] children: [ (C {(test)} {(-n)} {(DQ ($ VSub_Name '$test_cmp_a'))}) (C {(test)} {(-n)} {(DQ ($ VSub_Name '$test_cmp_b'))}) (C {(test)} {(DQ ($ VSub_Name '$test_cmp_a'))} {(Lit_Other '=')} {(DQ ($ VSub_Name '$test_cmp_b'))} ) (C {(eval)} { (DQ ('diff -u ') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\$'> ) ('@') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (' ') ($ VSub_Name '$stdin_for_diff') ) } ) ] ) ] spids: [4517] ) spids: [4512 4516] ) (command.FuncDef name: mingw_read_file_strip_cr_ body: (command.BraceGroup children: [ (command.Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:line spids:[4788]) op: Equal spids: [4788] ) ] spids: [4786] ) (command.WhileUntil keyword: <KW_While while> cond: [(C {(Lit_Other ':')})] body: (command.DoGroup children: [ (command.If arms: [ (if_arm cond: [ (command.SimpleCommand words: [ {(read)} {(-r)} {(-d)} { (word_part.SingleQuotedPart left: <Left_DollarSingleQuote "$'"> tokens: [<Char_OneChar '\\n'>] spids: [4812 4814] ) } {(line)} ] more_env: [ (env_pair name: IFS val: { (word_part.SingleQuotedPart left: <Left_DollarSingleQuote "$'"> tokens: [<Char_OneChar '\\r'>] spids: [4802 4804] ) } spids: [4801] ) ] ) ] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:line spids:[4826]) op: Equal rhs: {($ VSub_Name '$line') (word_part.SingleQuotedPart left: <Left_DollarSingleQuote "$'"> tokens: [<Char_OneChar '\\n'>] spids: [4828 4830] ) } spids: [4826] ) ] spids: [4826] ) ] spids: [16777215 4819] ) ] else_action: [ (command.If arms: [ (if_arm cond: [(C {(test)} {(-z)} {(DQ ($ VSub_Name '$line'))})] action: [(command.ControlFlow token:<ControlFlow_Break break>)] spids: [16777215 4859] ) ] spids: [16777215 4869] ) ] spids: [4833 4872] ) (C {(eval)} { (DQ ($ VSub_Number '$1') ('=') (word_part.EscapedLiteralPart token: <Lit_EscapedChar '\\$'> ) ($ VSub_Number '$1') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) (line) ) } ) ] spids: [4796 4887] ) ) ] spids: [4775] ) spids: [4770 4774] ) (command.FuncDef name: test_env body: (command.BraceGroup children: [ (command.Subshell child: (command.WhileUntil keyword: <KW_While while> cond: [(C {(test)} {($ VSub_Pound '$#')} {(-gt)} {(0)})] body: (command.DoGroup children: [ (command.Case to_match: {(DQ ($ VSub_Number '$1'))} arms: [ (case_arm pat_list: [{(Lit_Other '*') (Lit_Other '=') (Lit_Other '*')}] action: [ (C {(eval)} { (DQ (word_part.BracedVarSub token: <VSub_Number 1> suffix_op: (suffix_op.StringUnary op_id: VOp1_DPercent arg_word: {('=*')} ) spids: [4944 4948] ) ('=') (word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\$'>) ('{1#*=}') ) } ) (C {(eval)} { (DQ ('export ') (word_part.BracedVarSub token: <VSub_Number 1> suffix_op: (suffix_op.StringUnary op_id: VOp1_DPercent arg_word: {('=*')} ) spids: [4959 4963] ) ) } ) (C {(shift)}) ] spids: [4935 4938 4970 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (C {(DQ ($ VSub_At '$@'))}) (command.ControlFlow token: <ControlFlow_Exit exit> ) ] spids: [4973 4974 4985 16777215] ) ] spids: [4926 4932 4988] ) ] spids: [4923 4991] ) ) spids: [4909 4994] ) ] spids: [4906] ) spids: [4901 4905] ) (command.FuncDef name: test_match_signal body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (C {(test)} {(DQ ($ VSub_Number '$2'))} {(Lit_Other '=')} { (DQ (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{(Lit_Digits 128)}) right: (arith_expr.ArithWord w:{($ VSub_Number '$1')}) ) spids: [5024 5031] ) ) } ) ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [16777215 5035] ) (if_arm cond: [ (C {(test)} {(DQ ($ VSub_Number '$2'))} {(Lit_Other '=')} { (DQ (word_part.ArithSubPart anode: (arith_expr.ArithBinary op_id: Arith_Plus left: (arith_expr.ArithWord w:{(Lit_Digits 256)}) right: (arith_expr.ArithWord w:{($ VSub_Number '$1')}) ) spids: [5058 5065] ) ) } ) ] action: [(command.ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})] spids: [5047 5069] ) ] spids: [16777215 5081] ) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] spids: [5010] ) spids: [5005 5009] ) (command.FuncDef name: test_copy_bytes body: (command.BraceGroup children: [ (C {(perl)} {(-e)} { (SQ <'\n'> <'\t\tmy $len = $ARGV[1];\n'> <'\t\twhile ($len > 0) {\n'> <'\t\t\tmy $s;\n'> <'\t\t\tmy $nread = sysread(STDIN, $s, $len);\n'> <'\t\t\tdie "cannot read: $!" unless defined($nread);\n'> <'\t\t\tprint $s;\n'> <'\t\t\t$len -= $nread;\n'> <'\t\t}\n'> <'\t'> ) } {(-)} {(DQ ($ VSub_Number '$1'))} ) ] spids: [5099] ) spids: [5094 5098] ) ] )