(CommandList
  children: [
    (Case
      to_match: {($ VSub_Pound '$#')}
      arms: [
        (case_arm
          pat_list: [{(0)}]
          action: [
            (Sentence
              child: (C {(echo)} {(DQ ('usage: lorder file ...'))})
              terminator: <Op_Semi ';'>
            )
            (ControlFlow token:<ControlFlow_Exit exit>)
          ]
          spids: [110 111 124 16777215]
        )
        (case_arm
          pat_list: [{(1)}]
          action: [
            (Sentence
              child: (C {(echo)} {($ VSub_Number '$1')} {($ VSub_Number '$1')})
              terminator: <Op_Semi ';'>
            )
            (ControlFlow token:<ControlFlow_Exit exit>)
          ]
          spids: [127 128 141 16777215]
        )
      ]
      spids: [103 107 143]
    )
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:R)
          op: Equal
          rhs: 
            {
              (CommandSubPart
                command_list: (CommandList children:[(C {(mktemp)} {(-t)} {(_reference_)})])
                left_token: <Left_CommandSub '$('>
                spids: [150 156]
              )
            }
          spids: [149]
        )
      ]
      spids: [149]
    )
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:S)
          op: Equal
          rhs: 
            {
              (CommandSubPart
                command_list: (CommandList children:[(C {(mktemp)} {(-t)} {(_symbol_)})])
                left_token: <Left_CommandSub '$('>
                spids: [159 165]
              )
            }
          spids: [158]
        )
      ]
      spids: [158]
    )
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:NM)
          op: Equal
          rhs: 
            {
              (BracedVarSub
                token: <VSub_Name NM>
                suffix_op: (StringUnary op_id:VTest_ColonHyphen arg_word:{(nm)})
                spids: [168 172]
              )
            }
          spids: [167]
        )
      ]
      spids: [167]
    )
    (C {(trap)} 
      {
        (DQ ('rm -f ') ($ VSub_Name '$R') (' ') ($ VSub_Name '$S') (' ') ($ VSub_Name '$T') ('; exit 1'))
      } {(1)} {(2)} {(3)} {(13)} {(15)}
    )
    (ForEach
      iter_name: i
      iter_words: [{($ VSub_Star '$*')}]
      do_arg_iter: F
      body: 
        (DoGroup
          children: [(C {(echo)} {($ VSub_Name '$i')} {($ VSub_Name '$i')})]
          spids: [213 222]
        )
      spids: [209 211]
    )
    (Pipeline
      children: [
        (C {(${ VSub_Name NM)} {(${ VSub_Name NMFLAGS)} {(-go)} {($ VSub_Star '$*')})
        (C {(sed)} 
          {
            (DQ ('\n') ('\t/ [TDW] / {\n') ('\t\ts/:.* [TDW] / /\n') ('\t\tw ') ($ VSub_Name '$S') ('\n') 
              ('\t\td\n') ('\t}\n') ('\t/ U / {\n') ('\t\ts/:.* U / /\n') ('\t\tw ') ($ VSub_Name '$R') ('\n') ('\t}\n') ('\td\n')
            )
          }
        )
      ]
      negated: F
    )
    (C {(export)} {(Lit_VarLike 'LC_ALL=') (C)})
    (If
      arms: [
        (if_arm
          cond: [
            (Sentence
              child: 
                (C {(Lit_Other '[')} 
                  {
                    (CommandSubPart
                      command_list: 
                        (CommandList
                          children: [
                            (C {(expr)} {(DQ ($ VSub_Star '$*'))} {(Lit_Other ':')} 
                              {(SQ <'.*\\.a[[:>:]]'>)}
                            )
                          ]
                        )
                      left_token: <Left_CommandSub '$('>
                      spids: [287 299]
                    )
                  } {(-ne)} {(0)} {(Lit_Other ']')}
                )
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (C {(sort)} {(-u)} {(-o)} {($ VSub_Name '$S')} {($ VSub_Name '$S')})
            (C {(sort)} {(-u)} {(-o)} {($ VSub_Name '$R')} {($ VSub_Name '$R')})
            (Assignment
              keyword: Assign_None
              pairs: [
                (assign_pair
                  lhs: (LhsName name:T)
                  op: Equal
                  rhs: 
                    {
                      (CommandSubPart
                        command_list: (CommandList children:[(C {(mktemp)} {(-t)} {(_temp_)})])
                        left_token: <Left_CommandSub '$('>
                        spids: [334 340]
                      )
                    }
                  spids: [333]
                )
              ]
              spids: [333]
            )
            (SimpleCommand
              words: [{(comm)} {(-23)} {($ VSub_Name '$R')} {($ VSub_Name '$S')}]
              redirects: [
                (Redir
                  op_id: Redir_Great
                  fd: 16777215
                  arg_word: {($ VSub_Name '$T')}
                  spids: [351]
                )
              ]
            )
            (C {(mv)} {($ VSub_Name '$T')} {($ VSub_Name '$R')})
          ]
          spids: [16777215 308]
        )
      ]
      spids: [16777215 361]
    )
    (C {(sort)} {(-k)} {(2)} {(-o)} {($ VSub_Name '$R')} {($ VSub_Name '$R')})
    (C {(sort)} {(-k)} {(2)} {(-o)} {($ VSub_Name '$S')} {($ VSub_Name '$S')})
    (C {(join)} {(-j)} {(2)} {(-o)} {(1.1)} {(2.1)} {($ VSub_Name '$R')} {($ VSub_Name '$S')})
    (C {(rm)} {(-f)} {($ VSub_Name '$R')} {($ VSub_Name '$S')})
  ]
)