

#include "BUILTIN.h"
extern OBJ _ASeqMap_3(OBJ,OBJ);extern OBJ __ASeqMap_3;

#include "Array.h"
extern OBJ _AMap_10(OBJ,OBJ,OBJ,OBJ);extern OBJ __AMap_10;
extern OBJ _AMap_16(OBJ,OBJ,OBJ);extern OBJ __AMap_16;
extern OBJ _AMap_20(OBJ,OBJ,OBJ);extern OBJ __AMap_20;

#include "Nat.h"
extern OBJ __ASeq_6;
extern OBJ _ASeq_14(OBJ,OBJ);extern OBJ __ASeq_14;
extern OBJ _ASeq_15(OBJ,OBJ,OBJ);extern OBJ __ASeq_15;
extern OBJ _ASeq_16(OBJ,OBJ,OBJ,OBJ);extern OBJ __ASeq_16;
extern OBJ _ASeq_31(OBJ,OBJ);extern OBJ __ASeq_31;
extern OBJ _ASeq_32(OBJ,OBJ);extern OBJ __ASeq_32;
extern OBJ _ASeq_52(OBJ,OBJ);extern OBJ __ASeq_52;
extern OBJ _AFormat_5(OBJ,OBJ);extern OBJ __AFormat_5;
extern OBJ __AFormat_9;
extern OBJ _AIde_13(OBJ,OBJ);extern OBJ __AIde_13;
extern OBJ _AIde_14(OBJ,OBJ);extern OBJ __AIde_14;
extern OBJ __AIde_17;
extern OBJ _AIde_18(OBJ);extern OBJ __AIde_18;
extern OBJ _ATypeAn_6(OBJ);extern OBJ __ATypeAn_6;
extern OBJ __ATypeAn_40;
extern OBJ __ATypeAn_52;
extern OBJ __AIdeMap_3;
extern OBJ _AIdeMap_6(OBJ,OBJ);extern OBJ __AIdeMap_6;
extern OBJ _AAc_21(OBJ);extern OBJ __AAc_21;
extern OBJ _AAc_22(OBJ);extern OBJ __AAc_22;
extern OBJ _AAc_50(OBJ);extern OBJ __AAc_50;
extern OBJ _ANatMap_14(OBJ,OBJ);extern OBJ __ANatMap_14;
extern OBJ _ANatMap_19(OBJ);extern OBJ __ANatMap_19;
extern OBJ _AFmt_28(OBJ);extern OBJ __AFmt_28;

#include "Char.h"

