(CommandList children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:GREP_TYPE_BSD) op:Equal rhs:{(0)} spids:[91])] spids: [91] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:GREP_TYPE_GNU_FREEBSD) op:Equal rhs:{(1)} spids:[94])] spids: [94] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:GREP_TYPE_GNU) op:Equal rhs:{(2)} spids:[97])] spids: [97] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:GREP_TYPE_UNKNOWN) op:Equal rhs:{(3)} spids:[100])] spids: [100] ) (FuncDef name: grep_type body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:grep_version) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(grep)} {(--version)})]) left_token: <Left_CommandSub '$('> spids: [114 118] ) } spids: [113] ) ] spids: [111] ) (Case to_match: {(DQ ($ VSub_Name '$grep_version'))} arms: [ (case_arm pat_list: [{(Lit_Other '*') (DQ ('BSD grep')) (Lit_Other '*')}] action: [ (ControlFlow token: <ControlFlow_Return return> arg_word: {($ VSub_Name '$GREP_TYPE_BSD')} ) ] spids: [131 136 144 16777215] ) (case_arm pat_list: [{(Lit_Other '*') (DQ ('GNU grep')) (Lit_Other '*')}] action: [ (Case to_match: {(DQ ($ VSub_Name '$grep_version'))} arms: [ (case_arm pat_list: [{(Lit_Other '*') (2.5.1-FreeBSD) (Lit_Other '*')}] action: [ (ControlFlow token: <ControlFlow_Return return> arg_word: {($ VSub_Name '$GREP_TYPE_GNU_FREEBSD')} ) ] spids: [164 167 175 16777215] ) (case_arm pat_list: [{(Lit_Other '*')}] action: [ (ControlFlow token: <ControlFlow_Return return> arg_word: {($ VSub_Name '$GREP_TYPE_GNU')} ) ] spids: [178 179 187 16777215] ) ] spids: [155 161 190] ) ] spids: [147 152 193 16777215] ) ] spids: [122 128 196] ) (C {(atf_fail)} {(DQ ('unknown grep type: ') ($ VSub_Name '$grep_version'))}) ] spids: [108] ) spids: [104 107] ) (C {(atf_test_case)} {(grep_r_implied)}) (FuncDef name: grep_r_implied_body body: (BraceGroup children: [ (C {(grep_type)}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {($ VSub_QMark '$?')} {(-ne)} {($ VSub_Name '$GREP_TYPE_BSD')} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [(C {(atf_skip)} {(DQ ('this test only works with bsdgrep(1)'))})] spids: [16777215 236] ) ] spids: [16777215 246] ) (Subshell child: (AndOr ops: [Op_DAmp] children: [ (C {(cd)} { (DQ (CommandSubPart command_list: (CommandList children:[(C {(atf_get_srcdir)})]) left_token: <Left_CommandSub '$('> spids: [254 256] ) ) } ) (C {(grep)} {(-r)} {(--exclude) (Lit_Other '=') (DQ ('*.out'))} {(-e)} {(DQ (test))} {(.)} ) ] ) redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(d_grep_r_implied.out)} spids: [280] ) ] spids: [250 278] ) (C {(atf_check)} {(-s)} {(ControlFlow_Exit exit) (Lit_Other ':') (0)} {(-x)} { (DQ ('(cd ') (CommandSubPart command_list: (CommandList children:[(C {(atf_get_srcdir)})]) left_token: <Left_CommandSub '$('> spids: [300 302] ) (' && grep -r --exclude=') (EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) ('*.out') (EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (' -e ') (EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (test) (EscapedLiteralPart token:<Lit_EscapedChar '\\"'>) (') | diff d_grep_r_implied.out -') ) } ) ] spids: [217] ) spids: [213 216] ) (C {(atf_test_case)} {(rgrep)}) (FuncDef name: rgrep_head body: (BraceGroup children:[(C {(atf_set)} {(DQ (require.progs))} {(DQ (rgrep))})] spids:[325]) spids: [321 324] ) (FuncDef name: rgrep_body body: (BraceGroup children: [ (C {(atf_check)} {(-o)} {(save) (Lit_Other ':') (d_grep_r_implied.out)} {(grep)} {(-r)} {(--exclude) (Lit_Other '=') (DQ ('*.out'))} {(-e)} {(DQ (test))} { (DQ (CommandSubPart command_list: (CommandList children:[(C {(atf_get_srcdir)})]) left_token: <Left_CommandSub '$('> spids: [372 374] ) ) } ) (C {(atf_check)} {(-o)} {(file) (Lit_Other ':') (d_grep_r_implied.out)} {(rgrep)} {(--exclude) (Lit_Other '=') (DQ ('*.out'))} {(-e)} {(DQ (test))} { (DQ (CommandSubPart command_list: (CommandList children:[(C {(atf_get_srcdir)})]) left_token: <Left_CommandSub '$('> spids: [401 403] ) ) } ) ] spids: [344] ) spids: [340 343] ) (FuncDef name: atf_init_test_cases body: (BraceGroup children: [(C {(atf_add_test_case)} {(grep_r_implied)}) (C {(atf_add_test_case)} {(rgrep)})] spids: [413] ) spids: [409 412] ) ] )