/*===========================================================================*/
/*   (Llib/struct.scm)                                                       */
/*   Bigloo (2.6b)                                                           */
/*   Inria -- Sophia Antipolis (c)       Mon Dec 15 12:14:36 CET 2003        */
/*===========================================================================*/
/* COMPILATION: (/users/serrano/prgm/project/bigloo/bin/bigloo -O4 -mklib -cc gcc-2.95 -fsharing -q -s -copt -DBGL_NO_PIC -unsafe -c Llib/struct.scm -indent -o objs/obj_u/Llib/struct.c)*/
/* GC selection */
#define THE_GC BOEHM_GC

#include <bigloo.h>
#include <signal.h>

BGL_EXPORTED_DECL obj_t BGl_modulezd2initializa7ationz75zz__structurez00(long, char *);
extern obj_t BGl_modulezd2initializa7ationz75zz__errorz00(long, char *);
static obj_t BGl__recordzf3zf3zz__structurez00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_makezd2structzd2zz__structurez00(obj_t, int, obj_t);
BGL_EXPORTED_DECL bool_t BGl_recordzf3zf3zz__structurez00(obj_t);
BGL_EXPORTED_DECL obj_t BGl_structzd2setz12zc0zz__structurez00(obj_t, int, obj_t);
BGL_EXPORTED_DECL int BGl_structzd2lengthzd2zz__structurez00(obj_t);
BGL_EXPORTED_DECL obj_t BGl_structzd2refzd2zz__structurez00(obj_t, int);
static obj_t BGl__structzd2updatez12zc0zz__structurez00(obj_t, obj_t, obj_t);
static obj_t BGl__structzd2lengthzd2zz__structurez00(obj_t, obj_t);
static obj_t BGl__structzf3zf3zz__structurez00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_structzd2keyzd2setz12z12zz__structurez00(obj_t, obj_t);
BGL_EXPORTED_DECL bool_t BGl_structzf3zf3zz__structurez00(obj_t);
BGL_EXPORTED_DECL obj_t BGl_structzd2keyzd2zz__structurez00(obj_t);
static obj_t BGl__structzd2refzd2zz__structurez00(obj_t, obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_structzd2updatez12zc0zz__structurez00(obj_t, obj_t);
static obj_t BGl__structzd2setz12zc0zz__structurez00(obj_t, obj_t, obj_t, obj_t);
static obj_t BGl_importedzd2moduleszd2initz00zz__structurez00();
extern obj_t make_struct(obj_t, int, obj_t);
static obj_t BGl_requirezd2initializa7ationz75zz__structurez00 = BUNSPEC;
static obj_t BGl__structzd2keyzd2zz__structurez00(obj_t, obj_t);
static obj_t BGl__makezd2structzd2zz__structurez00(obj_t, obj_t, obj_t, obj_t);
static obj_t BGl__structzd2keyzd2setz12z12zz__structurez00(obj_t, obj_t, obj_t);
static obj_t *__cnst;


DEFINE_STRING( BGl_string1635z00zz__structurez00, BgL_bgl_string1635za700za7za7__structureza7001641z00, "Incompatible structures", 23 );
DEFINE_STRING( BGl_string1634z00zz__structurez00, BgL_bgl_string1634za700za7za7__structureza7001642z00, "struct-update!", 14 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2keyzd2envz00zz__structurez00, BgL_bgl__structza7d2keyza7d2za7za7__structureza7001643za7, BGl__structzd2keyzd2zz__structurez00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_structzf3zd2envz21zz__structurez00, BgL_bgl__structza7f3za7f3za7za7__structureza7001644za7, BGl__structzf3zf3zz__structurez00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_makezd2structzd2envz00zz__structurez00, BgL_bgl__makeza7d2structza7d2za7za7__structureza7001645za7, BGl__makezd2structzd2zz__structurez00, 0L, 3 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2refzd2envz00zz__structurez00, BgL_bgl__structza7d2refza7d2za7za7__structureza7001646za7, BGl__structzd2refzd2zz__structurez00, 0L, 2 );
DEFINE_EXPORT_PROCEDURE( BGl_recordzf3zd2envz21zz__structurez00, BgL_bgl__recordza7f3za7f3za7za7__structureza7001647za7, BGl__recordzf3zf3zz__structurez00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2lengthzd2envz00zz__structurez00, BgL_bgl__structza7d2lengthza7d2za7za7__structureza7001648za7, BGl__structzd2lengthzd2zz__structurez00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2updatez12zd2envz12zz__structurez00, BgL_bgl__structza7d2updateza712za7c0za7za7__structureza7001649z00, BGl__structzd2updatez12zc0zz__structurez00, 0L, 2 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2keyzd2setz12zd2envzc0zz__structurez00, BgL_bgl__structza7d2keyza7d2setza712za712za7za7__structureza7001650za7, BGl__structzd2keyzd2setz12z12zz__structurez00, 0L, 2 );
DEFINE_EXPORT_PROCEDURE( BGl_structzd2setz12zd2envz12zz__structurez00, BgL_bgl__structza7d2setza712za7c0za7za7__structureza7001651z00, BGl__structzd2setz12zc0zz__structurez00, 0L, 3 );



/* module-initialization */
BGL_EXPORTED_DEF obj_t BGl_modulezd2initializa7ationz75zz__structurez00(long BgL_checksumz00_517, char * BgL_fromz00_518)
{ AN_OBJECT;
{ 
if(
CBOOL(BGl_requirezd2initializa7ationz75zz__structurez00))
{ 
BGl_requirezd2initializa7ationz75zz__structurez00 = 
BBOOL(((bool_t)0)); 
BGl_importedzd2moduleszd2initz00zz__structurez00(); 
return BUNSPEC;}  else 
{ 
return BUNSPEC;} } 
}



/* make-struct */
BGL_EXPORTED_DEF obj_t BGl_makezd2structzd2zz__structurez00(obj_t BgL_keyz00_1, int BgL_lenz00_2, obj_t BgL_initz00_3)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 117 */
return 
make_struct(BgL_keyz00_1, BgL_lenz00_2, BgL_initz00_3);} 
}



