#include "chdecl.h"
void CH_pshell_parsepipe(current, sched, cop)
#define ARGUMENTS 10
#include "chhead.h"
select: switch (SELECTOR) {
    case 0: goto c0;
    case 1: goto cb2;
    case 2: goto c3;
    case 3: goto c17;
    case 4: goto c18;
    case 5: goto c68;
    case 6: goto c69;
    case 7: goto c72;
    case 8: goto c88;
    case 9: goto c90;
    case 10: goto c93;
    case 11: goto c106;
    case 12: goto c107;
    case 13: goto c110;
    case 14: goto c126;
    case 15: goto c128;
    case 16: goto c134;
    case 17: goto c136;
    case 18: goto c138;
    case 19: goto c152;
    case 20: goto c153;
    case 21: goto c158;  }
c0:
/* block , 0 */
  if((ch_returncode = che_block(QUAL(0),sched)) != Normal)
     goto ch_raise_exception;
/* block , 1 */
  if((ch_returncode = che_block(QUAL(1),sched)) != Normal)
     goto ch_raise_exception;
  current->ip = 1;
cb2:
/* receive 3 0 */
  if ((ch_returncode = che_receive(DEF(3),DEF(0),sched)) != Normal)
     goto ch_raise_exception;
  return;
c3:
/* chs_lit 4 , "stdout" */
  if( !chs_lit(DEF(4),"stdout") ) goto ch_depletion;
/* chs_lit 5 , "stdin" */
  if( !chs_lit(DEF(5),"stdin") ) goto ch_depletion;
/* enum_lit 6 , 0 */
  REF(6).value.enumeration = 0;
  REF(6).tsdr = & dr_enumeration;
/* block , 2 */
  if((ch_returncode = che_block(QUAL(2),sched)) != Normal)
     goto ch_raise_exception;
/* block , 3 */
  if((ch_returncode = che_block(QUAL(3),sched)) != Normal)
     goto ch_raise_exception;
/* privatize 3.0 */
  if (REF(3)DOT(0).value.table->refcount != 1)
    if ((ch_returncode = doCopyOnWrite(DEF(3)DOT(0))) != Normal)
       goto ch_raise_exception;
/* lookup_at 7 3.0 =(0) */
  if ( !((ch_t = REF(3)DOT(0).value.table)->size) ) goto ch_notfound;
  (*(REF(7).tsdr)->finalize)(REF(7).value,F_DISCARD,sched);
  (*(ch_t->tbls[ORDER_TBL].des->lookup_at))
    (ch_t, ORDER_TBL, & REF(7).value,0);
  REF(7).tsdr = qdatarepmap[ch_t->tsdr->number];
/* remove_at 8 3.0 =(0) */
  if ((ch_returncode = remove_at_func(DEF(8),DEF(3)DOT(0),0)) != Normal)
     goto ch_raise_exception;
/* endblock */
  che_endblock(sched);
/* branch , 18 */
   goto c18;
c17:
/* exit , 4 */
  ch_e = handler_type__exit; ch_val = QUAL(4); goto ch_exception;
c18:
/* noop */
  
/* equal . 6 =(5) , 136 */
  if ( REF(6).value.enumeration == 5 ) goto c136;
/* case 9 8 */
  REF(9).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(9).tsdr = & dr_enumeration;
/* notequal . 9 =(1) , 28 */
  if ( REF(9).value.enumeration != 1 ) goto c28;
/* reveal 8 , 1 */
  if (1 != REF(8).value.variant->info.variant_case) goto ch_case_error;
/* copy 10 8.0 */
  REF(10) = REF(8)DOT(0);
/* branch , 31 */
   goto c31;
c28:
/* ordenum_lit 10 , 32 */
  REF(10).value.ord_enum = 32;
  REF(10).tsdr = & dr_ord_enumeration;
c31:
/* noop */
  
/* equal . 6 =(4) , 43 */
  if ( REF(6).value.enumeration == 4 ) goto c43;
/* equal . 6 =(3) , 55 */
  if ( REF(6).value.enumeration == 3 ) goto c55;
/* equal . 6 =(2) , 72 */
  if ( REF(6).value.enumeration == 2 ) goto c72;
/* equal . 6 =(1) , 93 */
  if ( REF(6).value.enumeration == 1 ) goto c93;
/* equal . 6 =(0) , 110 */
  if ( REF(6).value.enumeration == 0 ) goto c110;
/* branch , 134 */
   goto c134;
c43:
/* case 11 8 */
  REF(11).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(11).tsdr = & dr_enumeration;