#include "Int.h"
extern OBJ __ABuiltin_12;
extern OBJ _ANatMapReduce_3(OBJ,OBJ,OBJ);extern OBJ __ANatMapReduce_3;
extern OBJ _AFormatFun1_2(OBJ,OBJ,OBJ,OBJ,OBJ);extern OBJ __AFormatFun1_2;
extern OBJ _ASeqReduce_3(OBJ,OBJ,OBJ);extern OBJ __ASeqReduce_3;
extern OBJ _ATypeAnFun_1(OBJ,OBJ);OBJ __ATypeAnFun_1; /* typeDec */
extern OBJ _ATypeAnFun_2(OBJ,OBJ);OBJ __ATypeAnFun_2; /* typeDecs */
extern OBJ _ATypeAnFun_3(OBJ,OBJ);OBJ __ATypeAnFun_3; /* importedTypeDecs */
extern OBJ _ATypeAnFun_4(OBJ);OBJ __ATypeAnFun_4; /* typeOfDec */
extern OBJ _ATypeAnFun_5(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_5; /* typeOfExp */
extern OBJ _ATypeAnFun_6(OBJ,OBJ);OBJ __ATypeAnFun_6; /* reduce */
extern OBJ _ATypeAnFun_7(OBJ,OBJ);OBJ __ATypeAnFun_7; /* unfold */
extern OBJ _ATypeAnFun_8(OBJ,OBJ);OBJ __ATypeAnFun_8; /* structure */
extern OBJ _ATypeAnFun_9(OBJ,OBJ);OBJ __ATypeAnFun_9; /* typeDecAss */
extern OBJ _ATypeAnFun_10(OBJ,OBJ);OBJ __ATypeAnFun_10; /* subs */
extern OBJ _ATypeAnFun_11(OBJ);OBJ __ATypeAnFun_11; /* order */
extern OBJ _ATypeAnFun_12(OBJ);OBJ __ATypeAnFun_12; /* format */
extern OBJ _ATypeAnFun_13(OBJ);OBJ __ATypeAnFun_13; /* format,1 */
extern OBJ _ATypeAnFun_14(OBJ);OBJ __ATypeAnFun_14; /* format,2 */
extern OBJ _ATypeAnFun_15(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_15; /* getImportedWhen */
extern OBJ _ATypeAnFun_16(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_16; /* getWhen */
extern OBJ _ATypeAnFun_17(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_17; /* typeOfApply */
extern OBJ _ATypeAnFun_18(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_18; /* typeOfCase */
extern OBJ _ATypeAnFun_19(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_19; /* typeOfBlock */
extern OBJ _ATypeAnFun_20(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_20; /* typeOfLambda */
extern OBJ _ATypeAnFun_21(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_21; /* typeOfIde */
extern OBJ _ATypeAnFun_22(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_22; /* typeOfDeno */
extern OBJ _ATypeAnFun_23(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_23; /* typeOfError */
extern OBJ _ATypeAnFun_24(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_24; /* typeOfRes */
extern OBJ _ATypeAnFun_25(OBJ,OBJ,OBJ);OBJ __ATypeAnFun_25; /* refine */
extern OBJ _ATypeAnFun_26(OBJ,OBJ,OBJ,OBJ);OBJ __ATypeAnFun_26; /* substitute */
OBJ __ATypeAnFun_27; /* typeOfDeno'27 */
extern OBJ _ATypeAnFun_28(OBJ,OBJ);OBJ __ATypeAnFun_28; /* typeOfLambda'28 */
OBJ __ATypeAnFun_29; /* format,1'29 */
extern OBJ _ATypeAnFun_30(OBJ);OBJ __ATypeAnFun_30; /* format,1'30 */
OBJ __ATypeAnFun_31; /* format,1'31 */
extern OBJ _ATypeAnFun_32(OBJ);OBJ __ATypeAnFun_32; /* format,1'32 */
OBJ __ATypeAnFun_33; /* format,1'33 */
extern OBJ _ATypeAnFun_34(OBJ);OBJ __ATypeAnFun_34; /* format,1'34 */
OBJ __ATypeAnFun_35; /* format,1'35 */
extern OBJ _ATypeAnFun_36(OBJ);OBJ __ATypeAnFun_36; /* format,1'36 */
OBJ __ATypeAnFun_37; /* format,1'37 */
OBJ __ATypeAnFun_38; /* format,1'38 */
extern OBJ _ATypeAnFun_39(OBJ);OBJ __ATypeAnFun_39; /* format,1'39 */
OBJ __ATypeAnFun_40; /* format,1'40 */
extern OBJ _ATypeAnFun_41(OBJ);OBJ __ATypeAnFun_41; /* format,1'41 */
OBJ __ATypeAnFun_42; /* format,1'42 */
extern OBJ _ATypeAnFun_43(OBJ);OBJ __ATypeAnFun_43; /* format,1'43 */
OBJ __ATypeAnFun_44; /* format,1'44 */
extern OBJ _ATypeAnFun_45(OBJ);OBJ __ATypeAnFun_45; /* format,1'45 */
OBJ __ATypeAnFun_46; /* format,1'46 */
extern OBJ _ATypeAnFun_47(OBJ);OBJ __ATypeAnFun_47; /* format,1'47 */
OBJ __ATypeAnFun_48; /* format,1'48 */
extern OBJ _ATypeAnFun_49(OBJ);OBJ __ATypeAnFun_49; /* format,1'49 */
OBJ __ATypeAnFun_50; /* format,1'50 */
extern OBJ _ATypeAnFun_51(OBJ);OBJ __ATypeAnFun_51; /* format,1'51 */
OBJ __ATypeAnFun_52; /* format,1'52 */
extern OBJ _ATypeAnFun_53(OBJ);OBJ __ATypeAnFun_53; /* format,1'53 */
OBJ __ATypeAnFun_54; /* format,2'54 */
extern OBJ _ATypeAnFun_55(OBJ);OBJ __ATypeAnFun_55; /* format,2'55 */
OBJ __ATypeAnFun_56; /* format,2'56 */
extern OBJ _ATypeAnFun_57(OBJ);OBJ __ATypeAnFun_57; /* format,2'57 */
OBJ __ATypeAnFun_58; /* format,2'58 */
OBJ __ATypeAnFun_59; /* format,2'59 */
extern OBJ _ATypeAnFun_60(OBJ);OBJ __ATypeAnFun_60; /* format,2'60 */
OBJ __ATypeAnFun_61; /* format'61 */
extern OBJ _ATypeAnFun_62(OBJ);OBJ __ATypeAnFun_62; /* format'62 */
extern OBJ _ATypeAnFun_63(OBJ);OBJ __ATypeAnFun_63; /* format'63 */
extern OBJ _ATypeAnFun_64(OBJ);OBJ __ATypeAnFun_64; /* format'64 */
OBJ __ATypeAnFun_65; /* format'65 */
extern OBJ _ATypeAnFun_66(OBJ);OBJ __ATypeAnFun_66; /* format'66 */

extern OBJ _ATypeAnFun_1(OBJ x1,OBJ x2) /* typeDec */
{OBJ r;
 {OBJ x11;OBJ x7;OBJ x12;OBJ x90;
  if(ISTGPRD(x2,0)){
   {OBJ x99=FLD(x2,1);OBJ x100=FLD(x2,2);
    x11=x99;x7=x100;}
  }else{
   HLT("Ide at <unknown> : undefined selection origin\'Ide:ide->origin");}
  ANat_76(x7,__AIde_17,x12);
  if(ISTGPRM(x12,1)){
   {OBJ x30=FLD1(x1,1);
    if(EXPRD(x1,1)){
     FLD1(x1,1)=NIL;DSPRD(x1);
    }else{
     COPY(x30,1);
     FRPRD(x1,1);}
    if(ISPRM(x30)){
     x90=__ATypeAn_52;
    }else{
     {OBJ x35=FLD1(x30,1);
      if(EXPRD(x30,1)){
       x90=x35;
       FLD1(x30,1)=NIL;DSPRD(x30);
      }else{
       COPY(x35,1);
       x90=x35;
       FRPRD(x30,1);}}}}
  }else{
   {OBJ x77=FLD1(x1,4);
    if(EXPRD(x1,1)){
     FLD1(x1,4)=NIL;DSPRD(x1);
    }else{
     CPPRD(x77,1);
     FRPRD(x1,1);}
    {OBJ x79;
     x79=_ANatMap_14(x77,x7);
     {OBJ x80=FLD1(x79,1);
      if(EXPRD(x79,1)){
       FLD1(x79,1)=NIL;DSPRD(x79);
      }else{
       COPY(x80,1);
       FRPRD(x79,1);}
      if(ISPRM(x80)){
       x90=__ATypeAn_52;
      }else{
       {OBJ x85=FLD1(x80,1);
	if(EXPRD(x80,1)){
	 x90=x85;
	 FLD1(x80,1)=NIL;DSPRD(x80);
	}else{
	 COPY(x85,1);
	 x90=x85;
	 FRPRD(x80,1);}}}}}}}
  if(ISPRD(x90)&&(ISTGPRD(x90,3))){
   {OBJ x95=FLD(x90,1);
    if(EXPRD(x90,1)){
     DSPRDF(x90);
    }else{
     CPPRD(x95,1);
     FRPRD(x90,1);}
    FRPRD(x2,1);
    r=_ANatMap_14(x95,x11);}
  }else{
   FREE(x90,1);
   PRD(1,0,r);FLD(r,1)=x2;}}
 return r;}

extern OBJ _ATypeAnFun_2(OBJ x1,OBJ x2) /* typeDecs */
{OBJ r;
 {OBJ x22=FLD1(x2,1);
  if(EXPRD(x2,1)){
   FLD1(x2,1)=NIL;DSPRD(x2);
  }else{
   COPY(x22,1);
   FRPRD(x2,1);}
  {OBJ x32;
   if(ISPRM(x22)){
    x32=__ATypeAn_52;
   }else{
    {OBJ x27=FLD1(x22,1);
     if(EXPRD(x22,1)){
      x32=x27;
      FLD1(x22,1)=NIL;DSPRD(x22);
     }else{
      COPY(x27,1);
      x32=x27;
      FRPRD(x22,1);}}}
   if(ISPRD(x32)&&(ISTGPRD(x32,3))){
    {OBJ x33=FLD(x32,1);
     if(EXPRD(x32,1)){
      DSPRDF(x32);
     }else{
      CPPRD(x33,1);
      FRPRD(x32,1);}
     CPCLS(__ATypeAnFun_16,1);
     {OBJ x34;
      x34=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_16,1))(__ATypeAnFun_16,x1);
      r=_ANatMapReduce_3(x34,__ASeq_6,x33);}}
   }else{
    FRCLS(x1,1);
    FREE(x32,1);
    r=__ASeq_6;}}}
 return r;}

extern OBJ _ATypeAnFun_3(OBJ x1,OBJ x2) /* importedTypeDecs */
{OBJ r;
 CPCLS(__ATypeAnFun_15,1);
 {OBJ x3;
  x3=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_15,1))(__ATypeAnFun_15,x1);
  {OBJ x7=FLD1(x2,4);
   if(EXPRD(x2,1)){
    FLD1(x2,4)=NIL;DSPRD(x2);
   }else{
    CPPRD(x7,1);
    FRPRD(x2,1);}
   {OBJ x9;
    x9=x7;
    r=_ANatMapReduce_3(x3,__ASeq_6,x9);}}}
 return r;}

extern OBJ _ATypeAnFun_4(OBJ x1) /* typeOfDec */
{OBJ r;
 {OBJ x2;OBJ x8;
  x2=_AAc_22(x1);
  if(ISPRM(x2)){
   x8=__ATypeAn_52;
  }else{
   {OBJ x3=FLD1(x2,1);
    if(EXPRD(x2,1)){
     x8=x3;
     FLD1(x2,1)=NIL;DSPRD(x2);
    }else{
     COPY(x3,1);
     x8=x3;
     FRPRD(x2,1);}}}
  if(ISPRD(x8)&&(ISTGPRD(x8,1))){
   {OBJ x12=FLD(x8,1);
    if(EXPRD(x8,1)){
     r=x12;
     DSPRDF(x8);
    }else{
     COPY(x12,1);
     r=x12;
     FRPRD(x8,1);}}
  }else{
   FREE(x8,1);
   r=__ATypeAn_40;}}
 return r;}

extern OBJ _ATypeAnFun_5(OBJ x1,OBJ x2,OBJ x3) /* typeOfExp */
{OBJ r;
 CPPRD(x3,1);
 {OBJ x4;OBJ x10;
  x4=_AAc_50(x3);
  if(ISPRM(x4)){
   x10=__ATypeAn_52;
  }else{
   {OBJ x5=FLD1(x4,1);
    if(EXPRD(x4,1)){
     x10=x5;
     FLD1(x4,1)=NIL;DSPRD(x4);
    }else{
     COPY(x5,1);
     x10=x5;
     FRPRD(x4,1);}}}
  if(ISPRD(x10)&&(ISTGPRD(x10,1))){
   {OBJ x95=FLD(x10,1);
    if(EXPRD(x10,1)){
     r=x95;
     DSPRDF(x10);
    }else{
     COPY(x95,1);
     r=x95;
     FRPRD(x10,1);}
    FRCLS(x1,1);
    FRCLS(x2,1);
    FRPRD(x3,1);}
  }else{
   {OBJ x99;OBJ x101;OBJ x123;
    if(ISTGPRD(x3,3)){
     x99=__ABUILTIN_5;
    }else{
     x99=__ABUILTIN_3;}
    if(ISPRD(x10)&&(ISTGPRD(x10,2))){
     x101=__ABUILTIN_5;
    }else{
     x101=__ABUILTIN_3;}
    if(ISTGPRM(x99,1)){
     x123=_ATypeAnFun_17(x1,x2,x3);
    }else{
     switch(TGPRD(x3)){
      case 5:
       x123=_ATypeAnFun_19(x1,x2,x3);break;
      case 4:
       x123=_ATypeAnFun_20(x1,x2,x3);break;
      case 2:
       {OBJ x113=FLD(x3,2);
	if(EXPRD(x3,1)){
	 FREE(FLD(x3,1),1);DSPRDF(x3);
	}else{
	 CPPRD(x113,1);
	 FRPRD(x3,1);}
	FRCLS(x2,1);
	x123=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x113);}break;
      case 1:
       if(EXPRD(x3,1)){
	DSPRD(x3);
       }else{
	DCPRD(x3,1);}
       FRCLS(x1,1);
       FRCLS(x2,1);
       COPY(__ATypeAnFun_27,1);
       x123=__ATypeAnFun_27;break;
      case 0:
       if(EXPRD(x3,1)){
	FREE(FLD(x3,1),1);DSPRDF(x3);
       }else{
	DCPRD(x3,1);}
       FRCLS(x1,1);
       FRCLS(x2,1);
       x123=__ATypeAn_40;break;
      case 3:
       HLT("TypeAnFun at <151,20-157,53> : missing else in typeOfExp\'TypeAnFun:(ide->type)**(ide->typeDec)->exp->type");break;
      default: 
       x123=_ATypeAnFun_18(x1,x2,x3);}}
    if(ISTGPRM(x101,1)){
     if(ISPRD(x10)&&(ISTGPRD(x10,2))){
      {OBJ x124=FLD(x10,1);
       if(EXPRD(x10,1)){
	DSPRDF(x10);
       }else{
	COPY(x124,1);
	FRPRD(x10,1);}
       PRD(2,6,r);FLD(r,1)=x123;FLD(r,2)=x124;}
     }else{
      HLT("TypeAn at <unknown> : undefined selection subs\'TypeAn:typeAn->seq");}
    }else{
     r=x123;
     FREE(x10,1);}}}}
 return r;}

extern OBJ _ATypeAnFun_6(register OBJ x1,register OBJ x2) /* reduce */
{OBJ r;
 for(;;){
  if(ISPRD(x2)&&(ISTGPRD(x2,6))){
   {OBJ x35=FLD(x2,1);OBJ x36=FLD(x2,2);
    if(EXPRD(x2,1)){
     DSPRDF(x2);
    }else{
     COPY(x35,1);COPY(x36,1);
     FRPRD(x2,1);}
    CPCLS(x1,1);
    {OBJ x37;
     x37=_ATypeAnFun_7(x1,x35);
     if(ISPRD(x37)&&(ISTGPRD(x37,7))){
      {OBJ x38=FLD(x37,1);OBJ x39=FLD(x37,2);
       if(EXPRD(x37,1)){
	DSPRDF(x37);
       }else{
	COPY(x38,1);COPY(x39,1);
	FRPRD(x37,1);}
       COPY(__AIdeMap_3,1);
       {OBJ x40;
	x40=_ATypeAnFun_26(__AIdeMap_3,x38,x36,x39);
	x2=x40;continue;}}
     }else{
      FRCLS(x1,1);
      FREE(x36,1);
      FREE(x37,1);
      r=__ATypeAn_40;}}}
  }else{
   FRCLS(x1,1);
   r=x2;}
  break;}
 return r;}

extern OBJ _ATypeAnFun_7(register OBJ x1,register OBJ x2) /* unfold */
{OBJ r;
 for(;;){
  if(ISPRD(x2)&&(ISTGPRD(x2,1))){
   {OBJ x33=FLD(x2,1);
    CPPRD(x33,1);
    if(ISTGPRD(x33,0)){
     CPCLS(x1,1);
     {OBJ x36;
      x36=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x33);
      if(ISTGPRD(x36,1)){
       {OBJ x38=FLD(x36,2);
	if(EXPRD(x36,1)){
	 FRPRD(FLD(x36,1),1);DSPRDF(x36);
	}else{
	 COPY(x38,1);
	 FRPRD(x36,1);}
	if(EXPRD(x2,1)){
	 FRPRD(FLD(x2,1),1);DSPRDF(x2);
	}else{
	 DCPRD(x2,1);}
	x2=x38;continue;}
      }else{
       FRCLS(x1,1);
       FRPRD(x36,1);
       r=x2;}}
    }else{
     if(EXPRD(x33,1)){
      DSPRDF(x33);
     }else{
      DCPRD(x33,1);}
     FRCLS(x1,1);
     r=x2;}}
  }else{
   FRCLS(x1,1);
   r=x2;}
  break;}
 return r;}

extern OBJ _ATypeAnFun_8(register OBJ x1,register OBJ x2) /* structure */
{OBJ r;
 for(;;){
  if(ISPRD(x2)&&(ISTGPRD(x2,6))){
   CPCLS(x1,1);
   {OBJ x86;
    x86=_ATypeAnFun_6(x1,x2);
    x2=x86;continue;}
  }else{
   if(ISPRD(x2)&&(ISTGPRD(x2,7))){
    {OBJ x88=FLD(x2,2);
     if(EXPRD(x2,1)){
      FREE(FLD(x2,1),1);DSPRDF(x2);
     }else{
      COPY(x88,1);
      FRPRD(x2,1);}
     x2=x88;continue;}
   }else{
    if(ISPRD(x2)&&(ISTGPRD(x2,1))){
     {OBJ x89=FLD(x2,1);
      CPPRD(x89,1);
      if(ISTGPRD(x89,0)){
       CPCLS(x1,1);
       {OBJ x92;
	x92=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x89);
	if(ISTGPRD(x92,1)){
	 {OBJ x94=FLD(x92,2);
	  if(EXPRD(x92,1)){
	   FRPRD(FLD(x92,1),1);DSPRDF(x92);
	  }else{
	   COPY(x94,1);
	   FRPRD(x92,1);}
	  if(EXPRD(x2,1)){
	   FRPRD(FLD(x2,1),1);DSPRDF(x2);
	  }else{
	   DCPRD(x2,1);}
	  x2=x94;continue;}
	}else{
	 FRCLS(x1,1);
	 FRPRD(x92,1);
	 r=x2;}}
      }else{
       if(EXPRD(x89,1)){
	DSPRDF(x89);
       }else{
	DCPRD(x89,1);}
       FRCLS(x1,1);
       r=x2;}}
    }else{
     if(ISPRD(x2)&&(ISTGPRD(x2,2))){
      {OBJ x96=FLD(x2,1);
       COPY(x96,2);
       FRCLS(x1,1);
       {OBJ x97;OBJ x98;
	x97=_ASeq_52(x96,__ANat_5);
	ANat_76(x97,__ANat_8,x98);
	if(ISTGPRM(x98,1)){
	 if(EXPRD(x2,1)){
	  FREE(FLD(x2,1),1);DSPRDF(x2);
	 }else{
	  DCPRD(x2,1);}
	 if(ISPRM(x96)){
	  HLT("Seq at <unknown> : undefined selection ft\'Seq:seq->data");
	 }else{
	  {OBJ x99=FLD1(x96,1);
	   if(EXPRD(x96,1)){
	    r=x99;
	    FREE(FLD1(x96,2),1);DSPRDF(x96);
	   }else{
	    COPY(x99,1);
	    r=x99;
	    FRPRD(x96,1);}}}
	}else{
	 FREE(x96,1);
	 r=x2;}}}
     }else{
      FRCLS(x1,1);
      r=x2;}}}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_9(OBJ x1,OBJ x2) /* typeDecAss */
{OBJ r;
 r=_ATypeAnFun_1(x1,x2);
 return r;}

extern OBJ _ATypeAnFun_10(register OBJ x1,register OBJ x2) /* subs */
{OBJ r;OBJ* p1=&r;
 for(;;){
  if(ISPRM(x2)){
   FREE(x1,1);
   *p1=x2;
  }else{
   switch(TGPRD(x2)){
    case 6:
     {OBJ x153=FLD(x2,1);OBJ x154=FLD(x2,2);
      if(EXPRD(x2,1)){
       COPY(x1,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x155;OBJ x156;
	x155=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	x156=_ASeqMap_3(x155,x154);
	RPRD(x2,*p1);FLD(*p1,2)=x156;
	x2=x153;p1=&FLD(*p1,1);continue;}
      }else{
       COPY(x153,1);COPY(x154,1);
       COPY(x1,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x155;OBJ x156;
	x155=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	x156=_ASeqMap_3(x155,x154);
	FRPRD(x2,1);PRD(2,6,*p1);FLD(*p1,2)=x156;
	x2=x153;p1=&FLD(*p1,1);continue;}}}break;
    case 3:
     {OBJ x158=FLD(x2,1);OBJ x159=FLD(x2,2);
      if(EXPRD(x2,1)){
       COPY(x1,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x160;OBJ x161;
	x160=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	x161=_ASeqMap_3(x160,x158);
	RPRD(x2,*p1);FLD(*p1,1)=x161;
	x2=x159;p1=&FLD(*p1,2);continue;}
      }else{
       COPY(x158,1);COPY(x159,1);
       COPY(x1,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x160;OBJ x161;
	x160=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	x161=_ASeqMap_3(x160,x158);
	FRPRD(x2,1);PRD(2,3,*p1);FLD(*p1,1)=x161;
	x2=x159;p1=&FLD(*p1,2);continue;}}}break;
    case 5:
     {OBJ x163=FLD(x2,1);
      if(EXPRD(x2,1)){
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x164;
	x164=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	RPRD(x2,*p1);
	FLD(*p1,1)=_ASeqMap_3(x164,x163);}
      }else{
       COPY(x163,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x164;
	x164=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	FRPRD(x2,1);PRD(1,5,*p1);
	FLD(*p1,1)=_ASeqMap_3(x164,x163);}}}break;
    case 2:
     {OBJ x166=FLD(x2,1);
      if(EXPRD(x2,1)){
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x167;
	x167=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	RPRD(x2,*p1);
	FLD(*p1,1)=_ASeqMap_3(x167,x166);}
      }else{
       COPY(x166,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x167;
	x167=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	FRPRD(x2,1);PRD(1,2,*p1);
	FLD(*p1,1)=_ASeqMap_3(x167,x166);}}}break;
    case 4:
     {OBJ x169;OBJ x170=FLD(x2,2);
      if(EXPRD(x2,1)){
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x171;
	x171=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	RPRD(x2,*p1);
	FLD(*p1,2)=_ASeqMap_3(x171,x170);}
      }else{
       x169=FLD(x2,1);CPPRD(x169,1);COPY(x170,1);
       CPCLS(__ATypeAnFun_10,1);
       {OBJ x171;
	x171=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_10,1))(__ATypeAnFun_10,x1);
	FRPRD(x2,1);PRD(2,4,*p1);FLD(*p1,1)=x169;
	FLD(*p1,2)=_ASeqMap_3(x171,x170);}}}break;
    case 1:
     {OBJ x173=FLD(x2,1);
      CPPRD(x173,2);
      COPY(x1,1);
      CPCLS(__AIde_14,1);
      {OBJ x174;
       x174=_AMap_20(__AIde_14,x173,x1);
       if(ISTGPRM(x174,1)){
	if(EXPRD(x2,1)){
	 FRPRD(FLD(x2,1),1);DSPRDF(x2);
	}else{
	 DCPRD(x2,1);}
	CPCLS(__AIde_14,1);
	*p1=_AMap_16(__AIde_14,x1,x173);
       }else{
	FREE(x1,1);
	FRPRD(x173,1);
	*p1=x2;}}}break;
    default: 
     {OBJ x150=FLD(x2,1);OBJ x151=FLD(x2,2);
      if(EXPRD(x2,1)){
       DSPRDF(x2);
      }else{
       COPY(x150,1);COPY(x151,1);
       FRPRD(x2,1);}
      CPCLS(__AIdeMap_6,1);
      {OBJ x152;
       x152=_ASeqReduce_3(__AIdeMap_6,x1,x150);
       x1=x152;x2=x151;continue;}}}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_11(register OBJ x1) /* order */
{OBJ r;
 for(;;){
  if(ISPRD(x1)&&(ISTGPRD(x1,3))){
   {OBJ x25=FLD(x1,1);OBJ x26=FLD(x1,2);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     COPY(x25,1);COPY(x26,1);
     FRPRD(x1,1);}
    {OBJ x27;OBJ x28;
     x27=_ASeq_52(x25,__ANat_5);
     x28=_ATypeAnFun_11(x26);
     ANat_61(x27,x28,r);}}
  }else{
   if(ISPRD(x1)&&(ISTGPRD(x1,7))){
    {OBJ x30=FLD(x1,2);
     if(EXPRD(x1,1)){
      FREE(FLD(x1,1),1);DSPRDF(x1);
     }else{
      COPY(x30,1);
      FRPRD(x1,1);}
     x1=x30;continue;}
   }else{
    FREE(x1,1);
    r=__ANat_5;}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_12(OBJ x1) /* format */
{OBJ r;
 if(ISPRD(x1)&&(ISTGPRD(x1,1))){
  {OBJ x40=FLD(x1,1);
   if(EXPRD(x1,1)){
    DSPRDF(x1);
   }else{
    COPY(x40,1);
    FRPRD(x1,1);}
   COPY(__ATypeAnFun_61,1);
   {OBJ x41;OBJ x42;
    x41=_ATypeAnFun_13(x40);
    x42=_ASeq_14(__ATypeAnFun_61,x41);
    r=_AFormat_5(__ANat_9,x42);}}
 }else{
  if(ISPRD(x1)&&(ISTGPRD(x1,2))){
   {OBJ x43=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     COPY(x43,1);
     FRPRD(x1,1);}
    CPCLS(__ATypeAnFun_13,1);
    COPY(__ATypeAnFun_61,1);
    CPCLS(__ATypeAnFun_62,1);
    CPCLS(__ATypeAnFun_63,1);
    CPCLS(__ATypeAnFun_64,1);
    {OBJ x44;OBJ x45;OBJ x46;OBJ x47;OBJ x48;
     x44=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_62,1))(__ATypeAnFun_62,__ABUILTIN_20);
     x45=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_63,1))(__ATypeAnFun_63,__ABUILTIN_20);
     x46=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_64,1))(__ATypeAnFun_64,__ABUILTIN_20);
     x47=_AFormatFun1_2(x44,x45,x46,__ATypeAnFun_13,x43);
     x48=_ASeq_14(__ATypeAnFun_61,x47);
     r=_AFormat_5(__ANat_9,x48);}}
  }else{
   CPCLS(__ATypeAnFun_66,1);
   {OBJ x49;
    x49=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_66,1))(__ATypeAnFun_66,__ABUILTIN_20);
    if(ISPRM(x1)){
     r=x49;
    }else{
     {OBJ x50=FLD(x1,1);
      if(EXPRD(x1,1)){
       DSPRDF(x1);
      }else{
       CPPRD(x50,1);
       FRPRD(x1,1);}
      COPY(x49,1);
      CPCLS(__ATypeAnFun_14,1);
      COPY(__ATypeAnFun_61,1);
      COPY(__AFormat_9,1);
      {OBJ x51;OBJ x52;OBJ x53;
       x51=_ANatMap_19(x50);
       x52=_AFormatFun1_2(x49,__AFormat_9,x49,__ATypeAnFun_14,x51);
       x53=_ASeq_14(__ATypeAnFun_61,x52);
       r=_AFormat_5(__ANat_9,x53);}}}}}}
 return r;}