/* _make-struct */
obj_t BGl__makezd2structzd2zz__structurez00(obj_t BgL_envz00_477, obj_t BgL_keyz00_478, obj_t BgL_lenz00_479, obj_t BgL_initz00_480)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 117 */
{ /* ./Llib/struct.scm 118 */
int BgL_auxz00_524;
BgL_auxz00_524 = 
CINT(BgL_lenz00_479); 
return 
make_struct(BgL_keyz00_478, BgL_auxz00_524, BgL_initz00_480);} } 
}



/* struct? */
BGL_EXPORTED_DEF bool_t BGl_structzf3zf3zz__structurez00(obj_t BgL_oz00_4)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 123 */
return 
STRUCTP(BgL_oz00_4);} 
}



/* _struct? */
obj_t BGl__structzf3zf3zz__structurez00(obj_t BgL_envz00_481, obj_t BgL_oz00_482)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 123 */
{ /* ./Llib/struct.scm 124 */
bool_t BgL_auxz00_528;
BgL_auxz00_528 = 
STRUCTP(BgL_oz00_482); 
return 
BBOOL(BgL_auxz00_528);} } 
}



/* record? */
BGL_EXPORTED_DEF bool_t BGl_recordzf3zf3zz__structurez00(obj_t BgL_oz00_5)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 129 */
return 
STRUCTP(BgL_oz00_5);} 
}



/* _record? */
obj_t BGl__recordzf3zf3zz__structurez00(obj_t BgL_envz00_483, obj_t BgL_oz00_484)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 129 */
{ /* ./Llib/struct.scm 130 */
bool_t BgL_auxz00_532;
BgL_auxz00_532 = 
STRUCTP(BgL_oz00_484); 
return 
BBOOL(BgL_auxz00_532);} } 
}



