

#include "BUILTIN.h"
extern OBJ _AMapByOS_32(OBJ,OBJ,OBJ,OBJ);extern OBJ __AMapByOS_32;
extern OBJ _AMapByOS_36(OBJ,OBJ,OBJ);extern OBJ __AMapByOS_36;

#include "Nat.h"
extern OBJ __ASeq_6;
extern OBJ _AMapByOSReduce_8(OBJ,OBJ,OBJ,OBJ);extern OBJ __AMapByOSReduce_8;
extern OBJ _AMapByOSCompose_6(OBJ,OBJ,OBJ,OBJ);OBJ __AMapByOSCompose_6; /* o */
extern OBJ _AMapByOSCompose_7(OBJ,OBJ,OBJ,OBJ,OBJ,OBJ);OBJ __AMapByOSCompose_7; /* o'7 */

extern OBJ _AMapByOSCompose_6(OBJ x1,OBJ x2,OBJ x3,OBJ x4) /* o */
{OBJ r;
 CPCLS(__AMapByOSCompose_7,1);
 CPCLS(x1,1);
 {OBJ x5;
  x5=(*(OBJ(*)(OBJ,OBJ,OBJ,OBJ))METHOD(__AMapByOSCompose_7,3))(__AMapByOSCompose_7,x1,x2,x4);
  r=_AMapByOSReduce_8(x1,x5,__ASeq_6,x3);}
 return r;}

extern OBJ _AMapByOSCompose_7(OBJ x1,OBJ x2,OBJ x3,OBJ x4,OBJ x5,OBJ x6) /* o'7 */
{OBJ r;
 {OBJ x7;
  x7=_AMapByOS_36(x2,x3,x5);
  if(ISPRM(x7)){
   FRCLS(x1,1);
   FREE(x4,1);
   r=x6;
  }else{
   {OBJ x12=FLD1(x7,1);
    if(EXPRD(x7,1)){
     DSPRDF(x7);
    }else{
     COPY(x12,1);
     FRPRD(x7,1);}
    r=_AMapByOS_32(x1,x4,x12,x6);}}}
 return r;}

static OBJ _mt_4_0_2(OBJ t,OBJ t1,OBJ t2) 
{OBJ r;
 DPCLS(t,r);
 INCCLS(r,0,2);
 FLDCLS(r,1)=t1;
 FLDCLS(r,2)=t2;
 return r;}

static OBJ _mt_4_2_2(OBJ t,OBJ t1,OBJ t2) 
{OBJ r;
 if(EXCLS(t)){
  DSCLSF(t);
 }else{
  COPY(FLDCLS(t,1),1);
  COPY(FLDCLS(t,2),1);
  DCCLS(t,1);}
 r=(*(OBJ(*)(OBJ,OBJ,OBJ,OBJ))ENTRY(t))(FLDCLS(t,1),FLDCLS(t,2),t1,t2);
 return r;}

static OBJ _mt_6_0_3(OBJ t,OBJ t1,OBJ t2,OBJ t3) 
{OBJ r;
 DPCLS(t,r);
 INCCLS(r,0,3);
 FLDCLS(r,1)=t1;
 FLDCLS(r,2)=t2;
 FLDCLS(r,3)=t3;
 return r;}

static OBJ _mt_6_0_6(OBJ t,OBJ t1,OBJ t2,OBJ t3,OBJ t4,OBJ t5,OBJ t6) 
{OBJ r;
 DCCLS(t,1);
 r=(*(OBJ(*)(OBJ,OBJ,OBJ,OBJ,OBJ,OBJ))ENTRY(t))(t1,t2,t3,t4,t5,t6);
 return r;}

static OBJ _mt_6_3_3(OBJ t,OBJ t1,OBJ t2,OBJ t3) 
{OBJ r;
 if(EXCLS(t)){
  DSCLSF(t);
 }else{
  COPY(FLDCLS(t,1),1);
  COPY(FLDCLS(t,2),1);
  COPY(FLDCLS(t,3),1);
  DCCLS(t,1);}
 r=(*(OBJ(*)(OBJ,OBJ,OBJ,OBJ,OBJ,OBJ))ENTRY(t))(FLDCLS(t,1),FLDCLS(t,2),FLDCLS(t,3),t1,t2,t3);
 return r;}

init_AMapByOSCompose()
{
 static int visited=0; if(visited) return; visited=1;
 init_AMapByOS();
 init_ANat();
 init_AOption();
 init_ASet();
 init_ASeq();
 init_APair();
 init_AMapByOSReduce();
 init_ASeqMap();
 CLS(6,_AMapByOSCompose_7,__AMapByOSCompose_7);
 CLS(4,_AMapByOSCompose_6,__AMapByOSCompose_6);
 MTH(4,0,2,_mt_4_0_2);LZYMTH(4,0,2,_mt_4_0_2);
 MTH(4,2,2,_mt_4_2_2);LZYMTH(4,2,2,_mt_4_2_2);
 MTH(6,0,3,_mt_6_0_3);LZYMTH(6,0,3,_mt_6_0_3);
 MTH(6,0,6,_mt_6_0_6);LZYMTH(6,0,6,_mt_6_0_6);
 MTH(6,3,3,_mt_6_3_3);LZYMTH(6,3,3,_mt_6_3_3);}

