/*
-- ANSI C code generated by :
-- SmallEiffel The GNU Eiffel Compiler -- Release (- 0.82)      --
-- Copyright (C), 1994-98 - LORIA - UHP - CRIN - INRIA - FRANCE --
-- Dominique COLNET and Suzanne COLLIN -    colnet@loria.fr     --
--                 http://www.loria.fr/SmallEiffel              --
*/
#include "pretty.h"
void r686clear_all(T686 C,int a1){
int _i=0;
int _v=0;
_i=a1;
while (!((_i)<(0))) {
(C)[_i]=(_v);
_i=(_i)-(1);
}
}
void r686set_all_with(T686 C,int a1,int a2){
int _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=(a1);
_i=(_i)-(1);
}
}
int r686fast_index_of(T686 C,int a1,int a2){
int R=0;
while (!(((R)>(a2))||((a1)==((C)[R])))) {
R=(R)+(1);
}
return R;
}
void r686copy_from(T686 C,T686 a1,int a2){
int _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T686 r686realloc(T686 C,int a1,int a2){
T686 R=NULL;
R=calloc(a2,sizeof(int));
r686copy_from(R,C,(a1)-(1));
return R;
}
void r44copy_from(T44 C,T44 a1,int a2){
int _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T44 r44realloc(T44 C,int a1,int a2){
T44 R=NULL;
R=calloc(a2,sizeof(T0*));
r44copy_from(R,C,(a1)-(1));
return R;
}
void r191copy_from(T191 C,T191 a1,int a2){
int _i=0;
_i=a2;
while (!((_i)<(0))) {
(C)[_i]=((a1)[_i]);
_i=(_i)-(1);
}
}
T191 r191realloc(T191 C,int a1,int a2){
T191 R=NULL;
R=calloc(a2,sizeof(T0*));
r191copy_from(R,C,(a1)-(1));
return R;
}
void r7add_first(T7* C,char a1){
int _i=0;
r7extend(C,'\40');
_i=(((T7*)C))->_count/*4*/;
while (!((_i)==(1))) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]=(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[((_i)-(1))-(1)]/*)*/);
/*]*/
_i=(_i)-(1);
}
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(1)-(1)]=(a1);
/*]*/
}
void r7extend(T7* C,char a1){
int _new_capacity=0;
/*IF*/if (((((T7*)C))->_capacity/*8*/)>((((T7*)C))->_count/*4*/)) {
}
 else if (((((T7*)C))->_capacity/*8*/)==(0)) {
C->_capacity=32;
C->_storage=calloc((((T7*)C))->_capacity/*8*/,sizeof(char));
}
else {
_new_capacity=(2)*((((T7*)C))->_capacity/*8*/);
C->_storage=r9realloc((((T7*)C))->_storage/*0*/,(((T7*)C))->_capacity/*8*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI*/C->_count=((((T7*)C))->_count/*4*/)+(1);
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[((((T7*)C))->_count/*4*/)-(1)]=(a1);
/*]*/
}
void r7set_last(T7* C,char a1){
/*IF*/if ((((((T7*)C))->_count/*4*/)==(0))||((/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[((((T7*)C))->_count/*4*/)-(1)]/*)*/)!=(a1))) {
r7extend(C,a1);
}
/*FI*/}
/*No:STRING.remove_suffix*/
void r7to_lower(T7* C){
int _i=0;
_i=(((T7*)C))->_count/*4*/;
while (!((_i)==(0))) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]=(r3to_lower(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]/*)*/));
/*]*/
_i=(_i)-(1);
}
}
int r7hash_code(T7* C){
int R=0;
R=r9hashcode((((T7*)C))->_storage/*0*/,((((T7*)C))->_count/*4*/)-(1));
return R;
}
/*No:STRING.empty*/
int r7index_of_string(T7* C,T0* a1){
int R=0;
int _i3=0;
int _i2=0;
int _i1=0;
int _stop=0;
_i1=1;
_i2=(((T7*)((T7*)a1)))->_count/*4*/;
_i3=_i2;
while (!((R)!=(0))) {
/*IF*/if ((_i2)>((((T7*)C))->_count/*4*/)) {
R=((((T7*)C))->_count/*4*/)+(1);
}
else {
_stop=0;
while (!(_stop)) {
/*IF*/if ((_i3)==(0)) {
_stop=1;
R=_i1;
}
 else if ((/*(IRF4.6item*/((((T7*)((T7*)a1)))->_storage/*0*/)[(_i3)-(1)]/*)*/)!=(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_i2)-(1)]/*)*/)) {
_stop=1;
}
/*FI*/_i3=(_i3)-(1);
_i2=(_i2)-(1);
}
}
/*FI*/_i1=(_i1)+(1);
_i3=(((T7*)((T7*)a1)))->_count/*4*/;
_i2=((_i1)+(_i3))-(1);
}
return R;
}
void r7make(T7* C,int a1){
/*IF*/if ((a1)>(0)) {
/*IF*/if (((((T7*)C))->_capacity/*8*/)<(a1)) {
C->_storage=calloc(a1,sizeof(char));
C->_capacity=a1;
}
/*FI*/}
/*FI*/C->_count=0;
}
void* r7to_external(T7* C){
void* R=0;
/*IF*/if (((((T7*)C))->_capacity/*8*/)>((((T7*)C))->_count/*4*/)) {
C->_count=((((T7*)C))->_count/*4*/)+(1);
/*IF*/if ((/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[((((T7*)C))->_count/*4*/)-(1)]/*)*/)!=('\0')) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[((((T7*)C))->_count/*4*/)-(1)]=('\0');
/*]*/
}
/*FI*/}
else {
r7extend(C,'\0');
}
/*FI*/C->_count=((((T7*)C))->_count/*4*/)-(1);
R=((void*)(((T7*)C))->_storage/*0*/);
return R;
}
/*No:STRING.item*/
int r7has_string(T7* C,T0* a1){
int R=0;
R=(r7index_of_string(C,a1))!=(((((T7*)C))->_count/*4*/)+(1));
return R;
}
/*No:STRING.clear*/
/*No:STRING.storage*/
T0* r7twin(T7* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T7*)R)=M7;
r7copy(((T7*)R),((T0*)C));
return R;
}
int r7is_equal(T7* C,T0* a1){
int R=0;
/*IF*/if ((C)==((void*)(a1))) {
R=1;
}
 else if (((((T7*)C))->_count/*4*/)==((((T7*)((T7*)a1)))->_count/*4*/)) {
/*IF*/if (((((T7*)C))->_count/*4*/)>(0)) {
R=r9fast_memcmp((((T7*)C))->_storage/*0*/,(((T7*)((T7*)a1)))->_storage/*0*/,(((T7*)C))->_count/*4*/);
}
else {
R=1;
}
/*FI*/}
/*FI*/return R;
}
void r7swap(T7* C,int a1,int a2){
char _tmp=0;
_tmp=/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(a1)-(1)]/*)*/;
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(a1)-(1)]=(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(a2)-(1)]/*)*/);
/*]*/
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(a2)-(1)]=(_tmp);
/*]*/
}
void r7blank(T7* C,int a1){
r7make(C,a1);
C->_count=a1;
/*[IRF3.6fill_with*/{T7* C1=C;
char b1='\40';
r9set_all_with((((T7*)C1))->_storage/*0*/,b1,((((T7*)C1))->_count/*4*/)-(1));
}/*]*/
}
char r7last(T7* C){
char R=0;
R=/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[((((T7*)C))->_count/*4*/)-(1)]/*)*/;
return R;
}
/*No:STRING.capacity*/
int r7has_suffix(T7* C,T0* a1){
int R=0;
int _i2=0;
int _i1=0;
/*IF*/if (((((T7*)((T7*)a1)))->_count/*4*/)<=((((T7*)C))->_count/*4*/)) {
_i1=(((((T7*)C))->_count/*4*/)-((((T7*)((T7*)a1)))->_count/*4*/))+(1);
_i2=1;
while (!((((_i1)>((((T7*)C))->_count/*4*/))||((_i2)>((((T7*)((T7*)a1)))->_count/*4*/)))||((/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_i1)-(1)]/*)*/)!=(/*(IRF4.6item*/((((T7*)((T7*)a1)))->_storage/*0*/)[(_i2)-(1)]/*)*/)))) {
_i1=(_i1)+(1);
_i2=(_i2)+(1);
}
R=(_i1)>((((T7*)C))->_count/*4*/);
}
/*FI*/return R;
}
int r7has(T7* C,char a1){
int R=0;
R=(r7index_of(C,a1))!=(((((T7*)C))->_count/*4*/)+(1));
return R;
}
void r7copy(T7* C,T0* a1){
C->_count=(((T7*)((T7*)a1)))->_count/*4*/;
/*IF*/if (((((T7*)C))->_count/*4*/)>(0)) {
/*IF*/if (((((T7*)C))->_capacity/*8*/)<((((T7*)C))->_count/*4*/)) {
C->_storage=calloc((((T7*)C))->_count/*4*/,sizeof(char));
C->_capacity=(((T7*)C))->_count/*4*/;
}
/*FI*/r9copy_from((((T7*)C))->_storage/*0*/,(((T7*)((T7*)a1)))->_storage/*0*/,((((T7*)C))->_count/*4*/)-(1));
}
/*FI*/}
int r7same_as(T7* C,T0* a1){
int R=0;
int _i=0;
/*IF*/if ((a1)==((void*)(C))) {
R=1;
}
else {
/*IF*/if (((((T7*)((T7*)a1)))->_count/*4*/)!=((((T7*)C))->_count/*4*/)) {
}
else {
_i=(((T7*)C))->_count/*4*/;
while (!(((_i)==(0))||(!(r3same_as(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]/*)*/,/*(IRF4.6item*/((((T7*)((T7*)a1)))->_storage/*0*/)[(_i)-(1)]/*)*/))))) {
_i=(_i)-(1);
}
R=(_i)==(0);
}
/*FI*/}
/*FI*/return R;
}
/*No:STRING.put*/
void r7prepend(T7* C,T0* a1){
int _old_count=0;
int _i=0;
_old_count=(((T7*)C))->_count/*4*/;
_i=(((T7*)((T7*)a1)))->_count/*4*/;
while (!((_i)==(0))) {
r7extend(C,'\40');
_i=(_i)-(1);
}
_i=(((T7*)C))->_count/*4*/;
while (!((_old_count)==(0))) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]=(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_old_count)-(1)]/*)*/);
/*]*/
_i=(_i)-(1);
_old_count=(_old_count)-(1);
}
_i=(((T7*)((T7*)a1)))->_count/*4*/;
while (!((_i)==(0))) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]=(/*(IRF4.6item*/((((T7*)((T7*)a1)))->_storage/*0*/)[(_i)-(1)]/*)*/);
/*]*/
_i=(_i)-(1);
}
}
/*No:STRING.fill_with*/
/*No:STRING.count*/
void r7to_upper(T7* C){
int _i=0;
_i=(((T7*)C))->_count/*4*/;
while (!((_i)==(0))) {
/*[IRF3.5put*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]=(r3to_upper(/*(IRF4.6item*/((((T7*)C))->_storage/*0*/)[(_i)-(1)]/*)*/));
/*]*/
_i=(_i)-(1);
}
}
void r7remove_last(T7* C,int a1){
C->_count=((((T7*)C))->_count/*4*/)-(a1);
}
/*No:STRING.first*/
int r7index_of(T7* C,char a1){
int R=0;
R=(1)+(r9fast_index_of((((T7*)C))->_storage/*0*/,a1,((((T7*)C))->_count/*4*/)-(1)));
return R;
}
void r7append(T7* C,T0* a1){
int _i=0;
_i=1;
while (!((_i)>((((T7*)((T7*)a1)))->_count/*4*/))) {
r7extend(C,/*(IRF4.6item*/((((T7*)((T7*)a1)))->_storage/*0*/)[(_i)-(1)]/*)*/);
_i=(_i)+(1);
}
}
/*No:ARRAY[INTEGER_CONSTANT].clear_all*/
/*No:ARRAY[INTEGER_CONSTANT].set_all_with*/
void r28make(T28* C,int a1,int a2){
int _needed=0;
C->_lower=a1;
C->_upper=a2;
_needed=((a2)-(a1))+(1);
/*IF*/if ((_needed)>(0)) {
/*IF*/if (((((T28*)C))->_capacity/*8*/)<(_needed)) {
/*IF*/if (((((T28*)C))->_capacity/*8*/)==(0)) {
C->_storage=calloc(_needed,sizeof(T0*));
}
else {
C->_storage=calloc(_needed,sizeof(T0*));
}
/*FI*/C->_capacity=_needed;
}
else {
/*[IRF3.6clear_all*/{T28* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T28* C2=C1;
T0* c1=__value;
r392set_all_with((((T28*)C2))->_storage/*4*/,c1,((((T28*)C2))->_upper/*12*/)-((((T28*)C2))->_lower/*16*/));
}/*]*/
}/*]*/
}
/*FI*/}
/*FI*/}
T0* r28item(T28* C,int a1){
T0* R=NULL;
R=((((T28*)C))->_storage/*4*/)[(a1)-((((T28*)C))->_lower/*16*/)];
return R;
}
/*No:ARRAY[INTEGER_CONSTANT].storage*/
T0* r28twin(T28* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T28*)R)=M28;
r28copy(((T28*)R),((T0*)C));
return R;
}
/*No:ARRAY[INTEGER_CONSTANT].capacity*/
void r28copy(T28* C,T0* a1){
int _needed_capacity=0;
C->_lower=(((T28*)((T28*)a1)))->_lower/*16*/;
C->_upper=(((T28*)((T28*)a1)))->_upper/*12*/;
_needed_capacity=(((((T28*)C))->_upper/*12*/)-((((T28*)C))->_lower/*16*/))+(1);
/*IF*/if (((((T28*)C))->_capacity/*8*/)<(_needed_capacity)) {
C->_capacity=_needed_capacity;
C->_storage=calloc((((T28*)C))->_capacity/*8*/,sizeof(T0*));
}
/*FI*//*IF*/if ((_needed_capacity)>(0)) {
r392copy_from((((T28*)C))->_storage/*4*/,(((T28*)((T28*)a1)))->_storage/*4*/,(_needed_capacity)-(1));
}
/*FI*/}
/*No:ARRAY[INTEGER_CONSTANT].lower*/
/*No:ARRAY[INTEGER_CONSTANT].put*/
/*No:ARRAY[INTEGER_CONSTANT].upper*/
int r28count(T28* C){
int R=0;
R=(((((T28*)C))->_upper/*12*/)-((((T28*)C))->_lower/*16*/))+(1);
return R;
}
void r28add_last(T28* C,T0* a1){
int _new_capacity=0;
/*IF*/if (((((T28*)C))->_capacity/*8*/)<((r28count(C))+(1))) {
/*IF*/if (((((T28*)C))->_capacity/*8*/)==(0)) {
C->_capacity=16;
C->_storage=calloc((((T28*)C))->_capacity/*8*/,sizeof(T0*));
}
else {
_new_capacity=(2)*((((T28*)C))->_capacity/*8*/);
C->_storage=r392realloc((((T28*)C))->_storage/*4*/,(((T28*)C))->_capacity/*8*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI*/}
/*FI*/C->_upper=((((T28*)C))->_upper/*12*/)+(1);
/*[IRF3.6put*/{T28* C1=C;
T0* b1=a1;
int b2=(((T28*)C))->_upper/*12*/;
((((T28*)C1))->_storage/*4*/)[(b2)-((((T28*)C1))->_lower/*16*/)]=(b1);
}/*]*/
}
T0* r28first(T28* C){
T0* R=NULL;
R=r28item(C,(((T28*)C))->_lower/*16*/);
return R;
}
T0* r235item(T235* C,int a1){
T0* R=NULL;
R=((((T235*)C))->_storage/*0*/)[(a1)-((((T235*)C))->_lower/*12*/)];
return R;
}
/*No:ARRAY[CREATION_CLAUSE].storage*/
/*No:ARRAY[CREATION_CLAUSE].capacity*/
/*No:ARRAY[CREATION_CLAUSE].lower*/
/*No:ARRAY[CREATION_CLAUSE].put*/
/*No:ARRAY[CREATION_CLAUSE].upper*/
int r235count(T235* C){
int R=0;
R=(((((T235*)C))->_upper/*8*/)-((((T235*)C))->_lower/*12*/))+(1);
return R;
}
void r235add_last(T235* C,T0* a1){
int _new_capacity=0;
/*IF*/if (((((T235*)C))->_capacity/*4*/)<((r235count(C))+(1))) {
/*IF*/if (((((T235*)C))->_capacity/*4*/)==(0)) {
C->_capacity=16;
C->_storage=calloc((((T235*)C))->_capacity/*4*/,sizeof(T0*));
}
else {
_new_capacity=(2)*((((T235*)C))->_capacity/*4*/);
C->_storage=r513realloc((((T235*)C))->_storage/*0*/,(((T235*)C))->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI*/}
/*FI*/C->_upper=((((T235*)C))->_upper/*8*/)+(1);
/*[IRF3.6put*/{T235* C1=C;
T0* b1=a1;
int b2=(((T235*)C))->_upper/*8*/;
((((T235*)C1))->_storage/*0*/)[(b2)-((((T235*)C1))->_lower/*12*/)]=(b1);
}/*]*/
}
T0* r235first(T235* C){
T0* R=NULL;
R=r235item(C,(((T235*)C))->_lower/*12*/);
return R;
}
T0* r147item(T147* C,int a1){
T0* R=NULL;
R=((((T147*)C))->_storage/*0*/)[(a1)-((((T147*)C))->_lower/*12*/)];
return R;
}
/*No:ARRAY[E_WHEN].storage*/
T0* r147twin(T147* C){
T0* R=NULL;
R=malloc(sizeof(*C));
*((T147*)R)=M147;
r147copy(((T147*)R),((T0*)C));
return R;
}
/*No:ARRAY[E_WHEN].capacity*/
void r147copy(T147* C,T0* a1){
int _needed_capacity=0;
C->_lower=(((T147*)((T147*)a1)))->_lower/*12*/;
C->_upper=(((T147*)((T147*)a1)))->_upper/*8*/;
_needed_capacity=(((((T147*)C))->_upper/*8*/)-((((T147*)C))->_lower/*12*/))+(1);
/*IF*/if (((((T147*)C))->_capacity/*4*/)<(_needed_capacity)) {
C->_capacity=_needed_capacity;
C->_storage=calloc((((T147*)C))->_capacity/*4*/,sizeof(T0*));
}
/*FI*//*IF*/if ((_needed_capacity)>(0)) {
r586copy_from((((T147*)C))->_storage/*0*/,(((T147*)((T147*)a1)))->_storage/*0*/,(_needed_capacity)-(1));
}
/*FI*/}
/*No:ARRAY[E_WHEN].lower*/
/*No:ARRAY[E_WHEN].put*/
/*No:ARRAY[E_WHEN].upper*/
int r147count(T147* C){
int R=0;
R=(((((T147*)C))->_upper/*8*/)-((((T147*)C))->_lower/*12*/))+(1);
return R;
}
void r147add_last(T147* C,T0* a1){
int _new_capacity=0;
/*IF*/if (((((T147*)C))->_capacity/*4*/)<((r147count(C))+(1))) {
/*IF*/if (((((T147*)C))->_capacity/*4*/)==(0)) {
C->_capacity=16;
C->_storage=calloc((((T147*)C))->_capacity/*4*/,sizeof(T0*));
}
else {
_new_capacity=(2)*((((T147*)C))->_capacity/*4*/);
C->_storage=r586realloc((((T147*)C))->_storage/*0*/,(((T147*)C))->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
}
/*FI*/}
/*FI*/C->_upper=((((T147*)C))->_upper/*8*/)+(1);
/*[IRF3.6put*/{T147* C1=C;
T0* b1=a1;
int b2=(((T147*)C))->_upper/*8*/;
((((T147*)C1))->_storage/*0*/)[(b2)-((((T147*)C1))->_lower/*12*/)]=(b1);
}/*]*/
}
/*No:ARRAY[RUN_FEATURE].clear_all*/
/*No:ARRAY[RUN_FEATURE].set_all_with*/
void r477force(T477* C,T0* a1,int a2){
/*IF*/if (((((T477*)C))->_upper/*8*/)<(a2)) {
r477resize(C,(((T477*)C))->_lower/*12*/,a2);
}
 else if ((a2)<((((T477*)C))->_lower/*12*/)) {
r477resize(C,a2,(((T477*)C))->_upper/*8*/);
}
/*FI*//*[IRF3.6put*/{T477* C1=C;
T0* b1=a1;
int b2=a2;
((((T477*)C1))->_storage/*0*/)[(b2)-((((T477*)C1))->_lower/*12*/)]=(b1);
}/*]*/
}
void r477make(T477* C,int a1,int a2){
int _needed=0;
C->_lower=a1;
C->_upper=a2;
_needed=((a2)-(a1))+(1);
/*IF*/if ((_needed)>(0)) {
/*IF*/if (((((T477*)C))->_capacity/*4*/)<(_needed)) {
/*IF*/if (((((T477*)C))->_capacity/*4*/)==(0)) {
C->_storage=calloc(_needed,sizeof(T0*));
}
else {
C->_storage=calloc(_needed,sizeof(T0*));
}
/*FI*/C->_capacity=_needed;
}
else {
/*[IRF3.6clear_all*/{T477* C1=C;
T0* __value=NULL;
/*[IRF3.6set_all_with*/{T477* C2=C1;
T0* c1=__value;
r778set_all_with((((T477*)C2))->_storage/*0*/,c1,((((T477*)C2))->_upper/*8*/)-((((T477*)C2))->_lower/*12*/));
}/*]*/
}/*]*/
}
/*FI*/}
/*FI*/}
T0* r477item(T477* C,int a1){
T0* R=NULL;
R=((((T477*)C))->_storage/*0*/)[(a1)-((((T477*)C))->_lower/*12*/)];
return R;
}
void r477resize(T477* C,int a1,int a2){
int _mem=0;
int _up=0;
int _i=0;
T0* _other=NULL;
{T477*n=malloc(sizeof(*n));
*n=M477;
r477make(n,a1,a2);
_other=(T0*)n;
}
_i=r2max((((T477*)C))->_lower/*12*/,(((T477*)((T477*)_other)))->_lower/*12*/);
_up=r2min((((T477*)C))->_upper/*8*/,(((T477*)((T477*)_other)))->_upper/*8*/);
while (!((_i)>(_up))) {
/*[IRF3.6put*/{T477* C1=((T477*)_other);
T0* b1=r477item(C,_i);
int b2=_i;
((((T477*)C1))->_storage/*0*/)[(b2)-((((T477*)C1))->_lower/*12*/)]=(b1);
}/*]*/
_i=(_i)+(1);
}
*((T477*)(C))=*((T477*)(_other));
}
/*No:ARRAY[RUN_FEATURE].storage*/
/*No:ARRAY[RUN_FEATURE].capacity*/
/*No:ARRAY[RUN_FEATURE].lower*/
/*No:ARRAY[RUN_FEATURE].put*/
/*No:ARRAY[RUN_FEATURE].upper*/
int r477count(T477* C){
int R=0;
R=(((((T477*)C))->_upper/*8*/)-((((T477*)C))->_lower/*12*/))+(1);
return R;
}
/*No:FIXED_ARRAY[TYPE_BIT_REF].storage*/
/*No:FIXED_ARRAY[TYPE_BIT_REF].capacity*/
void r41with_capacity(T41* C,int a1){
/*IF*/if (((((T41*)C))->_capacity/*4*/)<(a1)) {
C->_storage=calloc(a1,sizeof(T0*));
C->_capacity=a1;
}
/*FI*/C->_upper=-(1);
}
/*No:FIXED_ARRAY[TYPE_BIT_REF].put*/
/*No:FIXED_ARRAY[TYPE_BIT_REF].upper*/
void r41add_last(T41* C,T0* a1){
int _new_capacity=0;
/*IF*/if ((((((T41*)C))->_upper/*8*/)+(1))<=(((((T41*)C))->_capacity/*4*/)-(1))) {
C->_upper=((((T41*)C))->_upper/*8*/)+(1);
}
 else if (((((T41*)C))->_capacity/*4*/)==(0)) {
C->_storage=calloc(2,sizeof(T0*));
C->_capacity=2;
C->_upper=0;
}
else {
_new_capacity=(2)*((((T41*)C))->_capacity/*4*/);
C->_storage=r539realloc((((T41*)C))->_storage/*0*/,(((T41*)C))->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((((T41*)C))->_upper/*8*/)+(1);
}
/*FI*//*[IRF3.5put*/((((T41*)C))->_storage/*0*/)[(((T41*)C))->_upper/*8*/]=(a1);
/*]*/
}
/*No:FIXED_ARRAY[INTEGER].clear_all*/
/*No:FIXED_ARRAY[INTEGER].set_all_with*/
void r226make(T226* C,int a1){
/*IF*/if ((a1)==(0)) {
C->_upper=-(1);
}
 else if (((((T226*)C))->_capacity/*4*/)==(0)) {
C->_storage=calloc(a1,sizeof(int));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
 else if (((((T226*)C))->_capacity/*4*/)<(a1)) {
C->_storage=calloc(a1,sizeof(int));
C->_capacity=a1;
C->_upper=(a1)-(1);
}
else {
C->_upper=(a1)-(1);
/*[IRF3.6clear_all*/{T226* C1=C;
int __value=0;
/*[IRF3.6set_all_with*/{T226* C2=C1;
int c1=__value;
r686set_all_with((((T226*)C2))->_storage/*0*/,c1,(((T226*)C2))->_upper/*8*/);
}/*]*/
}/*]*/
}
/*FI*/}
int r226fast_has(T226* C,int a1){
int R=0;
/*IF*/if ((/*(IRF4.6count*/((((T226*)C))->_upper/*8*/)+(1)/*)*/)>(0)) {
R=(r226fast_index_of(C,a1))<=((((T226*)C))->_upper/*8*/);
}
/*FI*/return R;
}
/*No:FIXED_ARRAY[INTEGER].item*/
/*No:FIXED_ARRAY[INTEGER].storage*/
/*No:FIXED_ARRAY[INTEGER].capacity*/
void r226copy(T226* C,T0* a1){
int _new_capacity=0;
int _other_upper=0;
_other_upper=(((T226*)((T226*)a1)))->_upper/*8*/;
/*IF*/if ((_other_upper)>=(0)) {
_new_capacity=(_other_upper)+(1);
/*IF*/if (((((T226*)C))->_capacity/*4*/)<(_new_capacity)) {
C->_capacity=_new_capacity;
C->_storage=calloc(_new_capacity,sizeof(int));
}
 else if (((((T226*)C))->_capacity/*4*/)>(0)) {
r686clear_all((((T226*)C))->_storage/*0*/,((((T226*)C))->_capacity/*4*/)-(1));
}
/*FI*/r686copy_from((((T226*)C))->_storage/*0*/,(((T226*)((T226*)a1)))->_storage/*0*/,_other_upper);
}
 else if (((((T226*)C))->_capacity/*4*/)>(0)) {
r686clear_all((((T226*)C))->_storage/*0*/,((((T226*)C))->_capacity/*4*/)-(1));
}
/*FI*/C->_upper=_other_upper;
}
void r226with_capacity(T226* C,int a1){
/*IF*/if (((((T226*)C))->_capacity/*4*/)<(a1)) {
C->_storage=calloc(a1,sizeof(int));
C->_capacity=a1;
}
/*FI*/C->_upper=-(1);
}
int r226fast_index_of(T226* C,int a1){
int R=0;
R=r686fast_index_of((((T226*)C))->_storage/*0*/,a1,(((T226*)C))->_upper/*8*/);
return R;
}
/*No:FIXED_ARRAY[INTEGER].put*/
/*No:FIXED_ARRAY[INTEGER].upper*/
/*No:FIXED_ARRAY[INTEGER].count*/
void r226add_last(T226* C,int a1){
int _new_capacity=0;
/*IF*/if ((((((T226*)C))->_upper/*8*/)+(1))<=(((((T226*)C))->_capacity/*4*/)-(1))) {
C->_upper=((((T226*)C))->_upper/*8*/)+(1);
}
 else if (((((T226*)C))->_capacity/*4*/)==(0)) {
C->_storage=calloc(2,sizeof(int));
C->_capacity=2;
C->_upper=0;
}
else {
_new_capacity=(2)*((((T226*)C))->_capacity/*4*/);
C->_storage=r686realloc((((T226*)C))->_storage/*0*/,(((T226*)C))->_capacity/*4*/,_new_capacity);
C->_capacity=_new_capacity;
C->_upper=((((T226*)C))->_upper/*8*/)+(1);
}
/*FI*//*[IRF3.5put*/((((T226*)C))->_storage/*0*/)[(((T226*)C))->_upper/*8*/]=(a1);
/*]*/
}