extern OBJ _ATypeAnFun_13(OBJ x1) /* format,1 */
{OBJ r;
 if(ISPRM(x1)){
  CPCLS(__ATypeAnFun_30,1);
  r=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_30,1))(__ATypeAnFun_30,__ABUILTIN_20);
 }else{
  switch(TGPRD(x1)){
   case 3:
    {OBJ x318=FLD(x1,1);OBJ x319=FLD(x1,2);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      COPY(x318,1);COPY(x319,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_13,1);
     CPCLS(__ATypeAnFun_32,1);
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_36,1);
     COPY(__ATypeAnFun_37,1);
     CPCLS(__ATypeAnFun_39,1);
     {OBJ x320;OBJ x321;OBJ x322;OBJ x323;OBJ x324;OBJ x325;OBJ x326;
      x320=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_39,1))(__ATypeAnFun_39,__ABUILTIN_20);
      x321=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_36,1))(__ATypeAnFun_36,__ABUILTIN_20);
      x322=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x323=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_32,1))(__ATypeAnFun_32,__ABUILTIN_20);
      x324=_AFormatFun1_2(x323,x322,x321,__ATypeAnFun_13,x318);
      x325=_ATypeAnFun_13(x319);
      x326=_ASeq_16(x324,__ATypeAnFun_37,x320,x325);
      r=_AFormat_5(__ANat_9,x326);}}break;
   case 2:
    {OBJ x327=FLD(x1,1);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      COPY(x327,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_13,1);
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_41,1);
     CPCLS(__ATypeAnFun_43,1);
     {OBJ x328;OBJ x329;OBJ x330;OBJ x331;OBJ x332;
      x328=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x329=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_41,1))(__ATypeAnFun_41,__ABUILTIN_20);
      x330=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_43,1))(__ATypeAnFun_43,__ABUILTIN_20);
      x331=_AFormatFun1_2(x329,x328,x330,__ATypeAnFun_13,x327);
      PRD1(2,x332);FLD1(x332,1)=x331;FLD1(x332,2)=__ASeq_6;
      r=_AFormat_5(__ANat_9,x332);}}break;
   case 4:
    {OBJ x333=FLD(x1,1);OBJ x334=FLD(x1,2);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      CPPRD(x333,1);COPY(x334,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_13,1);
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_41,1);
     CPCLS(__ATypeAnFun_43,1);
     CPCLS(__ATypeAnFun_45,1);
     {OBJ x335;OBJ x336;OBJ x337;OBJ x338;OBJ x339;OBJ x340;OBJ x341;
      x335=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_45,1))(__ATypeAnFun_45,__ABUILTIN_20);
      x336=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_43,1))(__ATypeAnFun_43,__ABUILTIN_20);
      x337=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_41,1))(__ATypeAnFun_41,__ABUILTIN_20);
      x338=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x339=_AIde_18(x333);
      x340=_AFormatFun1_2(x335,x338,x336,__ATypeAnFun_13,x334);
      x341=_ASeq_15(x337,x339,x340);
      r=_AFormat_5(__ANat_9,x341);}}break;
   case 5:
    {OBJ x342=FLD(x1,1);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      COPY(x342,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_13,1);
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_47,1);
     CPCLS(__ATypeAnFun_49,1);
     {OBJ x343;OBJ x344;OBJ x345;OBJ x346;OBJ x347;
      x343=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x344=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_47,1))(__ATypeAnFun_47,__ABUILTIN_20);
      x345=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_49,1))(__ATypeAnFun_49,__ABUILTIN_20);
      x346=_AFormatFun1_2(x344,x343,x345,__ATypeAnFun_13,x342);
      PRD1(2,x347);FLD1(x347,1)=x346;FLD1(x347,2)=__ASeq_6;
      r=_AFormat_5(__ANat_9,x347);}}break;
   case 6:
    {OBJ x348=FLD(x1,1);OBJ x349=FLD(x1,2);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      COPY(x348,1);COPY(x349,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_13,1);
     CPCLS(__ATypeAnFun_32,1);
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_36,1);
     {OBJ x350;OBJ x351;OBJ x352;OBJ x354;OBJ x353;OBJ x355;
      x350=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_36,1))(__ATypeAnFun_36,__ABUILTIN_20);
      x351=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x352=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_32,1))(__ATypeAnFun_32,__ABUILTIN_20);
      x354=_AFormatFun1_2(x352,x351,x350,__ATypeAnFun_13,x349);
      x353=_ATypeAnFun_13(x348);
      x355=_ASeq_14(x353,x354);
      r=_AFormat_5(__ANat_9,x355);}}break;
   case 7:
    {OBJ x356=FLD(x1,1);OBJ x357=FLD(x1,2);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      COPY(x356,1);COPY(x357,1);
      FRPRD(x1,1);}
     CPCLS(__ATypeAnFun_34,1);
     CPCLS(__ATypeAnFun_51,1);
     CPCLS(__ATypeAnFun_53,1);
     CPCLS(__AIde_18,1);
     {OBJ x358;OBJ x359;OBJ x360;OBJ x362;OBJ x361;OBJ x363;
      x358=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_34,1))(__ATypeAnFun_34,__ABUILTIN_20);
      x359=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_51,1))(__ATypeAnFun_51,__ABUILTIN_20);
      x360=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_53,1))(__ATypeAnFun_53,__ABUILTIN_20);
      x362=_AFormatFun1_2(x359,x358,x360,__AIde_18,x356);
      x361=_ATypeAnFun_13(x357);
      x363=_ASeq_14(x362,x361);
      r=_AFormat_5(__ANat_9,x363);}}break;
   default: 
    {OBJ x317=FLD(x1,1);
     if(EXPRD(x1,1)){
      DSPRDF(x1);
     }else{
      CPPRD(x317,1);
      FRPRD(x1,1);}
     r=_AIde_18(x317);}}}
 return r;}

