(CommandList
  children: [
    (AndOr
      children: [
        (FuncDef
          name: _pkg_config
          body: 
            (BraceGroup
              children: [
                (Assignment
                  keyword: Assign_Local
                  pairs: [
                    (assign_pair lhs:(LhsName name:cur) op:Equal spids:[13])
                    (assign_pair lhs:(LhsName name:prev) op:Equal spids:[15])
                    (assign_pair lhs:(LhsName name:words) op:Equal spids:[17])
                    (assign_pair lhs:(LhsName name:cword) op:Equal spids:[19])
                    (assign_pair lhs:(LhsName name:split) op:Equal spids:[21])
                  ]
                  spids: [11]
                )
                (AndOr
                  children: [
                    (C {(_init_completion)} {(-s)})
                    (ControlFlow token:<ControlFlow_Return return>)
                  ]
                  op_id: Op_DPipe
                )
                (Case
                  to_match: {($ VSub_Name '$prev')}
                  arms: [
                    (case_arm
                      pat_list: [
                        {(--define-variable)}
                        {(--atleast-version)}
                        {(--atleast-pkgconfig-version)}
                        {(--exact-version)}
                        {(--max-version)}
                      ]
                      action: [(ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})]
                      spids: [41 53 65 16777215]
                    )
                    (case_arm
                      pat_list: [{(--variable)}]
                      action: [
                        (Assignment
                          keyword: Assign_Local
                          pairs: [(assign_pair lhs:(LhsName name:i) op:Equal spids:[74])]
                          spids: [72]
                        )
                        (ForExpr
                          init: 
                            (BinaryAssign
                              op_id: Arith_Equal
                              left: (LhsName name:i)
                              right: (ArithWord w:{(Lit_Digits 1)})
                            )
                          cond: 
                            (ArithBinary
                              op_id: Arith_Less
                              left: (ArithVarRef name:i)
                              right: 
                                (ArithWord
                                  w: 
                                    {
                                      (BracedVarSub
                                        token: <VSub_Name words>
                                        prefix_op: VSub_Pound
                                        bracket_op: (WholeArray op_id:Lit_At)
                                        spids: [90 96]
                                      )
                                    }
                                )
                            )
                          update: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:i))
                          body: 
                            (DoGroup
                              children: [
                                (If
                                  arms: [
                                    (if_arm
                                      cond: [
                                        (Sentence
                                          child: 
                                            (DBracket
                                              expr: 
                                                (BoolBinary
                                                  op_id: BoolBinary_GlobNEqual
                                                  left: 
                                                    {
                                                      (BracedVarSub
                                                        token: <VSub_Name words>
                                                        bracket_op: 
                                                          (ArrayIndex
                                                            expr: (ArithVarRef name:i)
                                                          )
                                                        spids: [113 118]
                                                      )
                                                    }
                                                  right: {(-) (Lit_Other '*')}
                                                )
                                            )
                                          terminator: <Op_Semi ';'>
                                        )
                                      ]
                                      action: [
                                        (Assignment
                                          keyword: Assign_None
                                          pairs: [
                                            (assign_pair
                                              lhs: (LhsName name:COMPREPLY)
                                              op: Equal
                                              rhs: 
                                                {
                                                  (ArrayLiteralPart
                                                    words: [
                                                      {
                                                        (CommandSubPart
                                                          command_list: 
                                                            (CommandList
                                                              children: [
                                                                (C {(compgen)} {(-W)} 
                                                                  {
                                                                    (SQ 
                                                                      <
'$( "$1" ${words[i]} --print-variables 2>/dev/null )'
                                                                      >
                                                                    )
                                                                  } {(--)} {(DQ ($ VSub_Name '$cur'))}
                                                                )
                                                              ]
                                                            )
                                                          left_token: <Left_CommandSub '$('>
                                                          spids: [134 154]
                                                        )
                                                      }
                                                    ]
                                                  )
                                                }
                                              spids: [131]
                                            )
                                          ]
                                          spids: [131]
                                        )
                                        (ControlFlow
                                          token: <ControlFlow_Break break>
                                        )
                                      ]
                                      spids: [16777215 128]
                                    )
                                  ]
                                  spids: [16777215 162]
                                )
                              ]
                              spids: [106 165]
                            )
                        )
                        (ControlFlow
                          token: <ControlFlow_Return return>
                          arg_word: {(0)}
                        )
                      ]
                      spids: [68 69 173 16777215]
                    )
                    (case_arm
                      pat_list: [
                        {(-) (EscapedLiteralPart token:<Lit_EscapedChar '\\?'>)}
                        {(--help)}
                        {(--version)}
                        {(--usage)}
                      ]
                      action: [(ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})]
                      spids: [176 184 196 16777215]
                    )
                  ]
                  spids: [34 38 199]
                )
                (AndOr
                  children: [
                    (C {($ VSub_Name '$split')})
                    (ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})
                  ]
                  op_id: Op_DAmp
                )
                (If
                  arms: [
                    (if_arm
                      cond: [
                        (Sentence
                          child: 
                            (DBracket
                              expr: 
                                (BoolBinary
                                  op_id: BoolBinary_GlobDEqual
                                  left: {(DQ ($ VSub_Name '$cur'))}
                                  right: {(-) (Lit_Other '*')}
                                )
                            )
                          terminator: <Op_Semi ';'>
                        )
                      ]
                      action: [
                        (Assignment
                          keyword: Assign_None
                          pairs: [
                            (assign_pair
                              lhs: (LhsName name:COMPREPLY)
                              op: Equal
                              rhs: 
                                {
                                  (ArrayLiteralPart
                                    words: [
                                      {
                                        (CommandSubPart
                                          command_list: 
                                            (CommandList
                                              children: [
                                                (C {(compgen)} {(-W)} {(SQ <'$( _parse_help "$1" )'>)} 
                                                  {(--)} {(DQ ($ VSub_Name '$cur'))}
                                                )
                                              ]
                                            )
                                          left_token: <Left_CommandSub '$('>
                                          spids: [235 251]
                                        )
                                      }
                                    ]
                                  )
                                }
                              spids: [232]
                            )
                          ]
                          spids: [232]
                        )
                        (AndOr
                          children: [
                            (DBracket
                              expr: 
                                (BoolBinary
                                  op_id: BoolBinary_GlobDEqual
                                  left: {($ VSub_Name '$COMPREPLY')}
                                  right: {(Lit_Other '*') (BoolBinary_GlobEqual '=')}
                                )
                            )
                            (C {(compopt)} {(-o)} {(nospace)})
                          ]
                          op_id: Op_DAmp
                        )
                      ]
                      spids: [16777215 229]
                    )
                  ]
                  else_action: [
                    (Assignment
                      keyword: Assign_None
                      pairs: [
                        (assign_pair
                          lhs: (LhsName name:COMPREPLY)
                          op: Equal
                          rhs: 
                            {
                              (ArrayLiteralPart
                                words: [
                                  {
                                    (CommandSubPart
                                      command_list: 
                                        (CommandList
                                          children: [
                                            (C {(compgen)} {(-W)} 
                                              {
                                                (DQ 
                                                  (CommandSubPart
                                                    command_list: 
                                                      (CommandList
                                                        children: [
                                                          (Pipeline
                                                            children: [
                                                              (SimpleCommand
                                                                words: [
                                                                  {($ VSub_Number '$1')}
                                                                  {(--list-all)}
                                                                ]
                                                                redirects: [
                                                                  (Redir
                                                                    op_id: Redir_Great
                                                                    fd: 2
                                                                    arg_word: {(/dev/null)}
                                                                    spids: [297]
                                                                  )
                                                                ]
                                                              )
                                                              (C {(awk)} {(SQ <'{print $1}'>)})
                                                            ]
                                                            negated: False
                                                          )
                                                        ]
                                                      )
                                                    left_token: <Left_CommandSub '$('>
                                                    spids: [289 308]
                                                  )
                                                )
                                              } {(--)} {(DQ ($ VSub_Name '$cur'))}
                                            )
                                          ]
                                        )
                                      left_token: <Left_CommandSub '$('>
                                      spids: [282 317]
                                    )
                                  }
                                ]
                              )
                            }
                          spids: [279]
                        )
                      ]
                      spids: [279]
                    )
                  ]
                  spids: [276 322]
                )
              ]
              spids: [8]
            )
          spids: [4 7]
        )
        (C {(complete)} {(-F)} {(_pkg_config)} {(pkg-config)})
      ]
      op_id: Op_DAmp
    )
  ]
)