/* struct-key */
BGL_EXPORTED_DEF obj_t BGl_structzd2keyzd2zz__structurez00(obj_t BgL_sz00_6)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 135 */
return 
STRUCT_KEY(BgL_sz00_6);} 
}



/* _struct-key */
obj_t BGl__structzd2keyzd2zz__structurez00(obj_t BgL_envz00_485, obj_t BgL_sz00_486)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 135 */
return 
STRUCT_KEY(BgL_sz00_486);} 
}



/* struct-key-set! */
BGL_EXPORTED_DEF obj_t BGl_structzd2keyzd2setz12z12zz__structurez00(obj_t BgL_sz00_7, obj_t BgL_kz00_8)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 141 */
return 
STRUCT_KEY_SET(BgL_sz00_7, BgL_kz00_8);} 
}



/* _struct-key-set! */
obj_t BGl__structzd2keyzd2setz12z12zz__structurez00(obj_t BgL_envz00_487, obj_t BgL_sz00_488, obj_t BgL_kz00_489)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 141 */
return 
STRUCT_KEY_SET(BgL_sz00_488, BgL_kz00_489);} 
}



/* struct-length */
BGL_EXPORTED_DEF int BGl_structzd2lengthzd2zz__structurez00(obj_t BgL_sz00_9)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 147 */
return 
STRUCT_LENGTH(BgL_sz00_9);} 
}



/* _struct-length */
obj_t BGl__structzd2lengthzd2zz__structurez00(obj_t BgL_envz00_490, obj_t BgL_sz00_491)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 147 */
{ /* ./Llib/struct.scm 148 */
int BgL_auxz00_540;
BgL_auxz00_540 = 
STRUCT_LENGTH(BgL_sz00_491); 
return 
BINT(BgL_auxz00_540);} } 
}



/* struct-ref */
BGL_EXPORTED_DEF obj_t BGl_structzd2refzd2zz__structurez00(obj_t BgL_sz00_10, int BgL_kz00_11)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 153 */
return 
STRUCT_REF(BgL_sz00_10, BgL_kz00_11);} 
}



/* _struct-ref */
obj_t BGl__structzd2refzd2zz__structurez00(obj_t BgL_envz00_492, obj_t BgL_sz00_493, obj_t BgL_kz00_494)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 153 */
{ /* ./Llib/struct.scm 154 */
int BgL_auxz00_544;
BgL_auxz00_544 = 
CINT(BgL_kz00_494); 
return 
STRUCT_REF(BgL_sz00_493, BgL_auxz00_544);} } 
}



/* struct-set! */
BGL_EXPORTED_DEF obj_t BGl_structzd2setz12zc0zz__structurez00(obj_t BgL_sz00_12, int BgL_kz00_13, obj_t BgL_oz00_14)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 159 */
return 
STRUCT_SET(BgL_sz00_12, BgL_kz00_13, BgL_oz00_14);} 
}



/* _struct-set! */
obj_t BGl__structzd2setz12zc0zz__structurez00(obj_t BgL_envz00_495, obj_t BgL_sz00_496, obj_t BgL_kz00_497, obj_t BgL_oz00_498)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 159 */
{ /* ./Llib/struct.scm 160 */
int BgL_auxz00_548;
BgL_auxz00_548 = 
CINT(BgL_kz00_497); 
return 
STRUCT_SET(BgL_sz00_496, BgL_auxz00_548, BgL_oz00_498);} } 
}