/* equal 12 11 =(1) */
  REF(12).value.boolean = (REF(11).value.enumeration == 1);
  REF(12).tsdr = & dr_boolean;
/* equal 13 10 =(93) */
  REF(13).value.boolean = (REF(10).value.ord_enum == 93);
  REF(13).tsdr = & dr_boolean;
/* and 14 12 13 */
  REF(14).value.boolean = REF(12).value.boolean&REF(13).value.boolean;
  REF(14).tsdr = & dr_boolean;
/* branch_false 14 , 53 */
  if ( !REF(14).value.boolean ) goto c53;
/* enum_lit 6 , 5 */
  REF(6).value.enumeration = 5;
  REF(6).tsdr = & dr_enumeration;
/* branch , 18 */
   goto c18;
c53:
/* exit , 5 */
  ch_e = handler_type__exit; ch_val = QUAL(5); goto ch_exception;
c55:
/* case 15 8 */
  REF(15).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(15).tsdr = & dr_enumeration;
/* notequal . 15 =(0) , 69 */
  if ( REF(15).value.enumeration != 0 ) goto c69;
/* reveal 8 , 0 */
  if (0 != REF(8).value.variant->info.variant_case) goto ch_case_error;
/* copy 5 8.0 */
  if((ch_returncode = cp_table(& ch_val, REF(8)DOT(0).value)) != Normal)
     goto ch_raise_exception;
  (*(REF(5).tsdr)->finalize)(REF(5).value,F_DISCARD,sched);
  REF(5).value = ch_val;
  REF(5).tsdr = & dr_table;
/* block , 6 */
  if((ch_returncode = che_block(QUAL(6),sched)) != Normal)
     goto ch_raise_exception;
/* privatize 3.0 */
  if (REF(3)DOT(0).value.table->refcount != 1)
    if ((ch_returncode = doCopyOnWrite(DEF(3)DOT(0))) != Normal)
       goto ch_raise_exception;
/* lookup_at 16 3.0 =(0) */
  if ( !((ch_t = REF(3)DOT(0).value.table)->size) ) goto ch_notfound;
  (*(REF(16).tsdr)->finalize)(REF(16).value,F_DISCARD,sched);
  (*(ch_t->tbls[ORDER_TBL].des->lookup_at))
    (ch_t, ORDER_TBL, & REF(16).value,0);
  REF(16).tsdr = qdatarepmap[ch_t->tsdr->number];
/* remove_at 8 3.0 =(0) */
  if ((ch_returncode = remove_at_func(DEF(8),DEF(3)DOT(0),0)) != Normal)
     goto ch_raise_exception;
/* endblock */
  che_endblock(sched);
/* branch , 69 */
   goto c69;
c68:
/* exit , 5 */
  ch_e = handler_type__exit; ch_val = QUAL(5); goto ch_exception;
c69:
/* enum_lit 6 , 4 */
  REF(6).value.enumeration = 4;
  REF(6).tsdr = & dr_enumeration;
/* branch , 18 */
   goto c18;
c72:
/* case 17 8 */
  REF(17).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(17).tsdr = & dr_enumeration;
/* equal 18 17 =(1) */
  REF(18).value.boolean = (REF(17).value.enumeration == 1);
  REF(18).tsdr = & dr_boolean;
/* equal 19 10 =(44) */
  REF(19).value.boolean = (REF(10).value.ord_enum == 44);
  REF(19).tsdr = & dr_boolean;
/* and 20 18 19 */
  REF(20).value.boolean = REF(18).value.boolean&REF(19).value.boolean;
  REF(20).tsdr = & dr_boolean;
/* branch_false 20 , 90 */
  if ( !REF(20).value.boolean ) goto c90;
/* enum_lit 6 , 3 */
  REF(6).value.enumeration = 3;
  REF(6).tsdr = & dr_enumeration;
/* block , 7 */
  if((ch_returncode = che_block(QUAL(7),sched)) != Normal)
     goto ch_raise_exception;
/* privatize 3.0 */
  if (REF(3)DOT(0).value.table->refcount != 1)
    if ((ch_returncode = doCopyOnWrite(DEF(3)DOT(0))) != Normal)
       goto ch_raise_exception;
/* lookup_at 21 3.0 =(0) */
  if ( !((ch_t = REF(3)DOT(0).value.table)->size) ) goto ch_notfound;
  (*(REF(21).tsdr)->finalize)(REF(21).value,F_DISCARD,sched);
  (*(ch_t->tbls[ORDER_TBL].des->lookup_at))
    (ch_t, ORDER_TBL, & REF(21).value,0);
  REF(21).tsdr = qdatarepmap[ch_t->tsdr->number];
