(command.CommandList
  children: [
    (command.ShFunction
      name: check
      body: 
        (BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Pipeline
                          children: [
                            (C {<grep>} {<-q>} {(DQ ($ Id.VSub_Number '$2'))} 
                              {(DQ ($ Id.VSub_Number '$1'))}
                            )
                          ]
                          negated: T
                        )
                      ]
                    )
                  action: [
                    (C {<echo>} {(DQ <'Did not find expected output:'>)})
                    (C {<echo>} {(DQ <'   '> ($ Id.VSub_Number '$2'))})
                    (C {<echo>} {(DQ )})
                    (C {<echo>} {(DQ <'Actual error output below:'>)})
                    (C {<cat>} {(DQ ($ Id.VSub_Number '$1'))})
                    (command.ControlFlow
                      token: <Id.ControlFlow_Exit exit>
                      arg_word: {<1>}
                    )
                  ]
                  spids: [65 82]
                )
              ]
            )
          ]
        )
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:STDOUT)
          op: assign_op.Equal
          rhs: {<gdb_index_test_3.stdout>}
          spids: [130]
        )
      ]
    )
    (C {<check>} {($ Id.VSub_DollarName '$STDOUT')} {(DQ <'^Version [4-7]'>)})
    (C {<check>} {($ Id.VSub_DollarName '$STDOUT')} 
      {(DQ <'^'> <Id.Lit_BadBackslash '\\'> <'[ *[0-9]*'> <Id.Lit_BadBackslash '\\'> <'] main:'>)}
    )
    (C {<check>} {($ Id.VSub_DollarName '$STDOUT')} 
      {
        (DQ <'^'> <Id.Lit_BadBackslash '\\'> <'[ *[0-9]*'> <Id.Lit_BadBackslash '\\'> <'] check_int:'>)
      }
    )
    (C {<check>} {($ Id.VSub_DollarName '$STDOUT')} 
      {(DQ <'^'> <Id.Lit_BadBackslash '\\'> <'[ *[0-9]*'> <Id.Lit_BadBackslash '\\'> <'] j:'>)}
    )
    (C {<check>} {($ Id.VSub_DollarName '$STDOUT')} 
      {(DQ <'^'> <Id.Lit_BadBackslash '\\'> <'[ *[0-9]*'> <Id.Lit_BadBackslash '\\'> <'] int:'>)}
    )
    (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>})
  ]
)