extern OBJ _ATypeAnFun_14(OBJ x1) /* format,2 */
{OBJ r;
 switch(TGPRD(x1)){
  case 1:
   {OBJ x56=FLD(x1,2);
    COPY(x56,1);
    CPCLS(__ATypeAnFun_57,1);
    COPY(__ATypeAnFun_58,1);
    {OBJ x57;OBJ x58;OBJ x59;OBJ x60;OBJ x61;
     x57=_ATypeAn_6(x1);
     x58=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_57,1))(__ATypeAnFun_57,__ABUILTIN_20);
     x59=_AIde_18(x57);
     x60=_ATypeAnFun_13(x56);
     x61=_ASeq_16(x59,x58,__ATypeAnFun_58,x60);
     r=_AFormat_5(__ANat_9,x61);}}break;
  case 2:
   CPCLS(__ATypeAnFun_60,1);
   {OBJ x65;OBJ x66;OBJ x67;OBJ x68;
    x65=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_60,1))(__ATypeAnFun_60,__ABUILTIN_20);
    x66=_ATypeAn_6(x1);
    x67=_AIde_18(x66);
    x68=_ASeq_14(x67,x65);
    r=_AFormat_5(__ANat_9,x68);}break;
  default: 
   CPCLS(__ATypeAnFun_55,1);
   {OBJ x51;OBJ x52;OBJ x53;OBJ x54;
    x51=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_55,1))(__ATypeAnFun_55,__ABUILTIN_20);
    x52=_ATypeAn_6(x1);
    x53=_AIde_18(x52);
    x54=_ASeq_14(x53,x51);
    r=_AFormat_5(__ANat_9,x54);}}
 return r;}