/* remove_at 8 3.0 =(0) */
  if ((ch_returncode = remove_at_func(DEF(8),DEF(3)DOT(0),0)) != Normal)
     goto ch_raise_exception;
/* endblock */
  che_endblock(sched);
/* branch , 18 */
   goto c18;
c88:
/* exit , 5 */
  ch_e = handler_type__exit; ch_val = QUAL(5); goto ch_exception;
c90:
/* enum_lit 6 , 4 */
  REF(6).value.enumeration = 4;
  REF(6).tsdr = & dr_enumeration;
/* branch , 18 */
   goto c18;
c93:
/* case 22 8 */
  REF(22).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(22).tsdr = & dr_enumeration;
/* notequal . 22 =(0) , 107 */
  if ( REF(22).value.enumeration != 0 ) goto c107;
/* reveal 8 , 0 */
  if (0 != REF(8).value.variant->info.variant_case) goto ch_case_error;
/* copy 4 8.0 */
  if((ch_returncode = cp_table(& ch_val, REF(8)DOT(0).value)) != Normal)
     goto ch_raise_exception;
  (*(REF(4).tsdr)->finalize)(REF(4).value,F_DISCARD,sched);
  REF(4).value = ch_val;
  REF(4).tsdr = & dr_table;
/* block , 8 */
  if((ch_returncode = che_block(QUAL(8),sched)) != Normal)
     goto ch_raise_exception;
/* privatize 3.0 */
  if (REF(3)DOT(0).value.table->refcount != 1)
    if ((ch_returncode = doCopyOnWrite(DEF(3)DOT(0))) != Normal)
       goto ch_raise_exception;
/* lookup_at 23 3.0 =(0) */
  if ( !((ch_t = REF(3)DOT(0).value.table)->size) ) goto ch_notfound;
  (*(REF(23).tsdr)->finalize)(REF(23).value,F_DISCARD,sched);
  (*(ch_t->tbls[ORDER_TBL].des->lookup_at))
    (ch_t, ORDER_TBL, & REF(23).value,0);
  REF(23).tsdr = qdatarepmap[ch_t->tsdr->number];
/* remove_at 8 3.0 =(0) */
  if ((ch_returncode = remove_at_func(DEF(8),DEF(3)DOT(0),0)) != Normal)
     goto ch_raise_exception;
/* endblock */
  che_endblock(sched);
/* branch , 107 */
   goto c107;
c106:
/* exit , 5 */
  ch_e = handler_type__exit; ch_val = QUAL(5); goto ch_exception;
c107:
/* enum_lit 6 , 2 */
  REF(6).value.enumeration = 2;
  REF(6).tsdr = & dr_enumeration;
/* branch , 18 */
   goto c18;
c110:
/* case 24 8 */
  REF(24).value.enumeration = REF(8).value.variant->info.variant_case;
  REF(24).tsdr = & dr_enumeration;
/* equal 25 24 =(1) */
  REF(25).value.boolean = (REF(24).value.enumeration == 1);
  REF(25).tsdr = & dr_boolean;
/* equal 26 10 =(91) */
  REF(26).value.boolean = (REF(10).value.ord_enum == 91);
  REF(26).tsdr = & dr_boolean;
/* and 27 25 26 */
  REF(27).value.boolean = REF(25).value.boolean&REF(26).value.boolean;
  REF(27).tsdr = & dr_boolean;
/* branch_false 27 , 128 */
  if ( !REF(27).value.boolean ) goto c128;
/* block , 9 */
  if((ch_returncode = che_block(QUAL(9),sched)) != Normal)
     goto ch_raise_exception;
/* privatize 3.0 */
  if (REF(3)DOT(0).value.table->refcount != 1)
    if ((ch_returncode = doCopyOnWrite(DEF(3)DOT(0))) != Normal)
       goto ch_raise_exception;
/* lookup_at 28 3.0 =(0) */
  if ( !((ch_t = REF(3)DOT(0).value.table)->size) ) goto ch_notfound;
  (*(REF(28).tsdr)->finalize)(REF(28).value,F_DISCARD,sched);
  (*(ch_t->tbls[ORDER_TBL].des->lookup_at))
    (ch_t, ORDER_TBL, & REF(28).value,0);
  REF(28).tsdr = qdatarepmap[ch_t->tsdr->number];