/* struct-update! */
BGL_EXPORTED_DEF obj_t BGl_structzd2updatez12zc0zz__structurez00(obj_t BgL_dstz00_15, obj_t BgL_srcz00_16)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 165 */
{ /* ./Llib/struct.scm 166 */
bool_t BgL_test1011z00_295;
{ /* ./Llib/struct.scm 166 */
bool_t BgL_testz00_551;
{ /* ./Llib/struct.scm 166 */
obj_t BgL_auxz00_554;obj_t BgL_auxz00_552;
BgL_auxz00_554 = 
STRUCT_KEY(BgL_srcz00_16); 
BgL_auxz00_552 = 
STRUCT_KEY(BgL_dstz00_15); 
BgL_testz00_551 = 
(BgL_auxz00_552==BgL_auxz00_554); } 
if(BgL_testz00_551)
{ /* ./Llib/struct.scm 167 */
long BgL_auxz00_561;long BgL_auxz00_557;
{ /* ./Llib/struct.scm 167 */
int BgL_auxz00_562;
BgL_auxz00_562 = 
STRUCT_LENGTH(BgL_srcz00_16); 
BgL_auxz00_561 = 
(long)(BgL_auxz00_562); } 
{ /* ./Llib/struct.scm 167 */
int BgL_auxz00_558;
BgL_auxz00_558 = 
STRUCT_LENGTH(BgL_dstz00_15); 
BgL_auxz00_557 = 
(long)(BgL_auxz00_558); } 
BgL_test1011z00_295 = 
(BgL_auxz00_557==BgL_auxz00_561); }  else 
{ /* ./Llib/struct.scm 166 */
BgL_test1011z00_295 = ((bool_t)0); } } 
if(BgL_test1011z00_295)
{ 
long BgL_iz00_296;
{ /* ./Llib/struct.scm 168 */
long BgL_auxz00_578;
{ /* ./Llib/struct.scm 168 */
int BgL_auxz00_579;
BgL_auxz00_579 = 
STRUCT_LENGTH(BgL_dstz00_15); 
BgL_auxz00_578 = 
(long)(BgL_auxz00_579); } 
BgL_iz00_296 = 
(BgL_auxz00_578-((long)1)); } 
BgL_loopz00_297:
if(
(BgL_iz00_296==((long)-1)))
{ /* ./Llib/struct.scm 169 */
return BgL_dstz00_15;}  else 
{ /* ./Llib/struct.scm 169 */
{ /* ./Llib/struct.scm 172 */
obj_t BgL_auxz00_571;int BgL_auxz00_569;
{ /* ./Llib/struct.scm 172 */
int BgL_auxz00_572;
BgL_auxz00_572 = 
(int)(BgL_iz00_296); 
BgL_auxz00_571 = 
STRUCT_REF(BgL_srcz00_16, BgL_auxz00_572); } 
BgL_auxz00_569 = 
(int)(BgL_iz00_296); 
STRUCT_SET(BgL_dstz00_15, BgL_auxz00_569, BgL_auxz00_571); } 
{ 
long BgL_iz00_576;
BgL_iz00_576 = 
(BgL_iz00_296-((long)1)); 
BgL_iz00_296 = BgL_iz00_576; 
goto BgL_loopz00_297;} } }  else 
{ /* ./Llib/struct.scm 174 */
obj_t BgL_arg1033z00_306;
{ /* ./Llib/struct.scm 174 */
obj_t BgL_list1036z00_307;
{ /* ./Llib/struct.scm 174 */
obj_t BgL_arg1038z00_308;
BgL_arg1038z00_308 = 
MAKE_PAIR(BgL_srcz00_16, BNIL); 
BgL_list1036z00_307 = 
MAKE_PAIR(BgL_dstz00_15, BgL_arg1038z00_308); } 
BgL_arg1033z00_306 = BgL_list1036z00_307; } 
FAILURE(BGl_string1634z00zz__structurez00,BGl_string1635z00zz__structurez00,BgL_arg1033z00_306);} } } 
}



/* _struct-update! */
obj_t BGl__structzd2updatez12zc0zz__structurez00(obj_t BgL_envz00_499, obj_t BgL_dstz00_500, obj_t BgL_srcz00_501)
{ AN_OBJECT;
{ /* ./Llib/struct.scm 165 */
return 
BGl_structzd2updatez12zc0zz__structurez00(BgL_dstz00_500, BgL_srcz00_501);} 
}



/* imported-modules-init */
obj_t BGl_importedzd2moduleszd2initz00zz__structurez00()
{ AN_OBJECT;
{ /* ./Llib/struct.scm 18 */
return 
BGl_modulezd2initializa7ationz75zz__errorz00(((long)11084), "__structure");} 
}