extern OBJ _ATypeAnFun_15(OBJ x1,OBJ x2,OBJ x3) /* getImportedWhen */
{OBJ r;
 {OBJ x23=FLD1(x2,1);
  if(EXPRD(x2,1)){
   FLD1(x2,1)=NIL;DSPRD(x2);
  }else{
   COPY(x23,1);
   FRPRD(x2,1);}
  {OBJ x33;
   if(ISPRM(x23)){
    x33=__ATypeAn_52;
   }else{
    {OBJ x28=FLD1(x23,1);
     if(EXPRD(x23,1)){
      x33=x28;
      FLD1(x23,1)=NIL;DSPRD(x23);
     }else{
      COPY(x28,1);
      x33=x28;
      FRPRD(x23,1);}}}
   if(ISPRD(x33)&&(ISTGPRD(x33,3))){
    {OBJ x34=FLD(x33,1);
     if(EXPRD(x33,1)){
      DSPRDF(x33);
     }else{
      CPPRD(x34,1);
      FRPRD(x33,1);}
     CPCLS(__ATypeAnFun_16,1);
     {OBJ x35;
      x35=(*(OBJ(*)(OBJ,OBJ))METHOD(__ATypeAnFun_16,1))(__ATypeAnFun_16,x1);
      r=_ANatMapReduce_3(x35,x3,x34);}}
   }else{
    FRCLS(x1,1);
    FREE(x33,1);
    r=x3;}}}
 return r;}

