(CommandList
  children: [
    (FuncDef
      name: validAlphaNum
      body: 
        (BraceGroup
          children: [
            (Assignment
              keyword: Assign_None
              pairs: [
                (assign_pair
                  lhs: (LhsName name:validchars)
                  op: Equal
                  rhs: 
                    {
                      (DQ 
                        (CommandSubPart
                          command_list: 
                            (CommandList
                              children: [
                                (Pipeline
                                  children: [
                                    (C {(echo)} {($ VSub_Number '$1')})
                                    (C {(sed)} {(-e)} {(SQ <'s/[^[:alnum:]]//g'>)})
                                  ]
                                  negated: F
                                )
                              ]
                            )
                          left_token: <Left_CommandSub '$('>
                          spids: [27 41]
                        )
                      )
                    }
                  spids: [25]
                )
              ]
              spids: [25]
            )
            (If
              arms: [
                (if_arm
                  cond: [
                    (Sentence
                      child: 
                        (C {(Lit_Other '[')} {(DQ ($ VSub_Name '$validchars'))} {(Lit_Other '=')} 
                          {(DQ ($ VSub_Number '$1'))} {(Lit_Other ']')}
                        )
                      terminator: <Op_Semi ';'>
                    )
                  ]
                  action: [(ControlFlow token:<ControlFlow_Return return> arg_word:{(0)})]
                  spids: [16777215 64]
                )
              ]
              else_action: [(ControlFlow token:<ControlFlow_Return return> arg_word:{(1)})]
              spids: [72 80]
            )
          ]
          spids: [14]
        )
      spids: [10 13]
    )
  ]
)