(command.CommandList
  children: [
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:ME_)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_Backtick '`'>
                child: 
                  (C {<expr>} {(DQ <'./'> ($ Id.VSub_Number '$0'))} {<Id.Lit_Colon ':'>} 
                    {(SQ <'.*/\\(.*\\)$'>)}
                  )
              )
            }
          spids: [163]
        )
      ]
    )
    (command.ShFunction
      name: Exit
      body: 
        (BraceGroup
          children: [
            (command.Sentence
              child: (C {<set>} {<Id.Lit_Other '+'> <e>})
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence
              child: 
                (command.Subshell
                  child: 
                    (command.ControlFlow
                      token: <Id.ControlFlow_Exit exit>
                      arg_word: {($ Id.VSub_Number '$1')}
                    )
                )
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence
              child: 
                (command.ControlFlow
                  token: <Id.ControlFlow_Exit exit>
                  arg_word: {($ Id.VSub_Number '$1')}
                )
              terminator: <Id.Op_Semi _>
            )
          ]
        )
    )
    (C {<Id.Lit_Colon ':'>} 
      {
        (braced_var_sub
          token: <Id.VSub_Name stderr_fileno_>
          suffix_op: (suffix_op.Unary tok:<Id.VTest_Equals '='> arg_word:{<2>})
        )
      }
    )
    (command.ShFunction
      name: warn_
      body: 
        (BraceGroup
          children: [
            (command.Case
              to_match: {($ Id.VSub_DollarName '$IFS')}
              arms: [
                (case_arm
                  pat_list: [{(SQ <' '>) <Id.Lit_Star '*'>}]
                  action: [
                    (command.Simple
                      words: [{<printf>} {(SQ <'%s\\n'>)} {(DQ ($ Id.VSub_Star '$*'))}]
                      redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
                      do_fork: T
                    )
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {<test>} {($ Id.VSub_DollarName '$stderr_fileno_')} {<Id.Lit_Equals '='>} 
                          {<2>}
                        )
                        (BraceGroup
                          children: [
                            (command.Sentence
                              child: 
                                (command.Pipeline
                                  children: [
                                    (C {<printf>} {(SQ <'%s\\n'>)} {(DQ ($ Id.VSub_Star '$*'))})
                                    (command.Simple
                                      words: [{<sed>} {<1q>}]
                                      redirects: [
                                        (redir
                                          op: <Id.Redir_GreatAnd '>&'>
                                          loc: (redir_loc.Fd fd:1)
                                          arg: {($ Id.VSub_DollarName '$stderr_fileno_')}
                                        )
                                      ]
                                      do_fork: T
                                    )
                                  ]
                                  negated: F
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      ]
                    )
                  ]
                  spids: [287 291 344 -1]
                )
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [
                    (command.Subshell
                      child: 
                        (command.CommandList
                          children: [
                            (command.Sentence
                              child: 
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:IFS)
                                      op: assign_op.Equal
                                      rhs: {(SQ <' '>)}
                                      spids: [351]
                                    )
                                  ]
                                )
                              terminator: <Id.Op_Semi _>
                            )
                            (C {<warn_>} {(DQ ($ Id.VSub_At '$@'))})
                          ]
                        )
                    )
                  ]
                  spids: [347 348 363 -1]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: fail_
      body: 
        (BraceGroup
          children: [
            (command.Sentence
              child: 
                (C {<warn_>} 
                  {(DQ ($ Id.VSub_DollarName '$ME_') <': failed test: '> ($ Id.VSub_At '$@'))}
                )
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence child:(C {<Exit>} {<1>}) terminator:<Id.Op_Semi _>)
          ]
        )
    )
    (command.ShFunction
      name: skip_
      body: 
        (BraceGroup
          children: [
            (command.Sentence
              child: 
                (C {<warn_>} 
                  {(DQ ($ Id.VSub_DollarName '$ME_') <': skipped test: '> ($ Id.VSub_At '$@'))}
                )
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence child:(C {<Exit>} {<77>}) terminator:<Id.Op_Semi _>)
          ]
        )
    )
    (command.ShFunction
      name: fatal_
      body: 
        (BraceGroup
          children: [
            (command.Sentence
              child: 
                (C {<warn_>} {(DQ ($ Id.VSub_DollarName '$ME_') <': hard error: '> ($ Id.VSub_At '$@'))})
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence child:(C {<Exit>} {<99>}) terminator:<Id.Op_Semi _>)
          ]
        )
    )
    (command.ShFunction
      name: framework_failure_
      body: 
        (BraceGroup
          children: [
            (command.Sentence
              child: 
                (C {<warn_>} 
                  {(DQ ($ Id.VSub_DollarName '$ME_') <': set-up failure: '> ($ Id.VSub_At '$@'))}
                )
              terminator: <Id.Op_Semi _>
            )
            (command.Sentence child:(C {<Exit>} {<99>}) terminator:<Id.Op_Semi _>)
          ]
        )
    )
    (command.ShFunction
      name: returns_
      body: 
        (BraceGroup
          children: [
            (BraceGroup
              children: [
                (command.Sentence
                  child: (C {<set>} {<Id.Lit_Other '+'> <x>})
                  terminator: <Id.Op_Semi _>
                )
              ]
              redirects: [(redir op:<Id.Redir_Great '2>'> loc:(redir_loc.Fd fd:2) arg:{<'/dev/null'>})]
            )
            (C {<local>} {<Id.Lit_VarLike 'exp_exit='> (DQ ($ Id.VSub_Number '$1'))})
            (C {<shift>})
            (C {(DQ ($ Id.VSub_At '$@'))})
            (command.AndOr
              ops: [Id.Op_DAmp Id.Op_DPipe]
              children: [
                (C {<test>} {($ Id.VSub_QMark '$?')} {<-eq>} {($ Id.VSub_DollarName '$exp_exit')})
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:ret_)
                      op: assign_op.Equal
                      rhs: {<0>}
                      spids: [534]
                    )
                  ]
                )
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:ret_)
                      op: assign_op.Equal
                      rhs: {<1>}
                      spids: [539]
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (command.AndOr
                              ops: [Id.Op_DAmp]
                              children: [
                                (C {<test>} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                                  {<Id.Lit_Equals '='>} {<yes>}
                                )
                                (C {<test>} {(DQ ($ Id.VSub_DollarName '$gl_set_x_corrupts_stderr_'))} 
                                  {<Id.Lit_Equals '='>} {<false>}
                                )
                              ]
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [(C {<set>} {<-x>})]
                  spids: [544 569]
                )
              ]
            )
            (BraceGroup
              children: [
                (command.Sentence
                  child: 
                    (command.ControlFlow
                      token: <Id.ControlFlow_Return return>
                      arg_word: {($ Id.VSub_DollarName '$ret_')}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
              redirects: [(redir op:<Id.Redir_Great '2>'> loc:(redir_loc.Fd fd:2) arg:{<'/dev/null'>})]
            )
          ]
        )
    )
    (command.CommandList
      children: [
        (command.Sentence
          child: 
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:DUALCASE)
                  op: assign_op.Equal
                  rhs: {<1>}
                  spids: [598]
                )
              ]
            )
          terminator: <Id.Op_Semi _>
        )
        (C {<export>} {<DUALCASE>})
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<test>} {<-n>} 
                          {
                            (DQ 
                              (braced_var_sub
                                token: <Id.VSub_Name ZSH_VERSION>
                                suffix_op: (suffix_op.Unary tok:<Id.VTest_Plus '+'> arg_word:{<set>})
                              )
                            )
                          }
                        )
                        (command.Subshell
                          child: (C {<emulate>} {<sh>})
                          redirects: [
                            (redir
                              op: <Id.Redir_Great '>'>
                              loc: (redir_loc.Fd fd:1)
                              arg: {<'/dev/null'>}
                            )
                            (redir
                              op: <Id.Redir_GreatAnd '2>&'>
                              loc: (redir_loc.Fd fd:2)
                              arg: {<1>}
                            )
                          ]
                        )
                      ]
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (C {<emulate>} {<sh>})
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:NULLCMD)
                  op: assign_op.Equal
                  rhs: {<Id.Lit_Colon ':'>}
                  spids: [643]
                )
              ]
            )
            (C {<alias>} {<-g>} {(SQ <'${1+"$@"}'>) <Id.Lit_Equals '='> (SQ <'"$@"'>)})
            (C {<setopt>} {<NO_GLOB_SUBST>})
          ]
          spids: [606 635]
        )
      ]
      else_action: [
        (command.Case
          to_match: 
            {
              (command_sub
                left_token: <Id.Left_Backtick '`'>
                child: 
                  (command.Subshell
                    child: (C {<set>} {<-o>})
                    redirects: [
                      (redir
                        op: <Id.Redir_Great '2>'>
                        loc: (redir_loc.Fd fd:2)
                        arg: {<'/dev/null'>}
                      )
                    ]
                  )
              )
            }
          arms: [
            (case_arm
              pat_list: [{<Id.Lit_Star '*'> <posix> <Id.Lit_Star '*'>}]
              action: [(C {<set>} {<-o>} {<posix>})]
              spids: [685 688 696 -1]
            )
          ]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:gl_shell_test_script_)
          op: assign_op.Equal
          rhs: 
            {
              (SQ <'\n'> <'test $(echo y) = y || exit 1\n'> 
                <'f_local_() { local v=1; }; f_local_ || exit 1\n'> <'score_=10\n'> <'if test "$VERBOSE" = yes; then\n'> 
                <'  test -n "$( (exec 3>&1; set -x; P=1 true 2>&3) 2> /dev/null)" && score_=9\n'> <'fi\n'> <'test -z "$EXEEXT" && exit $score_\n'> <'shopt -s expand_aliases\n'> 
                <'alias a-b="echo zoo"\n'> <'v=abx\n'> <'     test ${v%x} = ab \\\n'> <'  && test ${v#a} = bx \\\n'> 
                <'  && test $(a-b) = zoo \\\n'> <'  && exit $score_\n'>
              )
            }
          spids: [765]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<test>} {(DQ <x> ($ Id.VSub_Number '$1'))} {<Id.Lit_Equals '='>} 
                      {(DQ <x--no-reexec>)}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [(C {<shift>})]
          spids: [785 801]
        )
      ]
      else_action: [
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:gl_set_x_corrupts_stderr_)
              op: assign_op.Equal
              rhs: {<false>}
              spids: [813]
            )
          ]
        )
        (C {<export>} {<gl_set_x_corrupts_stderr_>})
        (command.ShAssignment
          pairs: [
            (assign_pair
              lhs: (sh_lhs_expr.Name name:marginal_)
              op: assign_op.Equal
              rhs: (word.Empty)
              spids: [827]
            )
          ]
        )
        (command.ForEach
          iter_name: re_shell_
          iter_words: [
            {<__current__>}
            {
              (DQ 
                (braced_var_sub
                  token: <Id.VSub_Name CONFIG_SHELL>
                  suffix_op: (suffix_op.Unary tok:<Id.VTest_ColonHyphen ':-'> arg_word:{<no_shell>})
                )
              )
            }
            {<'/bin/sh'>}
            {<bash>}
            {<dash>}
            {<zsh>}
            {<pdksh>}
            {<fail>}
          ]
          do_arg_iter: F
          body: 
            (command.DoGroup
              children: [
                (command.AndOr
                  ops: [Id.Op_DAmp]
                  children: [
                    (C {<test>} {(DQ ($ Id.VSub_DollarName '$re_shell_'))} {<Id.Lit_Equals '='>} 
                      {<no_shell>}
                    )
                    (command.ControlFlow token:<Id.ControlFlow_Continue continue>)
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (C {<test>} {(DQ ($ Id.VSub_DollarName '$re_shell_'))} 
                                  {<Id.Lit_Equals '='>} {<fail>}
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      action: [
                        (command.AndOr
                          ops: [Id.Op_DAmp]
                          children: [
                            (C {<test>} {<-z>} {(DQ ($ Id.VSub_DollarName '$marginal_'))})
                            (C {<skip_>} {<failed>} {<to>} {<find>} {<an>} {<adequate>} {<shell>})
                          ]
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:re_shell_)
                              op: assign_op.Equal
                              rhs: {($ Id.VSub_DollarName '$marginal_')}
                              spids: [934]
                            )
                          ]
                        )
                        (command.ControlFlow
                          token: <Id.ControlFlow_Break break>
                        )
                      ]
                      spids: [893 906]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (C {<test>} {(DQ ($ Id.VSub_DollarName '$re_shell_'))} 
                                  {<Id.Lit_Equals '='>} {<__current__>}
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      action: [
                        (command.Subshell
                          child: (C {<eval>} {(DQ ($ Id.VSub_DollarName '$gl_shell_test_script_'))})
                          redirects: [
                            (redir
                              op: <Id.Redir_Great '>'>
                              loc: (redir_loc.Fd fd:1)
                              arg: {<'/dev/null'>}
                            )
                            (redir
                              op: <Id.Redir_GreatAnd '2>&'>
                              loc: (redir_loc.Fd fd:2)
                              arg: {<1>}
                            )
                          ]
                        )
                      ]
                      spids: [953 966]
                    )
                  ]
                  else_action: [
                    (command.Simple
                      words: [
                        {(DQ ($ Id.VSub_DollarName '$re_shell_'))}
                        {<-c>}
                        {(DQ ($ Id.VSub_DollarName '$gl_shell_test_script_'))}
                      ]
                      redirects: [
                        (redir
                          op: <Id.Redir_Great '2>'>
                          loc: (redir_loc.Fd fd:2)
                          arg: {<'/dev/null'>}
                        )
                      ]
                      do_fork: T
                    )
                  ]
                )
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:st_)
                      op: assign_op.Equal
                      rhs: {($ Id.VSub_QMark '$?')}
                      spids: [1020]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (C {<test>} {($ Id.VSub_DollarName '$st_')} {<Id.Lit_Equals '='>} {<10>})
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:gl_set_x_corrupts_stderr_)
                              op: assign_op.Equal
                              rhs: {<false>}
                              spids: [1043]
                            )
                          ]
                        )
                        (command.ControlFlow
                          token: <Id.ControlFlow_Break break>
                        )
                      ]
                      spids: [1029 1040]
                    )
                  ]
                )
                (command.If
                  arms: [
                    (if_arm
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (C {<test>} 
                                  {
                                    (DQ ($ Id.VSub_DollarName '$st_') <':'> 
                                      ($ Id.VSub_DollarName '$marginal_')
                                    )
                                  } {<Id.Lit_Equals '='>} {<9> <Id.Lit_Colon ':'>}
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:marginal_)
                              op: assign_op.Equal
                              rhs: {(DQ ($ Id.VSub_DollarName '$re_shell_'))}
                              spids: [1078]
                            )
                          ]
                        )
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:gl_set_x_corrupts_stderr_)
                              op: assign_op.Equal
                              rhs: {<true>}
                              spids: [1084]
                            )
                          ]
                        )
                      ]
                      spids: [1058 1075]
                    )
                  ]
                )
              ]
            )
        )
        (command.If
          arms: [
            (if_arm
              cond: 
                (condition.Shell
                  commands: [
                    (command.Sentence
                      child: 
                        (C {<test>} {(DQ ($ Id.VSub_DollarName '$re_shell_'))} 
                          {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<__current__>}
                        )
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              action: [
                (command.Case
                  to_match: {($ Id.VSub_Hyphen '$-')}
                  arms: [
                    (case_arm
                      pat_list: [
                        {<Id.Lit_Star '*'> <v> <Id.Lit_Star '*'> <x> <Id.Lit_Star '*'>}
                        {<Id.Lit_Star '*'> <x> <Id.Lit_Star '*'> <v> <Id.Lit_Star '*'>}
                      ]
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:opts_)
                              op: assign_op.Equal
                              rhs: {<-vx>}
                              spids: [1138]
                            )
                          ]
                        )
                      ]
                      spids: [1123 1136 1141 -1]
                    )
                    (case_arm
                      pat_list: [{<Id.Lit_Star '*'> <v> <Id.Lit_Star '*'>}]
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:opts_)
                              op: assign_op.Equal
                              rhs: {<-v>}
                              spids: [1149]
                            )
                          ]
                        )
                      ]
                      spids: [1144 1147 1152 -1]
                    )
                    (case_arm
                      pat_list: [{<Id.Lit_Star '*'> <x> <Id.Lit_Star '*'>}]
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:opts_)
                              op: assign_op.Equal
                              rhs: {<-x>}
                              spids: [1160]
                            )
                          ]
                        )
                      ]
                      spids: [1155 1158 1163 -1]
                    )
                    (case_arm
                      pat_list: [{<Id.Lit_Star '*'>}]
                      action: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:opts_)
                              op: assign_op.Equal
                              rhs: (word.Empty)
                              spids: [1169]
                            )
                          ]
                        )
                      ]
                      spids: [1166 1167 1171 -1]
                    )
                  ]
                )
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:re_shell)
                      op: assign_op.Equal
                      rhs: {($ Id.VSub_DollarName '$re_shell_')}
                      spids: [1177]
                    )
                  ]
                )
                (C {<export>} {<re_shell>})
                (C {<exec>} {(DQ ($ Id.VSub_DollarName '$re_shell_'))} {($ Id.VSub_DollarName '$opts_')} 
                  {(DQ ($ Id.VSub_Number '$0'))} {<--no-reexec>} {(DQ ($ Id.VSub_At '$@'))}
                )
                (command.Simple
                  words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$ME_') <': exec failed'>)}]
                  redirects: [(redir op:<Id.Redir_GreatAnd '1>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
                  do_fork: T
                )
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<127>})
              ]
              spids: [1095 1109]
            )
          ]
        )
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<test>} {<-n>} {(DQ ($ Id.VSub_DollarName '$BASH_VERSION'))})
        (C {<unalias>} {<-a>})
      ]
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<test>} {<-n>} {(DQ ($ Id.VSub_DollarName '$EXEEXT'))})
        (C {<shopt>} {<-s>} {<expand_aliases>})
      ]
    )
    (C {<Id.Lit_Colon ':'>} 
      {
        (braced_var_sub
          token: <Id.VSub_Name MALLOC_PERTURB_>
          suffix_op: (suffix_op.Unary tok:<Id.VTest_Equals '='> arg_word:{<87>})
        )
      }
    )
    (C {<export>} {<MALLOC_PERTURB_>})
    (command.ShFunction
      name: cleanup_
      body: 
        (BraceGroup
          children: [(command.Sentence child:(C {<Id.Lit_Colon ':'>}) terminator:<Id.Op_Semi _>)]
        )
    )
    (command.ShFunction
      name: emit_diff_u_header_
      body: 
        (BraceGroup
          children: [
            (C {<printf>} {(SQ <'%s\\n'>)} {(DQ <'diff -u '> ($ Id.VSub_Star '$*'))} 
              {(DQ <'--- '> ($ Id.VSub_Number '$1') <'\t1970-01-01'>)} {(DQ <'+++ '> ($ Id.VSub_Number '$2') <'\t1970-01-01'>)}
            )
          ]
        )
    )
    (command.ShFunction
      name: compare_dev_null_
      body: 
        (BraceGroup
          children: [
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<test>} {($ Id.VSub_Pound '$#')} {<Id.Lit_Equals '='>} {<2>})
                (command.ControlFlow
                  token: <Id.ControlFlow_Return return>
                  arg_word: {<2>}
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<test>} {(DQ <x> ($ Id.VSub_Number '$1'))} {<Id.Lit_Equals '='>} 
                              {<'x/dev/null'>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {<test>} {<-s>} {(DQ ($ Id.VSub_Number '$2'))})
                        (command.ControlFlow
                          token: <Id.ControlFlow_Return return>
                          arg_word: {<0>}
                        )
                      ]
                    )
                    (command.Sentence
                      child: (C {<emit_diff_u_header_>} {(DQ ($ Id.VSub_At '$@'))})
                      terminator: <Id.Op_Semi _>
                    )
                    (C {<sed>} {(SQ <'s/^/+/'>)} {(DQ ($ Id.VSub_Number '$2'))})
                    (command.ControlFlow
                      token: <Id.ControlFlow_Return return>
                      arg_word: {<1>}
                    )
                  ]
                  spids: [1409 1423]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<test>} {(DQ <x> ($ Id.VSub_Number '$2'))} {<Id.Lit_Equals '='>} 
                              {<'x/dev/null'>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {<test>} {<-s>} {(DQ ($ Id.VSub_Number '$1'))})
                        (command.ControlFlow
                          token: <Id.ControlFlow_Return return>
                          arg_word: {<0>}
                        )
                      ]
                    )
                    (command.Sentence
                      child: (C {<emit_diff_u_header_>} {(DQ ($ Id.VSub_At '$@'))})
                      terminator: <Id.Op_Semi _>
                    )
                    (C {<sed>} {(SQ <'s/^/-/'>)} {(DQ ($ Id.VSub_Number '$1'))})
                    (command.ControlFlow
                      token: <Id.ControlFlow_Return return>
                      arg_word: {<1>}
                    )
                  ]
                  spids: [1468 1482]
                )
              ]
            )
            (command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<2>})
          ]
        )
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:diff_out_)
                              op: assign_op.Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Id.Left_Backtick '`'>
                                    child: 
                                      (command.CommandList
                                        children: [
                                          (command.Sentence
                                            child: 
                                              (command.Simple
                                                words: [{<exec>}]
                                                redirects: [
                                                  (redir
                                                    op: <Id.Redir_Great '2>'>
                                                    loc: (redir_loc.Fd fd:2)
                                                    arg: {<'/dev/null'>}
                                                  )
                                                ]
                                                do_fork: T
                                              )
                                            terminator: <Id.Op_Semi _>
                                          )
                                          (command.Simple
                                            words: [
                                              {<diff>}
                                              {<-u>}
                                              {(DQ ($ Id.VSub_Number '$0'))}
                                              {(DQ ($ Id.VSub_Number '$0'))}
                                            ]
                                            redirects: [
                                              (redir
                                                op: <Id.Redir_Less '<'>
                                                loc: (redir_loc.Fd fd:0)
                                                arg: {<'/dev/null'>}
                                              )
                                            ]
                                            do_fork: T
                                          )
                                        ]
                                      )
                                  )
                                }
                              spids: [1536]
                            )
                          ]
                        )
                        (command.Pipeline
                          children: [
                            (command.Simple
                              words: [{<diff>} {<-u>} {<Makefile>} {(DQ ($ Id.VSub_Number '$0'))}]
                              redirects: [
                                (redir
                                  op: <Id.Redir_Great '2>'>
                                  loc: (redir_loc.Fd fd:2)
                                  arg: {<'/dev/null'>}
                                )
                              ]
                              do_fork: T
                            )
                            (command.Simple
                              words: [{<grep>} {(SQ <'^[+]#!'>)}]
                              redirects: [
                                (redir
                                  op: <Id.Redir_Great '>'>
                                  loc: (redir_loc.Fd fd:1)
                                  arg: {<'/dev/null'>}
                                )
                              ]
                              do_fork: T
                            )
                          ]
                          negated: F
                        )
                      ]
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: (C {<test>} {<-z>} {(DQ ($ Id.VSub_DollarName '$diff_out_'))})
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.ShFunction
                      name: compare_
                      body: 
                        (BraceGroup
                          children: [
                            (command.Sentence
                              child: (C {<diff>} {<-u>} {(DQ ($ Id.VSub_At '$@'))})
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                    )
                  ]
                  spids: [1603 1614]
                )
              ]
              else_action: [
                (command.ShFunction
                  name: compare_
                  body: 
                    (BraceGroup
                      children: [
                        (command.If
                          arms: [
                            (if_arm
                              cond: 
                                (condition.Shell
                                  commands: [
                                    (command.Sentence
                                      child: 
                                        (command.Simple
                                          words: [{<diff>} {<-u>} {(DQ ($ Id.VSub_At '$@'))}]
                                          redirects: [
                                            (redir
                                              op: <Id.Redir_Great '>'>
                                              loc: (redir_loc.Fd fd:1)
                                              arg: {<diff.out>}
                                            )
                                          ]
                                          do_fork: T
                                        )
                                      terminator: <Id.Op_Semi _>
                                    )
                                  ]
                                )
                              action: [(C {<rm>} {<-f>} {<diff.out>}) (C {<true>})]
                              spids: [1648 1663]
                            )
                          ]
                          else_action: [
                            (C {<cat>} {<diff.out>})
                            (C {<rm>} {<-f>} {<diff.out>})
                            (C {<false>})
                          ]
                        )
                      ]
                    )
                )
              ]
            )
          ]
          spids: [1534 1592]
        )
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:diff_out_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Id.Left_Backtick '`'>
                                child: 
                                  (command.CommandList
                                    children: [
                                      (command.Sentence
                                        child: 
                                          (command.Simple
                                            words: [{<exec>}]
                                            redirects: [
                                              (redir
                                                op: <Id.Redir_Great '2>'>
                                                loc: (redir_loc.Fd fd:2)
                                                arg: {<'/dev/null'>}
                                              )
                                            ]
                                            do_fork: T
                                          )
                                        terminator: <Id.Op_Semi _>
                                      )
                                      (command.Simple
                                        words: [
                                          {<diff>}
                                          {<-c>}
                                          {(DQ ($ Id.VSub_Number '$0'))}
                                          {(DQ ($ Id.VSub_Number '$0'))}
                                        ]
                                        redirects: [
                                          (redir
                                            op: <Id.Redir_Less '<'>
                                            loc: (redir_loc.Fd fd:0)
                                            arg: {<'/dev/null'>}
                                          )
                                        ]
                                        do_fork: T
                                      )
                                    ]
                                  )
                              )
                            }
                          spids: [1712]
                        )
                      ]
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: (C {<test>} {<-z>} {(DQ ($ Id.VSub_DollarName '$diff_out_'))})
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.ShFunction
                      name: compare_
                      body: 
                        (BraceGroup
                          children: [
                            (command.Sentence
                              child: (C {<diff>} {<-c>} {(DQ ($ Id.VSub_At '$@'))})
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                    )
                  ]
                  spids: [1743 1754]
                )
              ]
              else_action: [
                (command.ShFunction
                  name: compare_
                  body: 
                    (BraceGroup
                      children: [
                        (command.If
                          arms: [
                            (if_arm
                              cond: 
                                (condition.Shell
                                  commands: [
                                    (command.Sentence
                                      child: 
                                        (command.Simple
                                          words: [{<diff>} {<-c>} {(DQ ($ Id.VSub_At '$@'))}]
                                          redirects: [
                                            (redir
                                              op: <Id.Redir_Great '>'>
                                              loc: (redir_loc.Fd fd:1)
                                              arg: {<diff.out>}
                                            )
                                          ]
                                          do_fork: T
                                        )
                                      terminator: <Id.Op_Semi _>
                                    )
                                  ]
                                )
                              action: [(C {<rm>} {<-f>} {<diff.out>}) (C {<true>})]
                              spids: [1788 1803]
                            )
                          ]
                          else_action: [
                            (C {<cat>} {<diff.out>})
                            (C {<rm>} {<-f>} {<diff.out>})
                            (C {<false>})
                          ]
                        )
                      ]
                    )
                )
              ]
            )
          ]
          spids: [1710 1740]
        )
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.Simple
                      words: [{<cmp>} {<-s>} {<'/dev/null'>} {<'/dev/null'>}]
                      redirects: [
                        (redir
                          op: <Id.Redir_Great '2>'>
                          loc: (redir_loc.Fd fd:2)
                          arg: {<'/dev/null'>}
                        )
                      ]
                      do_fork: T
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.ShFunction
              name: compare_
              body: 
                (BraceGroup
                  children: [
                    (command.Sentence
                      child: (C {<cmp>} {<-s>} {(DQ ($ Id.VSub_At '$@'))})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
            )
          ]
          spids: [1854 1868]
        )
      ]
      else_action: [
        (command.ShFunction
          name: compare_
          body: 
            (BraceGroup
              children: [
                (command.Sentence
                  child: (C {<cmp>} {(DQ ($ Id.VSub_At '$@'))})
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
        )
      ]
    )
    (command.ShFunction
      name: compare
      body: 
        (BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: (C {<compare_dev_null_>} {(DQ ($ Id.VSub_At '$@'))})
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [(command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<0>})]
                  spids: [1943 1952]
                )
              ]
              else_action: [
                (command.Case
                  to_match: {($ Id.VSub_QMark '$?')}
                  arms: [
                    (case_arm
                      pat_list: [{<1>}]
                      action: [
                        (command.ControlFlow
                          token: <Id.ControlFlow_Return return>
                          arg_word: {<1>}
                        )
                      ]
                      spids: [1970 1971 1976 -1]
                    )
                    (case_arm
                      pat_list: [{<Id.Lit_Star '*'>}]
                      action: [(C {<compare_>} {(DQ ($ Id.VSub_At '$@'))})]
                      spids: [1979 1980 1987 -1]
                    )
                  ]
                )
              ]
            )
          ]
        )
    )
    (command.ShFunction
      name: testdir_prefix_
      body: 
        (BraceGroup
          children: [(command.Sentence child:(C {<printf>} {<gt>}) terminator:<Id.Op_Semi _>)]
        )
    )
    (command.ShFunction
      name: remove_tmp_
      body: 
        (BraceGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:__st)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_QMark '$?')}
                  spids: [2030]
                )
              ]
            )
            (C {<cleanup_>})
            (command.AndOr
              ops: [Id.Op_DPipe Id.Op_DPipe]
              children: [
                (C {<cd>} {(DQ ($ Id.VSub_DollarName '$initial_cwd_'))})
                (C {<cd>} {<'/'>})
                (C {<cd>} {<'/tmp'>})
              ]
            )
            (C {<chmod>} {<-R>} {<u> <Id.Lit_Other '+'> <rwx>} {(DQ ($ Id.VSub_DollarName '$test_dir_'))})
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<rm>} {<-rf>} {(DQ ($ Id.VSub_DollarName '$test_dir_'))})
                (BraceGroup
                  children: [
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Id.Op_DAmp]
                          children: [
                            (C {<test>} {($ Id.VSub_DollarName '$__st')} {<Id.Lit_Equals '='>} {<0>})
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:__st)
                                  op: assign_op.Equal
                                  rhs: {<1>}
                                  spids: [2099]
                                )
                              ]
                            )
                          ]
                        )
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              ]
            )
            (command.ControlFlow
              token: <Id.ControlFlow_Exit exit>
              arg_word: {($ Id.VSub_DollarName '$__st')}
            )
          ]
        )
    )
    (command.ShFunction
      name: find_exe_basenames_
      body: 
        (BraceGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:feb_dir_)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_Number '$1')}
                  spids: [2133]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:feb_fail_)
                  op: assign_op.Equal
                  rhs: {<0>}
                  spids: [2137]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:feb_result_)
                  op: assign_op.Equal
                  rhs: (word.Empty)
                  spids: [2141]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:feb_sp_)
                  op: assign_op.Equal
                  rhs: (word.Empty)
                  spids: [2144]
                )
              ]
            )
            (command.ForEach
              iter_name: feb_file_
              iter_words: [{($ Id.VSub_DollarName '$feb_dir_') <'/'> <Id.Lit_Star '*'> <.exe>}]
              do_arg_iter: F
              body: 
                (command.DoGroup
                  children: [
                    (command.AndOr
                      ops: [Id.Op_DAmp Id.Op_DAmp]
                      children: [
                        (C {<test>} {(DQ <x> ($ Id.VSub_DollarName '$feb_file_'))} {<Id.Lit_Equals '='>} 
                          {(DQ <x> ($ Id.VSub_DollarName '$feb_dir_') <'/*.exe'>)}
                        )
                        (C {<test>} {<Id.KW_Bang '!'>} {<-f>} {(DQ ($ Id.VSub_DollarName '$feb_file_'))})
                        (command.ControlFlow
                          token: <Id.ControlFlow_Continue continue>
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<test>} {(DQ <x> ($ Id.VSub_DollarName '$feb_file_'))} {<Id.Lit_Equals '='>} 
                          {(DQ <x> ($ Id.VSub_DollarName '$feb_dir_') <'/[.exe'>)}
                        )
                        (command.ControlFlow
                          token: <Id.ControlFlow_Continue continue>
                        )
                      ]
                    )
                    (command.Case
                      to_match: {($ Id.VSub_DollarName '$feb_file_')}
                      arms: [
                        (case_arm
                          pat_list: [
                            {<Id.Lit_Star '*'> <Id.Lit_LBracket '['> <Id.KW_Bang '!'> <'-a-zA-Z/0-9_.'> 
                              <Id.Lit_Other '+'> <Id.Lit_RBracket ']'> <Id.Lit_Star '*'>
                            }
                          ]
                          action: [
                            (command.Sentence
                              child: 
                                (command.ShAssignment
                                  pairs: [
                                    (assign_pair
                                      lhs: (sh_lhs_expr.Name name:feb_fail_)
                                      op: assign_op.Equal
                                      rhs: {<1>}
                                      spids: [2252]
                                    )
                                  ]
                                )
                              terminator: <Id.Op_Semi _>
                            )
                            (command.ControlFlow
                              token: <Id.ControlFlow_Break break>
                            )
                          ]
                          spids: [2243 2250 2257 -1]
                        )
                        (case_arm
                          pat_list: [{<Id.Lit_Star '*'>}]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:feb_file_)
                                  op: assign_op.Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <Id.VSub_Name feb_file_>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            tok: <Id.VOp1_DPound '##'>
                                            arg_word: {<Id.Lit_Other '*'> <Id.Lit_Slash '/'>}
                                          )
                                      )
                                    }
                                  spids: [2267]
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:feb_file_)
                                  op: assign_op.Equal
                                  rhs: 
                                    {
                                      (braced_var_sub
                                        token: <Id.VSub_Name feb_file_>
                                        suffix_op: 
                                          (suffix_op.Unary
                                            tok: <Id.VOp1_Percent '%'>
                                            arg_word: {<.exe>}
                                          )
                                      )
                                    }
                                  spids: [2276]
                                )
                              ]
                            )
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:feb_result_)
                                  op: assign_op.Equal
                                  rhs: 
                                    {
                                      (DQ ($ Id.VSub_DollarName '$feb_result_') 
                                        ($ Id.VSub_DollarName '$feb_sp_') ($ Id.VSub_DollarName '$feb_file_')
                                      )
                                    }
                                  spids: [2284]
                                )
                              ]
                            )
                          ]
                          spids: [2260 2261 2290 -1]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:feb_sp_)
                          op: assign_op.Equal
                          rhs: {(SQ <' '>)}
                          spids: [2296]
                        )
                      ]
                    )
                  ]
                )
            )
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<test>} {($ Id.VSub_DollarName '$feb_fail_')} {<Id.Lit_Equals '='>} {<0>})
                (C {<printf>} {<Id.Lit_Other '%'> <s>} {(DQ ($ Id.VSub_DollarName '$feb_result_'))})
              ]
            )
            (command.ControlFlow
              token: <Id.ControlFlow_Return return>
              arg_word: {($ Id.VSub_DollarName '$feb_fail_')}
            )
          ]
        )
    )
    (command.ShFunction
      name: create_exe_shims_
      body: 
        (BraceGroup
          children: [
            (command.Case
              to_match: {($ Id.VSub_DollarName '$EXEEXT')}
              arms: [
                (case_arm
                  pat_list: [{(SQ )}]
                  action: [(command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<0>})]
                  spids: [2362 2364 2370 -1]
                )
                (case_arm pat_list:[{<.exe>}] spids:[2373 2374 2376 -1])
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [
                    (command.Sentence
                      child: 
                        (command.Simple
                          words: [
                            {<echo>}
                            {
                              (DQ ($ Id.VSub_Number '$0') <': unexpected '> 
                                (word_part.EscapedLiteral
                                  token: <Id.Lit_EscapedChar '\\$'>
                                ) <'EXEEXT value: '> ($ Id.VSub_DollarName '$EXEEXT')
                              )
                            }
                          ]
                          redirects: [
                            (redir
                              op: <Id.Redir_GreatAnd '1>&'>
                              loc: (redir_loc.Fd fd:1)
                              arg: {<2>}
                            )
                          ]
                          do_fork: T
                        )
                      terminator: <Id.Op_Semi _>
                    )
                    (command.ControlFlow
                      token: <Id.ControlFlow_Return return>
                      arg_word: {<1>}
                    )
                  ]
                  spids: [2379 2380 2400 -1]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:base_names_)
                      op: assign_op.Equal
                      rhs: 
                        {
                          (command_sub
                            left_token: <Id.Left_Backtick '`'>
                            child: (C {<find_exe_basenames_>} {($ Id.VSub_Number '$1')})
                          )
                        }
                      spids: [2407]
                    )
                  ]
                )
                (BraceGroup
                  children: [
                    (command.Sentence
                      child: 
                        (command.Simple
                          words: [
                            {<echo>}
                            {
                              (DQ ($ Id.VSub_Number '$0') <' (exe_shim): skipping directory: '> 
                                ($ Id.VSub_Number '$1')
                              )
                            }
                          ]
                          redirects: [
                            (redir
                              op: <Id.Redir_GreatAnd '1>&'>
                              loc: (redir_loc.Fd fd:1)
                              arg: {<2>}
                            )
                          ]
                          do_fork: T
                        )
                      terminator: <Id.Op_Semi _>
                    )
                    (command.Sentence
                      child: (command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<0>})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: (C {<test>} {<-n>} {(DQ ($ Id.VSub_DollarName '$base_names_'))})
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.ForEach
                      iter_name: base_
                      iter_words: [{($ Id.VSub_DollarName '$base_names_')}]
                      do_arg_iter: F
                      body: 
                        (command.DoGroup
                          children: [
                            (C {<alias>} 
                              {(DQ ($ Id.VSub_DollarName '$base_')) <Id.Lit_Equals '='> 
                                (DQ ($ Id.VSub_DollarName '$base_') ($ Id.VSub_DollarName '$EXEEXT'))
                              }
                            )
                          ]
                        )
                    )
                  ]
                  spids: [2443 2454]
                )
              ]
            )
            (command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<0>})
          ]
        )
    )
    (command.ShFunction
      name: path_prepend_
      body: 
        (BraceGroup
          children: [
            (command.WhileUntil
              keyword: <Id.KW_While while>
              cond: 
                (condition.Shell
                  commands: [
                    (command.Sentence
                      child: 
                        (C {<test>} {($ Id.VSub_Pound '$#')} {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<0>})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              body: 
                (command.DoGroup
                  children: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:path_dir_)
                          op: assign_op.Equal
                          rhs: {($ Id.VSub_Number '$1')}
                          spids: [2524]
                        )
                      ]
                    )
                    (command.Case
                      to_match: {($ Id.VSub_DollarName '$path_dir_')}
                      arms: [
                        (case_arm
                          pat_list: [{(SQ )}]
                          action: [
                            (C {<fail_>} {(DQ <'invalid path dir: \''> ($ Id.VSub_Number '$1') <'\''>)})
                          ]
                          spids: [2535 2537 2546 -1]
                        )
                        (case_arm
                          pat_list: [{<'/'> <Id.Lit_Star '*'>}]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:abs_path_dir_)
                                  op: assign_op.Equal
                                  rhs: {($ Id.VSub_DollarName '$path_dir_')}
                                  spids: [2553]
                                )
                              ]
                            )
                          ]
                          spids: [2549 2551 2555 -1]
                        )
                        (case_arm
                          pat_list: [{<Id.Lit_Star '*'>}]
                          action: [
                            (command.ShAssignment
                              pairs: [
                                (assign_pair
                                  lhs: (sh_lhs_expr.Name name:abs_path_dir_)
                                  op: assign_op.Equal
                                  rhs: 
                                    {($ Id.VSub_DollarName '$initial_cwd_') <'/'> 
                                      ($ Id.VSub_DollarName '$path_dir_')
                                    }
                                  spids: [2561]
                                )
                              ]
                            )
                          ]
                          spids: [2558 2559 2565 -1]
                        )
                      ]
                    )
                    (command.Case
                      to_match: {($ Id.VSub_DollarName '$abs_path_dir_')}
                      arms: [
                        (case_arm
                          pat_list: [{<Id.Lit_Star '*'> <Id.Lit_Colon ':'> <Id.Lit_Star '*'>}]
                          action: [
                            (C {<fail_>} 
                              {
                                (DQ <'invalid path dir: \''> ($ Id.VSub_DollarName '$abs_path_dir_') 
                                  <'\''>
                                )
                              }
                            )
                          ]
                          spids: [2578 2581 2590 -1]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:PATH)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (DQ ($ Id.VSub_DollarName '$abs_path_dir_') <':'> 
                                ($ Id.VSub_DollarName '$PATH')
                              )
                            }
                          spids: [2596]
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [
                        (C {<create_exe_shims_>} {(DQ ($ Id.VSub_DollarName '$abs_path_dir_'))})
                        (C {<fail_>} 
                          {
                            (DQ <'something failed (above): '> ($ Id.VSub_DollarName '$abs_path_dir_'))
                          }
                        )
                      ]
                    )
                    (C {<shift>})
                  ]
                )
            )
            (C {<export>} {<PATH>})
          ]
        )
    )
    (command.ShFunction
      name: setup_
      body: 
        (BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<test>} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} {<Id.Lit_Equals '='>} 
                              {<yes>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: 
                            (condition.Shell
                              commands: [
                                (command.Sentence
                                  child: (C {($ Id.VSub_DollarName '$gl_set_x_corrupts_stderr_')})
                                  terminator: <Id.Op_Semi _>
                                )
                              ]
                            )
                          action: [
                            (C {<warn_>} 
                              {
                                (DQ <'using SHELL='> ($ Id.VSub_DollarName '$SHELL') 
                                  <' with \'set -x\' corrupts stderr'>
                                )
                              }
                            )
                          ]
                          spids: [2684 2689]
                        )
                      ]
                      else_action: [(C {<set>} {<-x>})]
                    )
                  ]
                  spids: [2648 2661]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:initial_cwd_)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_DollarName '$PWD')}
                  spids: [2716]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:fail)
                  op: assign_op.Equal
                  rhs: {<0>}
                  spids: [2720]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:pfx_)
                  op: assign_op.Equal
                  rhs: {(command_sub left_token:<Id.Left_Backtick '`'> child:(C {<testdir_prefix_>}))}
                  spids: [2725]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:test_dir_)
                      op: assign_op.Equal
                      rhs: 
                        {
                          (command_sub
                            left_token: <Id.Left_Backtick '`'>
                            child: 
                              (C {<mktempd_>} {(DQ ($ Id.VSub_DollarName '$initial_cwd_'))} 
                                {
                                  (DQ ($ Id.VSub_DollarName '$pfx_') <-> ($ Id.VSub_DollarName '$ME_') 
                                    <.XXXX>
                                  )
                                }
                              )
                          )
                        }
                      spids: [2733]
                    )
                  ]
                )
                (C {<fail_>} 
                  {
                    (DQ <'failed to create temporary directory in '> 
                      ($ Id.VSub_DollarName '$initial_cwd_')
                    )
                  }
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<cd>} {(DQ ($ Id.VSub_DollarName '$test_dir_'))})
                (C {<fail_>} {(DQ <'failed to cd to temporary directory'>)})
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:gl_init_sh_nl_)
                  op: assign_op.Equal
                  rhs: {(SQ <'\n'>)}
                  spids: [2787]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:IFS)
                  op: assign_op.Equal
                  rhs: {(DQ <' '>) (DQ <'\t'> ($ Id.VSub_DollarName '$gl_init_sh_nl_'))}
                  spids: [2793]
                )
              ]
            )
            (command.ForEach
              iter_name: sig_
              iter_words: [{<1>} {<2>} {<3>} {<13>} {<15>}]
              do_arg_iter: F
              body: 
                (command.DoGroup
                  children: [
                    (C {<eval>} 
                      {
                        (DQ <'trap \'Exit '> 
                          (command_sub
                            left_token: <Id.Left_DollarParen '$('>
                            child: 
                              (C {<expr>} {($ Id.VSub_DollarName '$sig_')} {<Id.Lit_Other '+'>} {<128>})
                          ) <'\' '> ($ Id.VSub_DollarName '$sig_')
                        )
                      }
                    )
                  ]
                )
            )
          ]
        )
    )
    (command.ShFunction
      name: rand_bytes_
      body: 
        (BraceGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:n_)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_Number '$1')}
                  spids: [2913]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:chars_)
                  op: assign_op.Equal
                  rhs: {<abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789>}
                  spids: [2927]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:dev_rand_)
                  op: assign_op.Equal
                  rhs: {<'/dev/urandom'>}
                  spids: [2931]
                )
              ]
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: (C {<test>} {<-r>} {(DQ ($ Id.VSub_DollarName '$dev_rand_'))})
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.Pipeline
                      children: [
                        (command.Simple
                          words: [
                            {<dd>}
                            {<Id.Lit_VarLike 'ibs='> ($ Id.VSub_DollarName '$n_')}
                            {<Id.Lit_VarLike 'count='> <1>}
                            {<Id.Lit_VarLike 'if='> ($ Id.VSub_DollarName '$dev_rand_')}
                          ]
                          redirects: [
                            (redir
                              op: <Id.Redir_Great '2>'>
                              loc: (redir_loc.Fd fd:2)
                              arg: {<'/dev/null'>}
                            )
                          ]
                          do_fork: T
                        )
                        (command.Simple
                          words: [
                            {<tr>}
                            {<-c>}
                            {($ Id.VSub_DollarName '$chars_')}
                            {<01234567> ($ Id.VSub_DollarName '$chars_') 
                              ($ Id.VSub_DollarName '$chars_') ($ Id.VSub_DollarName '$chars_')
                            }
                          ]
                          more_env: [(env_pair name:LC_ALL val:{<C>} spids:[2971])]
                          do_fork: T
                        )
                      ]
                      negated: F
                    )
                    (command.ControlFlow token:<Id.ControlFlow_Return return>)
                  ]
                  spids: [2935 2946]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:n_plus_50_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: (C {<expr>} {($ Id.VSub_DollarName '$n_')} {<Id.Lit_Other '+'>} {<50>})
                      )
                    }
                  spids: [2993]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:cmds_)
                  op: assign_op.Equal
                  rhs: {(SQ <'date; date +%N; free; who -a; w; ps auxww; ps ef; netstat -n'>)}
                  spids: [3007]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:data_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (command.Pipeline
                            children: [
                              (command.Subshell
                                child: (C {<eval>} {(DQ ($ Id.VSub_DollarName '$cmds_'))})
                                redirects: [
                                  (redir
                                    op: <Id.Redir_GreatAnd '2>&'>
                                    loc: (redir_loc.Fd fd:2)
                                    arg: {<1>}
                                  )
                                ]
                              )
                              (C {<gzip>})
                            ]
                            negated: F
                          )
                      )
                    }
                  spids: [3013]
                )
              ]
            )
            (command.WhileUntil
              keyword: <Id.KW_While while>
              cond: 
                (condition.Shell
                  commands: [
                    (command.Sentence
                      child: (C {<Id.Lit_Colon ':'>})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              body: 
                (command.DoGroup
                  children: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:len_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Id.Left_Backtick '`'>
                                child: 
                                  (command.Pipeline
                                    children: [
                                      (C {<echo>} {(DQ ($ Id.VSub_DollarName '$data_'))})
                                      (C {<wc>} {<-c>})
                                    ]
                                    negated: F
                                  )
                              )
                            }
                          spids: [3049]
                        )
                      ]
                    )
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Id.Op_DAmp]
                          children: [
                            (C {<test>} {($ Id.VSub_DollarName '$n_plus_50_')} {<-le>} 
                              {($ Id.VSub_DollarName '$len_')}
                            )
                            (command.ControlFlow
                              token: <Id.ControlFlow_Break break>
                            )
                          ]
                        )
                      terminator: <Id.Op_Semi _>
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:data_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Id.Left_Backtick '`'>
                                child: 
                                  (command.Pipeline
                                    children: [
                                      (command.Subshell
                                        child: 
                                          (command.CommandList
                                            children: [
                                              (command.Sentence
                                                child: 
                                                  (C {<echo>} {(DQ ($ Id.VSub_DollarName '$data_'))})
                                                terminator: <Id.Op_Semi _>
                                              )
                                              (C {<eval>} {(DQ ($ Id.VSub_DollarName '$cmds_'))})
                                            ]
                                          )
                                        redirects: [
                                          (redir
                                            op: <Id.Redir_GreatAnd '2>&'>
                                            loc: (redir_loc.Fd fd:2)
                                            arg: {<1>}
                                          )
                                        ]
                                      )
                                      (C {<gzip>})
                                    ]
                                    negated: F
                                  )
                              )
                            }
                          spids: [3079]
                        )
                      ]
                    )
                  ]
                )
            )
            (command.Pipeline
              children: [
                (C {<echo>} {(DQ ($ Id.VSub_DollarName '$data_'))})
                (command.Simple
                  words: [
                    {<dd>}
                    {<Id.Lit_VarLike 'bs='> <1>}
                    {<Id.Lit_VarLike 'skip='> <50>}
                    {<Id.Lit_VarLike 'count='> ($ Id.VSub_DollarName '$n_')}
                  ]
                  redirects: [
                    (redir
                      op: <Id.Redir_Great '2>'>
                      loc: (redir_loc.Fd fd:2)
                      arg: {<'/dev/null'>}
                    )
                  ]
                  do_fork: T
                )
                (command.Simple
                  words: [
                    {<tr>}
                    {<-c>}
                    {($ Id.VSub_DollarName '$chars_')}
                    {<01234567> ($ Id.VSub_DollarName '$chars_') ($ Id.VSub_DollarName '$chars_') 
                      ($ Id.VSub_DollarName '$chars_')
                    }
                  ]
                  more_env: [(env_pair name:LC_ALL val:{<C>} spids:[3141])]
                  do_fork: T
                )
              ]
              negated: F
            )
          ]
        )
    )
    (command.ShFunction
      name: mktempd_
      body: 
        (BraceGroup
          children: [
            (command.Case
              to_match: {($ Id.VSub_Pound '$#')}
              arms: [
                (case_arm pat_list:[{<2>}] spids:[3173 3174 3175 -1])
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [(C {<fail_>} {(DQ <'Usage: mktempd_ DIR TEMPLATE'>)})]
                  spids: [3178 3179 3186 -1]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:destdir_)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_Number '$1')}
                  spids: [3193]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:template_)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_Number '$2')}
                  spids: [3197]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:MAX_TRIES_)
                  op: assign_op.Equal
                  rhs: {<4>}
                  spids: [3202]
                )
              ]
            )
            (command.Case
              to_match: {($ Id.VSub_DollarName '$destdir_')}
              arms: [
                (case_arm pat_list:[{<'/'>}] spids:[3222 3223 3225 -1])
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'> <'/'>}]
                  action: [(C {<fail_>} {(DQ <'invalid destination dir: remove trailing slash(es)'>)})]
                  spids: [3228 3230 3237 -1]
                )
              ]
            )
            (command.Case
              to_match: {($ Id.VSub_DollarName '$template_')}
              arms: [
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'> <XXXX>}]
                  spids: [3251 3253 3255 -1]
                )
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [
                    (C {<fail_>} 
                      {
                        (DQ <'invalid template: '> ($ Id.VSub_DollarName '$template_') 
                          <' (must have a suffix of at least 4 X\'s)'>
                        )
                      }
                    )
                  ]
                  spids: [3258 3259 3270 -1]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:d)
                      op: assign_op.Equal
                      rhs: 
                        {
                          (command_sub
                            left_token: <Id.Left_Backtick '`'>
                            child: 
                              (command.CommandList
                                children: [
                                  (command.Sentence
                                    child: (C {<unset>} {<TMPDIR>})
                                    terminator: <Id.Op_Semi _>
                                  )
                                  (BraceGroup
                                    children: [
                                      (command.Sentence
                                        child: 
                                          (C {<mktemp>} {<-d>} {<-t>} {<-p>} 
                                            {(DQ ($ Id.VSub_DollarName '$destdir_'))} {(DQ ($ Id.VSub_DollarName '$template_'))}
                                          )
                                        terminator: <Id.Op_Semi _>
                                      )
                                    ]
                                    redirects: [
                                      (redir
                                        op: <Id.Redir_Great '2>'>
                                        loc: (redir_loc.Fd fd:2)
                                        arg: {<'/dev/null'>}
                                      )
                                    ]
                                  )
                                ]
                              )
                          )
                        }
                      spids: [3281]
                    )
                  ]
                )
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:fail)
                      op: assign_op.Equal
                      rhs: {<1>}
                      spids: [3319]
                    )
                  ]
                )
              ]
            )
            (command.Case
              to_match: {($ Id.VSub_DollarName '$d')}
              arms: [
                (case_arm
                  pat_list: [{(DQ ($ Id.VSub_DollarName '$destdir_')) <Id.Lit_Star '*'>}]
                  spids: [3334 3338 3339 -1]
                )
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:fail)
                          op: assign_op.Equal
                          rhs: {<1>}
                          spids: [3344]
                        )
                      ]
                    )
                  ]
                  spids: [3341 3342 3346 -1]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<test>} {<-d>} {(DQ ($ Id.VSub_DollarName '$d'))})
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:fail)
                      op: assign_op.Equal
                      rhs: {<1>}
                      spids: [3366]
                    )
                  ]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:perms)
                      op: assign_op.Equal
                      rhs: 
                        {
                          (command_sub
                            left_token: <Id.Left_Backtick '`'>
                            child: 
                              (command.Pipeline
                                children: [
                                  (command.Simple
                                    words: [{<ls>} {<-dgo>} {(DQ ($ Id.VSub_DollarName '$d'))}]
                                    redirects: [
                                      (redir
                                        op: <Id.Redir_Great '2>'>
                                        loc: (redir_loc.Fd fd:2)
                                        arg: {<'/dev/null'>}
                                      )
                                    ]
                                    do_fork: T
                                  )
                                  (C {<tr>} {<S>} {<->})
                                ]
                                negated: F
                              )
                          )
                        }
                      spids: [3375]
                    )
                  ]
                )
                (command.ShAssignment
                  pairs: [
                    (assign_pair
                      lhs: (sh_lhs_expr.Name name:fail)
                      op: assign_op.Equal
                      rhs: {<1>}
                      spids: [3399]
                    )
                  ]
                )
              ]
            )
            (command.Case
              to_match: {($ Id.VSub_DollarName '$perms')}
              arms: [
                (case_arm
                  pat_list: [{<drwx------> <Id.Lit_Star '*'>}]
                  spids: [3409 3411 3413 -1]
                )
                (case_arm
                  pat_list: [{<Id.Lit_Star '*'>}]
                  action: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:fail)
                          op: assign_op.Equal
                          rhs: {<1>}
                          spids: [3418]
                        )
                      ]
                    )
                  ]
                  spids: [3415 3416 3420 -1]
                )
              ]
            )
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<test>} {($ Id.VSub_DollarName '$fail')} {<Id.Lit_Equals '='>} {<0>})
                (BraceGroup
                  children: [
                    (C {<echo>} {(DQ ($ Id.VSub_DollarName '$d'))})
                    (command.ControlFlow token:<Id.ControlFlow_Return return>)
                  ]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:base_template_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<echo>} {(DQ ($ Id.VSub_DollarName '$template_'))})
                              (C {<sed>} {(SQ <'s/XX*$//'>)})
                            ]
                            negated: F
                          )
                      )
                    }
                  spids: [3462]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:template_length_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<echo>} {(DQ ($ Id.VSub_DollarName '$template_'))})
                              (C {<wc>} {<-c>})
                            ]
                            negated: F
                          )
                      )
                    }
                  spids: [3485]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:nx_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<echo>} {(DQ ($ Id.VSub_DollarName '$base_template_'))})
                              (C {<wc>} {<-c>})
                            ]
                            negated: F
                          )
                      )
                    }
                  spids: [3503]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:nx_)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (C {<expr>} {($ Id.VSub_DollarName '$template_length_')} {<->} 
                            {($ Id.VSub_DollarName '$nx_')}
                          )
                      )
                    }
                  spids: [3521]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:err_)
                  op: assign_op.Equal
                  rhs: (word.Empty)
                  spids: [3536]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:i_)
                  op: assign_op.Equal
                  rhs: {<1>}
                  spids: [3539]
                )
              ]
            )
            (command.WhileUntil
              keyword: <Id.KW_While while>
              cond: 
                (condition.Shell
                  commands: [
                    (command.Sentence
                      child: (C {<Id.Lit_Colon ':'>})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              body: 
                (command.DoGroup
                  children: [
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:X_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Id.Left_Backtick '`'>
                                child: (C {<rand_bytes_>} {($ Id.VSub_DollarName '$nx_')})
                              )
                            }
                          spids: [3551]
                        )
                      ]
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:candidate_dir_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (DQ ($ Id.VSub_DollarName '$destdir_') <'/'> 
                                ($ Id.VSub_DollarName '$base_template_') ($ Id.VSub_DollarName '$X_')
                              )
                            }
                          spids: [3561]
                        )
                      ]
                    )
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (command.ShAssignment
                          pairs: [
                            (assign_pair
                              lhs: (sh_lhs_expr.Name name:err_)
                              op: assign_op.Equal
                              rhs: 
                                {
                                  (command_sub
                                    left_token: <Id.Left_Backtick '`'>
                                    child: 
                                      (command.Simple
                                        words: [
                                          {<mkdir>}
                                          {<-m>}
                                          {<0700>}
                                          {(DQ ($ Id.VSub_DollarName '$candidate_dir_'))}
                                        ]
                                        redirects: [
                                          (redir
                                            op: <Id.Redir_GreatAnd '2>&'>
                                            loc: (redir_loc.Fd fd:2)
                                            arg: {<1>}
                                          )
                                        ]
                                        do_fork: T
                                      )
                                  )
                                }
                              spids: [3570]
                            )
                          ]
                        )
                        (BraceGroup
                          children: [
                            (command.Sentence
                              child: (C {<echo>} {(DQ ($ Id.VSub_DollarName '$candidate_dir_'))})
                              terminator: <Id.Op_Semi _>
                            )
                            (command.Sentence
                              child: (command.ControlFlow token:<Id.ControlFlow_Return return>)
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      ]
                    )
                    (command.Sentence
                      child: 
                        (command.AndOr
                          ops: [Id.Op_DAmp]
                          children: [
                            (C {<test>} {($ Id.VSub_DollarName '$MAX_TRIES_')} {<-le>} 
                              {($ Id.VSub_DollarName '$i_')}
                            )
                            (command.ControlFlow
                              token: <Id.ControlFlow_Break break>
                            )
                          ]
                        )
                      terminator: <Id.Op_Semi _>
                    )
                    (command.ShAssignment
                      pairs: [
                        (assign_pair
                          lhs: (sh_lhs_expr.Name name:i_)
                          op: assign_op.Equal
                          rhs: 
                            {
                              (command_sub
                                left_token: <Id.Left_Backtick '`'>
                                child: 
                                  (C {<expr>} {($ Id.VSub_DollarName '$i_')} {<Id.Lit_Other '+'>} {<1>})
                              )
                            }
                          spids: [3621]
                        )
                      ]
                    )
                  ]
                )
            )
            (C {<fail_>} {(DQ ($ Id.VSub_DollarName '$err_'))})
          ]
        )
    )
    (command.AndOr
      ops: [Id.Op_DAmp]
      children: [
        (C {<test>} {<-f>} {(DQ ($ Id.VSub_DollarName '$srcdir') <'/init.cfg'>)})
        (C {<.>} {(DQ ($ Id.VSub_DollarName '$srcdir') <'/init.cfg'>)})
      ]
    )
    (C {<setup_>} {(DQ ($ Id.VSub_At '$@'))})
    (C {<trap>} {<remove_tmp_>} {<0>})
  ]
)