extern OBJ _ATypeAnFun_16(OBJ x1,OBJ x2,OBJ x3) /* getWhen */
{OBJ r;
 CPPRD(x2,1);
 {OBJ x4;
  x4=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x2);
  if(ISTGPRM(x4,1)){
   PRD1(2,r);FLD1(r,1)=x2;FLD1(r,2)=x3;
  }else{
   FRPRD(x2,1);
   r=x3;}}
 return r;}

extern OBJ _ATypeAnFun_17(OBJ x1,OBJ x2,OBJ x3) /* typeOfApply */
{OBJ r;
 if(ISTGPRD(x3,3)){
  {OBJ x30=FLD(x3,2);OBJ x31=FLD(x3,3);
   if(EXPRD(x3,1)){
    FREE(FLD(x3,1),1);DSPRDF(x3);
   }else{
    CPPRD(x30,1);COPY(x31,1);
    FRPRD(x3,1);}
   CPCLS(x2,1);
   {OBJ x32;OBJ x33;
    x32=_ATypeAnFun_5(x1,x2,x30);
    x33=_ATypeAnFun_6(x2,x32);
    if(ISPRD(x33)&&(ISTGPRD(x33,3))){
     {OBJ x34=FLD(x33,1);OBJ x35=FLD(x33,2);
      if(EXPRD(x33,1)){
       DSPRDF(x33);
      }else{
       COPY(x34,1);COPY(x35,1);
       FRPRD(x33,1);}
      {OBJ x36;
       x36=_ASeq_52(x31,__ANat_5);
       r=_ATypeAnFun_24(x34,x35,x36);}}
    }else{
     FREE(x31,1);
     FREE(x33,1);
     r=__ATypeAn_40;}}}
 }else{
  HLT("Ac at <unknown> : undefined selection fun\'Ac:exp->exp");}
 return r;}

extern OBJ _ATypeAnFun_18(OBJ x1,OBJ x2,OBJ x3) /* typeOfCase */
{OBJ r;
 if(ISTGPRD(x3,6)){
  {OBJ x31=FLD(x3,3);OBJ x32=FLD(x3,4);
   if(EXPRD(x3,1)){
    FLD(x3,3)=NIL;FLD(x3,4)=NIL;DSPRD(x3);
   }else{
    COPY(x31,1);CPPRD(x32,1);
    FRPRD(x3,1);}
   if(ISPRM(x31)){
    r=_ATypeAnFun_5(x1,x2,x32);
   }else{
    {OBJ x33=FLD1(x31,1);
     if(EXPRD(x31,1)){
      FREE(FLD1(x31,2),1);DSPRDF(x31);
     }else{
      CPPRD(x33,1);
      FRPRD(x31,1);}
     FRPRD(x32,1);
     {OBJ x37=FLD1(x33,3);
      if(EXPRD(x33,1)){
       FLD1(x33,3)=NIL;DSPRD(x33);
      }else{
       CPPRD(x37,1);
       FRPRD(x33,1);}
      r=_ATypeAnFun_5(x1,x2,x37);}}}}
 }else{
  HLT("Ac at <unknown> : undefined selection default\'Ac:exp->exp");}
 return r;}

extern OBJ _ATypeAnFun_19(OBJ x1,OBJ x2,OBJ x3) /* typeOfBlock */
{OBJ r;
 if(ISTGPRD(x3,5)){
  {OBJ x17=FLD(x3,2);OBJ x18=FLD(x3,3);
   if(EXPRD(x3,1)){
    FREE(FLD(x3,1),1);DSPRDF(x3);
   }else{
    COPY(x17,1);CPPRD(x18,1);
    FRPRD(x3,1);}
   CPCLS(__ATypeAnFun_25,1);
   {OBJ x19;
    x19=(*(OBJ(*)(OBJ,OBJ,OBJ))METHOD(__ATypeAnFun_25,2))(__ATypeAnFun_25,x1,x17);
    r=_ATypeAnFun_5(x19,x2,x18);}}
 }else{
  HLT("Ac at <unknown> : undefined selection binds\'Ac:exp->seq");}
 return r;}

extern OBJ _ATypeAnFun_20(OBJ x1,OBJ x2,OBJ x3) /* typeOfLambda */
{OBJ r;
 if(ISTGPRD(x3,4)){
  {OBJ x18=FLD(x3,2);OBJ x19=FLD(x3,3);
   if(EXPRD(x3,1)){
    COPY(x18,1);
    FREE(FLD(x3,1),1);DSPRDF(x3);
   }else{
    COPY(x18,2);CPPRD(x19,1);
    FRPRD(x3,1);}
   CPCLS(__ATypeAnFun_25,1);
   CPCLS(__ATypeAnFun_28,1);
   {OBJ x20;OBJ x21;
    x20=(*(OBJ(*)(OBJ,OBJ,OBJ))METHOD(__ATypeAnFun_25,2))(__ATypeAnFun_25,x1,x18);
    x21=_ATypeAnFun_5(x20,x2,x19);
    r=_ASeqReduce_3(__ATypeAnFun_28,x21,x18);}}
 }else{
  HLT("Ac at <unknown> : undefined selection vars\'Ac:exp->seq");}
 return r;}

extern OBJ _ATypeAnFun_21(OBJ x1,OBJ x2,OBJ x3) /* typeOfIde */
{OBJ r;
 FRCLS(x2,1);
 if(ISTGPRD(x3,2)){
  {OBJ x5=FLD(x3,2);
   if(EXPRD(x3,1)){
    FREE(FLD(x3,1),1);DSPRDF(x3);
   }else{
    CPPRD(x5,1);
    FRPRD(x3,1);}
   {OBJ x6;
    x6=x5;
    r=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x6);}}
 }else{
  HLT("Ac at <unknown> : undefined selection ide\'Ac:exp->ide");}
 return r;}

extern OBJ _ATypeAnFun_22(OBJ x1,OBJ x2,OBJ x3) /* typeOfDeno */
{OBJ r;
 COPY(__ATypeAnFun_27,1);
 FRCLS(x1,1);
 FRCLS(x2,1);
 FRPRD(x3,1);
 r=__ATypeAnFun_27;
 return r;}

extern OBJ _ATypeAnFun_23(OBJ x1,OBJ x2,OBJ x3) /* typeOfError */
{OBJ r;
 FRCLS(x1,1);
 FRCLS(x2,1);
 FRPRD(x3,1);
 r=__ATypeAn_40;
 return r;}