/* remove_at 8 3.0 =(0) */
  if ((ch_returncode = remove_at_func(DEF(8),DEF(3)DOT(0),0)) != Normal)
     goto ch_raise_exception;
/* enum_lit 6 , 1 */
  REF(6).value.enumeration = 1;
  REF(6).tsdr = & dr_enumeration;
/* endblock */
  che_endblock(sched);
/* branch , 18 */
   goto c18;
c126:
/* exit , 5 */
  ch_e = handler_type__exit; ch_val = QUAL(5); goto ch_exception;
c128:
/* copy 29 8 */
  if((ch_returncode = cp_variant(& ch_val, REF(8).value)) != Normal)
     goto ch_raise_exception;
  (*(REF(29).tsdr)->finalize)(REF(29).value,F_DISCARD,sched);
  REF(29).value = ch_val;
  REF(29).tsdr = & dr_variant;
/* insert_at 3.0 29 =(0) */
  if ((ch_returncode = insertfunc(DEF(3)DOT(0),DEF(29),TRUE, 0)) != Normal)
     goto ch_raise_exception;
/* enum_lit 6 , 5 */
  REF(6).value.enumeration = 5;
  REF(6).tsdr = & dr_enumeration;
/* branch , 18 */
   goto c18;
c134:
/* exit , 10 */
  ch_e = handler_type__exit; ch_val = QUAL(10); goto ch_exception;
c136:
/* endblock */
  che_endblock(sched);
c138:
/* discard 8 */
  (*(REF(8).tsdr)->finalize)(REF(8).value,F_DISCARD,sched);
  REF(8).tsdr = & dr_bottom;
/* new_record 3.1 , 5 */
  if ((ch_val.record = new_record(5)) == nil) goto ch_depletion;
  (*(REF(3)DOT(1).tsdr)->finalize)(REF(3)DOT(1).value,F_DISCARD,sched);
  REF(3)DOT(1).value = ch_val; REF(3)DOT(1).tsdr = & dr_record;
/* unique 3.1.0 */
  if ((ch_returncode = che_unique(DEF(3)DOT(1)DOT(0),sched)) != Normal)
     goto ch_raise_exception;
/* unique 3.1.1 */
  if ((ch_returncode = che_unique(DEF(3)DOT(1)DOT(1),sched)) != Normal)
     goto ch_raise_exception;
/* move 3.1.2 4 */
  (*(REF(3)DOT(1)DOT(2).tsdr)->finalize)(REF(3)DOT(1)DOT(2).value
    ,F_DISCARD,sched);
  REF(3)DOT(1)DOT(2) = REF(4);
  REF(4).tsdr = & dr_bottom;
/* unique 3.1.3 */
  if ((ch_returncode = che_unique(DEF(3)DOT(1)DOT(3),sched)) != Normal)
     goto ch_raise_exception;
/* move 3.1.4 5 */
  (*(REF(3)DOT(1)DOT(4).tsdr)->finalize)(REF(3)DOT(1)DOT(4).value
    ,F_DISCARD,sched);
  REF(3)DOT(1)DOT(4) = REF(5);
  REF(5).tsdr = & dr_bottom;
/* return 3 */
  if (ch_caller = do_return(REF(3).value)) {
    if (ch_caller->type < CProcess) ch_caller->ip++;
      sched->wakeup_proc(sched, ch_caller);}
  else rem_return(REF(3).value);
  REF(3).tsdr = & dr_bottom;
/* endblock */
  che_endblock(sched);
/* branch , 153 */
   goto c153;
c152:
/* return_exception 3 , 11 */
  if (ch_caller = do_return(REF(3).value)) {
    raise_user(QUAL(11),ch_caller); 
    sched->wakeup_proc(sched,ch_caller);}
  else rem_return_exception(DEF(3),QUAL(11));
  REF(3).tsdr = & dr_bottom;
c153:
/* discard 4 */
  (*(REF(4).tsdr)->finalize)(REF(4).value,F_DISCARD,sched);
  REF(4).tsdr = & dr_bottom;
/* discard 5 */
  (*(REF(5).tsdr)->finalize)(REF(5).value,F_DISCARD,sched);
  REF(5).tsdr = & dr_bottom;
/* discard 8 */
  (*(REF(8).tsdr)->finalize)(REF(8).value,F_DISCARD,sched);
  REF(8).tsdr = & dr_bottom;
/* endblock */
  che_endblock(sched);
c158:
/* endprocess */
  che_endprocess(sched); return;
#include "chtail.h"
