

#include "BUILTIN.h"

#include "Nat.h"

#include "Int.h"

#include "Real.h"

#include "Char.h"
extern OBJ __ABoolConv_2;
extern OBJ __ABoolConv_3;

#include "CharConv.h"

#include "Denotation.h"

#include "IntConv.h"

#include "NatConv.h"

#include "RealConv.h"
extern OBJ _AStringConv_1(OBJ);extern OBJ __AStringConv_1;
extern OBJ _ASeqConv_2(OBJ,OBJ);extern OBJ __ASeqConv_2;
extern OBJ _ABTUnionConv_1(OBJ);OBJ __ABTUnionConv_1; /* ` */
extern OBJ _ABTUnionConv_2(OBJ);OBJ __ABTUnionConv_2; /* `,1 */
OBJ __ABTUnionConv_3; /* `'3 */
OBJ __ABTUnionConv_4; /* `'4 */
OBJ __ABTUnionConv_5; /* `'5 */
OBJ __ABTUnionConv_6; /* `'6 */
OBJ __ABTUnionConv_7; /* `'7 */
OBJ __ABTUnionConv_8; /* `'8 */
OBJ __ABTUnionConv_9; /* `'9 */

extern OBJ _ABTUnionConv_1(OBJ x1) /* ` */
{OBJ r;
 switch(TGPRD(x1)){
  case 5:
   {OBJ x82=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     FRPRD(x1,1);}
    {OBJ x83;
     if(ISTGPRM(x82,1)){
      CPPRD(__ABTUnionConv_4,1);
      CPPRD(__ABoolConv_2,1);
      x83=__ABoolConv_2;
     }else{
      CPPRD(__ABTUnionConv_4,1);
      CPPRD(__ABoolConv_3,1);
      x83=__ABoolConv_3;}
     ADenotation_4(__ABTUnionConv_4,x83,r);}}break;
  case 6:
   {OBJ x84=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     CPPRD(x84,1);
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_5,1);
    ADenotation_4(__ABTUnionConv_5,x84,r);}break;
  case 4:
   {OBJ x85=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     COPY(x85,1);
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_6,1);
    {OBJ x86;
     x86=_AStringConv_1(x85);
     ADenotation_4(__ABTUnionConv_6,x86,r);}}break;
  case 1:
   {OBJ x87=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_7,1);
    {OBJ x88;
     AIntConv_1(x87,x88);
     ADenotation_4(__ABTUnionConv_7,x88,r);}}break;
  case 2:
   {OBJ x89=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     CPPRD(x89,1);
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_8,1);
    {OBJ x90;
     ARealConv_2(x89,__ANat_23,x90);
     ADenotation_4(__ABTUnionConv_8,x90,r);}}break;
  case 0:
   {OBJ x91=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_9,1);
    {OBJ x92;
     ANatConv_1(x91,x92);
     ADenotation_4(__ABTUnionConv_9,x92,r);}}break;
  default: 
   {OBJ x80=FLD(x1,1);
    if(EXPRD(x1,1)){
     DSPRDF(x1);
    }else{
     FRPRD(x1,1);}
    CPPRD(__ABTUnionConv_3,1);
    {OBJ x81;
     ADenotation_1(__ANat_8,x80,x81);
     ADenotation_4(__ABTUnionConv_3,x81,r);}}}
 return r;}

extern OBJ _ABTUnionConv_2(OBJ x1) /* `,1 */
{OBJ r;
 CPCLS(__ABTUnionConv_1,1);
 r=_ASeqConv_2(__ABTUnionConv_1,x1);
 return r;}

init_ABTUnionConv()
{
 static int visited=0; if(visited) return; visited=1;
 init_ABTUnion();
 init_ASeq();
 init_ANat();
 init_AOption();
 init_AInt();
 init_AReal();
 init_AChar();
 init_AString();
 init_ABoolConv();
 init_ACharConv();
 init_ADenotation();
 init_AIntConv();
 init_ANatConv();
 init_ARealConv();
 init_AStringConv();
 init_ASeqConv();
 init_AStringMapSeq();
 DEN("nat:",__ABTUnionConv_9);
 DEN("real:",__ABTUnionConv_8);
 DEN("int:",__ABTUnionConv_7);
 DEN("string:",__ABTUnionConv_6);
 DEN("denotation:",__ABTUnionConv_5);
 DEN("bool:",__ABTUnionConv_4);
 DEN("char:",__ABTUnionConv_3);
 CLS(1,_ABTUnionConv_2,__ABTUnionConv_2);
 CLS(1,_ABTUnionConv_1,__ABTUnionConv_1);}