extern OBJ _ATypeAnFun_24(register OBJ x1,register OBJ x2,register OBJ x3) /* typeOfRes */
{OBJ r;
 for(;;){
  COPY(x1,1);
  {OBJ x4;OBJ x5;
   x4=_ASeq_52(x1,__ANat_5);
   ANat_79(x4,x3,x5);
   if(ISTGPRM(x5,1)){
    {OBJ x6;
     x6=_ASeq_32(x3,x1);
     if(ISPRM(x6)){
      r=x2;
     }else{
      PRD(2,3,r);FLD(r,1)=x6;FLD(r,2)=x2;}}
   }else{
    FREE(x1,1);
    if(ISPRD(x2)&&(ISTGPRD(x2,3))){
     {OBJ x25=FLD(x2,1);OBJ x26=FLD(x2,2);
      if(EXPRD(x2,1)){
       DSPRDF(x2);
      }else{
       COPY(x25,1);COPY(x26,1);
       FRPRD(x2,1);}
      {OBJ x27;
       ANat_62(x3,x4,x27);
       x1=x25;x2=x26;x3=x27;continue;}}
    }else{
     FREE(x2,1);
     r=__ATypeAn_40;}}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_25(register OBJ x1,register OBJ x2,register OBJ x3) /* refine */
{OBJ r;
 for(;;){
  if(ISPRM(x2)){
   r=(*(OBJ(*)(OBJ,OBJ))METHOD(x1,1))(x1,x3);
  }else{
   {OBJ x26=FLD1(x2,1);OBJ x27=FLD1(x2,2);
    if(EXPRD(x2,1)){
     CPPRD(x26,1);
     DSPRDF(x2);
    }else{
     CPPRD(x26,2);COPY(x27,1);
     FRPRD(x2,1);}
    CPPRD(x3,1);
    {OBJ x28;OBJ x29;
     x28=_AAc_21(x26);
     x29=_AIde_13(x28,x3);
     if(ISTGPRM(x29,1)){
      FRCLS(x1,1);
      FRPRD(x3,1);
      FREE(x27,1);
      {OBJ x30;OBJ x36;
       x30=_AAc_22(x26);
       if(ISPRM(x30)){
	x36=__ATypeAn_52;
       }else{
	{OBJ x31=FLD1(x30,1);
	 if(EXPRD(x30,1)){
	  x36=x31;
	  FLD1(x30,1)=NIL;DSPRD(x30);
	 }else{
	  COPY(x31,1);
	  x36=x31;
	  FRPRD(x30,1);}}}
       if(ISPRD(x36)&&(ISTGPRD(x36,1))){
	{OBJ x37=FLD(x36,1);
	 if(EXPRD(x36,1)){
	  r=x37;
	  DSPRDF(x36);
	 }else{
	  COPY(x37,1);
	  r=x37;
	  FRPRD(x36,1);}}
       }else{
	FREE(x36,1);
	r=__ATypeAn_40;}}
     }else{
      FRPRD(x26,1);
      x2=x27;continue;}}}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_26(register OBJ x1,register OBJ x2,register OBJ x3,register OBJ x4) /* substitute */
{OBJ r;
 for(;;){
  COPY(x3,1);
  {OBJ x5;OBJ x6;
   x5=_ASeq_52(x3,__ANat_5);
   ANat_6(x5,x6);
   if(ISTGPRM(x6,1)){
    FREE(x2,1);
    FREE(x3,1);
    r=_ATypeAnFun_10(x1,x4);
   }else{
    COPY(x2,1);
    {OBJ x7;OBJ x8;
     x7=_ASeq_52(x2,__ANat_5);
     ANat_81(x7,x5,x8);
     if(ISTGPRM(x8,1)){
      COPY(x2,1);
      CPCLS(__AIde_14,1);
      {OBJ x9;OBJ x10;OBJ x11;
       x9=_ASeq_32(x5,x2);
       x10=_ASeq_31(x5,x2);
       x11=_AMap_10(__AIde_14,x1,x10,x3);
       PRD(2,7,r);FLD(r,1)=x9;
       FLD(r,2)=_ATypeAnFun_10(x11,x4);}
     }else{
      {OBJ x15;OBJ x16;OBJ x17;
       if(ISPRD(x4)&&(ISTGPRD(x4,7))){
	COPY(x3,1);
	CPCLS(__AIde_14,1);
	x15=__ABUILTIN_5;
       }else{
	COPY(x3,1);
	CPCLS(__AIde_14,1);
	x15=__ABUILTIN_3;}
       x16=_ASeq_31(x7,x3);
       x17=_AMap_10(__AIde_14,x1,x2,x16);
       if(ISTGPRM(x15,1)){
	if(ISPRD(x4)&&(ISTGPRD(x4,7))){
	 {OBJ x25=FLD(x4,1);OBJ x26=FLD(x4,2);
	  if(EXPRD(x4,1)){
	   DSPRDF(x4);
	  }else{
	   COPY(x25,1);COPY(x26,1);
	   FRPRD(x4,1);}
	  {OBJ x27;
	   x27=_ASeq_32(x7,x3);
	   x1=x17;x2=x25;x3=x27;x4=x26;continue;}}
	}else{
	 HLT("TypeAn at <unknown> : undefined selection vars\'TypeAn:type->seq");}
       }else{
	FREE(x3,1);
	r=_ATypeAnFun_10(x17,x4);}}}}}}
  break;}
 return r;}

extern OBJ _ATypeAnFun_28(OBJ x1,OBJ x2) /* typeOfLambda'28 */
{OBJ r;
 {OBJ x3;OBJ x4;
  x3=_ATypeAnFun_4(x1);
  PRD1(2,x4);FLD1(x4,1)=x3;FLD1(x4,2)=__ASeq_6;
  PRD(2,3,r);FLD(r,1)=x4;FLD(r,2)=x2;}
 return r;}

extern OBJ _ATypeAnFun_30(OBJ x1) /* format,1'30 */
{OBJ r;
 CPPRD(__ATypeAnFun_29,1);
 r=_AFmt_28(__ATypeAnFun_29);
 return r;}

extern OBJ _ATypeAnFun_32(OBJ x1) /* format,1'32 */
{OBJ r;
 CPPRD(__ATypeAnFun_31,1);
 r=_AFmt_28(__ATypeAnFun_31);
 return r;}

extern OBJ _ATypeAnFun_34(OBJ x1) /* format,1'34 */
{OBJ r;
 CPPRD(__ATypeAnFun_33,1);
 r=_AFmt_28(__ATypeAnFun_33);
 return r;}

extern OBJ _ATypeAnFun_36(OBJ x1) /* format,1'36 */
{OBJ r;
 CPPRD(__ATypeAnFun_35,1);
 r=_AFmt_28(__ATypeAnFun_35);
 return r;}

extern OBJ _ATypeAnFun_39(OBJ x1) /* format,1'39 */
{OBJ r;
 CPPRD(__ATypeAnFun_38,1);
 r=_AFmt_28(__ATypeAnFun_38);
 return r;}

extern OBJ _ATypeAnFun_41(OBJ x1) /* format,1'41 */
{OBJ r;
 CPPRD(__ATypeAnFun_40,1);
 r=_AFmt_28(__ATypeAnFun_40);
 return r;}

extern OBJ _ATypeAnFun_43(OBJ x1) /* format,1'43 */
{OBJ r;
 CPPRD(__ATypeAnFun_42,1);
 r=_AFmt_28(__ATypeAnFun_42);
 return r;}

extern OBJ _ATypeAnFun_45(OBJ x1) /* format,1'45 */
{OBJ r;
 CPPRD(__ATypeAnFun_44,1);
 r=_AFmt_28(__ATypeAnFun_44);
 return r;}

extern OBJ _ATypeAnFun_47(OBJ x1) /* format,1'47 */
{OBJ r;
 CPPRD(__ATypeAnFun_46,1);
 r=_AFmt_28(__ATypeAnFun_46);
 return r;}

extern OBJ _ATypeAnFun_49(OBJ x1) /* format,1'49 */
{OBJ r;
 CPPRD(__ATypeAnFun_48,1);
 r=_AFmt_28(__ATypeAnFun_48);
 return r;}

extern OBJ _ATypeAnFun_51(OBJ x1) /* format,1'51 */
{OBJ r;
 CPPRD(__ATypeAnFun_50,1);
 r=_AFmt_28(__ATypeAnFun_50);
 return r;}

extern OBJ _ATypeAnFun_53(OBJ x1) /* format,1'53 */
{OBJ r;
 CPPRD(__ATypeAnFun_52,1);
 r=_AFmt_28(__ATypeAnFun_52);
 return r;}

extern OBJ _ATypeAnFun_55(OBJ x1) /* format,2'55 */
{OBJ r;
 CPPRD(__ATypeAnFun_54,1);
 r=_AFmt_28(__ATypeAnFun_54);
 return r;}

extern OBJ _ATypeAnFun_57(OBJ x1) /* format,2'57 */
{OBJ r;
 CPPRD(__ATypeAnFun_56,1);
 r=_AFmt_28(__ATypeAnFun_56);
 return r;}

extern OBJ _ATypeAnFun_60(OBJ x1) /* format,2'60 */
{OBJ r;
 CPPRD(__ATypeAnFun_59,1);
 r=_AFmt_28(__ATypeAnFun_59);
 return r;}

extern OBJ _ATypeAnFun_62(OBJ x1) /* format'62 */
{OBJ r;
 CPPRD(__ATypeAnFun_31,1);
 r=_AFmt_28(__ATypeAnFun_31);
 return r;}

extern OBJ _ATypeAnFun_63(OBJ x1) /* format'63 */
{OBJ r;
 CPPRD(__ATypeAnFun_33,1);
 r=_AFmt_28(__ATypeAnFun_33);
 return r;}

extern OBJ _ATypeAnFun_64(OBJ x1) /* format'64 */
{OBJ r;
 CPPRD(__ATypeAnFun_35,1);
 r=_AFmt_28(__ATypeAnFun_35);
 return r;}

extern OBJ _ATypeAnFun_66(OBJ x1) /* format'66 */
{OBJ r;
 CPPRD(__ATypeAnFun_65,1);
 r=_AFmt_28(__ATypeAnFun_65);
 return r;}





init_ATypeAnFun()
{
 static int visited=0; if(visited) return; visited=1;
 init_ASeqMap();
 init_ACompose();
 init_AArray();
 init_AMap();
 init_ANat();
 init_ASetByBST();
 init_ASeq();
 init_ABSTree();
 init_AFormat();
 init_ATree();
 init_AIde();
 init_AMapConv();
 init_ATypeAn();
 init_AIdeMap();
 init_AAc();
 init_ANatMap();
 init_AAn();
 init_ASourceAn();
 init_AOptimAn();
 init_ATransAn();
 init_APragmaAn();
 init_AOption();
 init_AStore();
 init_AString();
 init_ACom();
 init_AStream();
 init_AVoid();
 init_AFmt();
 init_AChar();
 init_AFile();
 init_AInt();
 init_ASet();
 init_APair();
 init_ABuiltin();
 init_ANatMapReduce();
 init_AFormatFun1();
 init_ASeqReduce();
 LCLS(1,_ATypeAnFun_63,__ATypeAnFun_63);
 DEN("(",__ATypeAnFun_31);
 LCLS(1,_ATypeAnFun_62,__ATypeAnFun_62);
 LCLS(1,_ATypeAnFun_30,__ATypeAnFun_30);
 DEN("SOME",__ATypeAnFun_29);
 LCLS(1,_ATypeAnFun_60,__ATypeAnFun_60);
 CLS(2,_ATypeAnFun_28,__ATypeAnFun_28);
 DEN(" = foreign",__ATypeAnFun_59);
 CLS(4,_ATypeAnFun_26,__ATypeAnFun_26);
 LCLS(1,_ATypeAnFun_57,__ATypeAnFun_57);
 CLS(3,_ATypeAnFun_25,__ATypeAnFun_25);
 DEN(" =",__ATypeAnFun_56);
 CLS(3,_ATypeAnFun_24,__ATypeAnFun_24);
 LCLS(1,_ATypeAnFun_55,__ATypeAnFun_55);
 CLS(3,_ATypeAnFun_23,__ATypeAnFun_23);
 DEN(" = hidden",__ATypeAnFun_54);
 CLS(3,_ATypeAnFun_22,__ATypeAnFun_22);
 LCLS(1,_ATypeAnFun_53,__ATypeAnFun_53);
 CLS(3,_ATypeAnFun_21,__ATypeAnFun_21);
 DEN(".",__ATypeAnFun_52);
 CLS(3,_ATypeAnFun_20,__ATypeAnFun_20);
 LCLS(1,_ATypeAnFun_51,__ATypeAnFun_51);
 CLS(3,_ATypeAnFun_19,__ATypeAnFun_19);
 DEN("%",__ATypeAnFun_50);
 CLS(3,_ATypeAnFun_18,__ATypeAnFun_18);
 LCLS(1,_ATypeAnFun_49,__ATypeAnFun_49);
 CLS(3,_ATypeAnFun_17,__ATypeAnFun_17);
 DEN("}",__ATypeAnFun_48);
 CLS(3,_ATypeAnFun_16,__ATypeAnFun_16);
 LCLS(1,_ATypeAnFun_47,__ATypeAnFun_47);
 CLS(3,_ATypeAnFun_15,__ATypeAnFun_15);
 DEN("{",__ATypeAnFun_46);
 CLS(1,_ATypeAnFun_14,__ATypeAnFun_14);
 LCLS(1,_ATypeAnFun_45,__ATypeAnFun_45);
 CLS(1,_ATypeAnFun_13,__ATypeAnFun_13);
 DEN("|",__ATypeAnFun_44);
 CLS(1,_ATypeAnFun_12,__ATypeAnFun_12);
 LCLS(1,_ATypeAnFun_43,__ATypeAnFun_43);
 CLS(1,_ATypeAnFun_11,__ATypeAnFun_11);
 DEN(">",__ATypeAnFun_42);
 CLS(2,_ATypeAnFun_10,__ATypeAnFun_10);
 LCLS(1,_ATypeAnFun_41,__ATypeAnFun_41);
 CLS(2,_ATypeAnFun_9,__ATypeAnFun_9);
 DEN("<",__ATypeAnFun_40);
 CLS(2,_ATypeAnFun_8,__ATypeAnFun_8);
 LCLS(1,_ATypeAnFun_39,__ATypeAnFun_39);
 CLS(2,_ATypeAnFun_7,__ATypeAnFun_7);
 DEN("->",__ATypeAnFun_38);
 CLS(2,_ATypeAnFun_6,__ATypeAnFun_6);
 CLS(3,_ATypeAnFun_5,__ATypeAnFun_5);
 LCLS(1,_ATypeAnFun_36,__ATypeAnFun_36);
 CLS(1,_ATypeAnFun_4,__ATypeAnFun_4);
 DEN(")",__ATypeAnFun_35);
 CLS(2,_ATypeAnFun_3,__ATypeAnFun_3);
 LCLS(1,_ATypeAnFun_66,__ATypeAnFun_66);
 CLS(2,_ATypeAnFun_2,__ATypeAnFun_2);
 LCLS(1,_ATypeAnFun_34,__ATypeAnFun_34);
 DEN("",__ATypeAnFun_65);
 CLS(2,_ATypeAnFun_1,__ATypeAnFun_1);
 DEN(",",__ATypeAnFun_33);
 LCLS(1,_ATypeAnFun_64,__ATypeAnFun_64);
 LCLS(1,_ATypeAnFun_32,__ATypeAnFun_32);
 CPPRD(__ABuiltin_12,1);
 PRD(1,1,__ATypeAnFun_27);FLD(__ATypeAnFun_27,1)=__ABuiltin_12;
 PRDF(1,1,__ATypeAnFun_37);FLD(__ATypeAnFun_37,1)=__ANat_5;
 PRDF(1,1,__ATypeAnFun_58);FLD(__ATypeAnFun_58,1)=__ANat_8;
 PRDF(1,1,__ATypeAnFun_61);FLD(__ATypeAnFun_61,1)=__ANat_5;}

