/* This C file is generated by NIT to compile module partial_order. */
#include "partial_order._sep.h"
-val_t partial_order___PartialOrder___iterator(val_t p0){
+val_t partial_order___PartialOrder___roots(val_t p0){
struct {struct stack_frame_t me;} fra;
val_t REGB0;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
- fra.me.line = 54;
- fra.me.meth = LOCATE_partial_order___PartialOrder___iterator;
+ fra.me.line = 30;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___roots;
fra.me.has_broke = 0;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0])!=NIT_NULL);
- /* ./metamodel//partial_order.nit:54 */
+ /* ./metamodel//partial_order.nit:30 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____roots(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements_list");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 54);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_roots", LOCATE_partial_order, 30);
}
- fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]);
- fra.me.REG[0] = CALL_abstract_collection___Collection___iterator(fra.me.REG[0])(fra.me.REG[0]);
- goto label1;
- label1: while(0);
+ fra.me.REG[0] = ATTR_partial_order___PartialOrder____roots(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
return fra.me.REG[0];
}
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:35 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 35);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 35);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
REGB0 = CALL_abstract_collection___Collection___is_empty(fra.me.REG[0])(fra.me.REG[0]);
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:37 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 37);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 37);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
REGB0 = CALL_abstract_collection___Collection___length(fra.me.REG[0])(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
return REGB0;
}
+val_t partial_order___PartialOrder___first(val_t p0){
+ struct {struct stack_frame_t me;} fra;
+ val_t REGB0;
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 39;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___first;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:39 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_elements_list", LOCATE_partial_order, 39);
+ }
+ fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]);
+ fra.me.REG[0] = CALL_abstract_collection___Collection___first(fra.me.REG[0])(fra.me.REG[0]);
+ goto label1;
+ label1: while(0);
+ stack_frame_head = fra.me.prev;
+ return fra.me.REG[0];
+}
val_t partial_order___PartialOrder___has(val_t p0, val_t p1){
struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
val_t REGB0;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:41 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 41);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 41);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
REGB0 = CALL_abstract_collection___MapRead___has_key(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:43 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 43);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 43);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
REGB0 = CALL_abstract_collection___Collection___length(fra.me.REG[2])(fra.me.REG[2]);
REGB2 = TAG_Bool(IS_EQUAL_OO(REGB0,REGB1));
if (UNTAG_Bool(REGB2)) {
} else {
+ /* ./../lib/standard//kernel.nit:207 */
REGB1 = TAG_Bool((REGB0)==(REGB1));
+ /* ./metamodel//partial_order.nit:43 */
REGB2 = REGB1;
- /* ./metamodel//partial_order.nit:43 */
}
if (UNTAG_Bool(REGB2)) {
REGB2 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB2)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 43);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 43);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
fra.me.REG[0] = CALL_abstract_collection___Collection___first(fra.me.REG[0])(fra.me.REG[0]);
- REGB2 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[0],fra.me.REG[1]));
+ REGB2 = TAG_Bool(IS_EQUAL_ON(fra.me.REG[1],fra.me.REG[0]));
if (UNTAG_Bool(REGB2)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
/* ./metamodel//partial_order.nit:47 */
+ REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
if (UNTAG_Bool(REGB0)) {
- REGB0 = TAG_Int(1);
/* ./metamodel//partial_order.nit:48 */
+ REGB0 = TAG_Int(1);
goto label1;
} else {
+ /* ./metamodel//partial_order.nit:50 */
REGB1 = TAG_Int(0);
REGB0 = REGB1;
- /* ./metamodel//partial_order.nit:50 */
goto label1;
}
label1: while(0);
stack_frame_head = fra.me.prev;
return REGB0;
}
-val_t partial_order___PartialOrder___first(val_t p0){
+val_t partial_order___PartialOrder___iterator(val_t p0){
struct {struct stack_frame_t me;} fra;
val_t REGB0;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
- fra.me.line = 39;
- fra.me.meth = LOCATE_partial_order___PartialOrder___first;
+ fra.me.line = 54;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___iterator;
fra.me.has_broke = 0;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:54 */
REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0])!=NIT_NULL);
- /* ./metamodel//partial_order.nit:39 */
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements_list");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 39);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements_list", LOCATE_partial_order, 54);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]);
- fra.me.REG[0] = CALL_abstract_collection___Collection___first(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[0] = CALL_abstract_collection___Collection___iterator(fra.me.REG[0])(fra.me.REG[0]);
goto label1;
label1: while(0);
stack_frame_head = fra.me.prev;
return fra.me.REG[0];
}
-val_t partial_order___PartialOrder___roots(val_t p0){
- struct {struct stack_frame_t me;} fra;
- val_t REGB0;
- val_t tmp;
- fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
- fra.me.file = LOCATE_partial_order;
- fra.me.line = 30;
- fra.me.meth = LOCATE_partial_order___PartialOrder___roots;
- fra.me.has_broke = 0;
- fra.me.REG_size = 1;
- fra.me.REG[0] = NIT_NULL;
- fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____roots(fra.me.REG[0])!=NIT_NULL);
- /* ./metamodel//partial_order.nit:30 */
- if (UNTAG_Bool(REGB0)) {
- } else {
- fprintf(stderr, "Uninitialized attribute %s", "_roots");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 30);
- nit_exit(1);
- }
- fra.me.REG[0] = ATTR_partial_order___PartialOrder____roots(fra.me.REG[0]);
- stack_frame_head = fra.me.prev;
- return fra.me.REG[0];
-}
val_t partial_order___PartialOrder_____bra(val_t p0, val_t p1){
struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
val_t REGB0;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:61 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 61);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 61);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
fra.me.REG[1] = CALL_abstract_collection___MapRead_____bra(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
return fra.me.REG[1];
}
val_t partial_order___PartialOrder___to_dot(val_t p0){
- struct {struct stack_frame_t me; val_t MORE_REG[6];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
val_t REGB0;
val_t tmp;
static val_t once_value_3; /* Once value */
fra.me.line = 64;
fra.me.meth = LOCATE_partial_order___PartialOrder___to_dot;
fra.me.has_broke = 0;
- fra.me.REG_size = 7;
+ fra.me.REG_size = 3;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
- fra.me.REG[3] = NIT_NULL;
- fra.me.REG[4] = NIT_NULL;
- fra.me.REG[5] = NIT_NULL;
- fra.me.REG[6] = NIT_NULL;
fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:67 */
fra.me.REG[1] = NEW_Buffer_string___Buffer___init();
- fra.me.REG[2] = CALL_partial_order___PartialOrder___to_dot_header(fra.me.REG[0])(fra.me.REG[0]);
/* ./metamodel//partial_order.nit:68 */
+ fra.me.REG[2] = CALL_partial_order___PartialOrder___to_dot_header(fra.me.REG[0])(fra.me.REG[0]);
CALL_abstract_collection___Sequence___append(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:69 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 69);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 69);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
- fra.me.REG[2] = CALL_abstract_collection___Collection___iterator(fra.me.REG[2])(fra.me.REG[2]);
- while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[2])(fra.me.REG[2]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[3] = CALL_abstract_collection___Iterator___item(fra.me.REG[2])(fra.me.REG[2]);
- fra.me.REG[4] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[3])(fra.me.REG[3]);
- fra.me.REG[4] = CALL_partial_order___PartialOrder___to_dot_node(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[4]);
- /* ./metamodel//partial_order.nit:70 */
- CALL_abstract_collection___Sequence___append(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[4]);
- fra.me.REG[4] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[3])(fra.me.REG[3]);
- fra.me.REG[4] = CALL_abstract_collection___Collection___iterator(fra.me.REG[4])(fra.me.REG[4]);
- /* ./metamodel//partial_order.nit:71 */
- while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[4])(fra.me.REG[4]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[5] = CALL_abstract_collection___Iterator___item(fra.me.REG[4])(fra.me.REG[4]);
- fra.me.REG[6] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[3])(fra.me.REG[3]);
- fra.me.REG[5] = CALL_partial_order___PartialOrder___to_dot_edge(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[6], fra.me.REG[5]);
- /* ./metamodel//partial_order.nit:72 */
- CALL_abstract_collection___Sequence___append(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[5]);
- } else {
- /* ./metamodel//partial_order.nit:71 */
- goto label1;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[4])(fra.me.REG[4]);
- }
- label1: while(0);
- } else {
- /* ./metamodel//partial_order.nit:69 */
- goto label2;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[2])(fra.me.REG[2]);
- }
- label2: while(0);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[2])(fra.me.REG[2], (&(fra.me)), ((fun_t)OC_partial_order___PartialOrder___to_dot_1));
/* ./metamodel//partial_order.nit:75 */
if (!once_value_3) {
- fra.me.REG[2] = BOX_NativeString("}\n");
+ fra.me.REG[0] = BOX_NativeString("}\n");
REGB0 = TAG_Int(2);
- fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
- once_value_3 = fra.me.REG[2];
+ fra.me.REG[0] = NEW_String_string___String___with_native(fra.me.REG[0], REGB0);
+ once_value_3 = fra.me.REG[0];
register_static_object(&once_value_3);
- } else fra.me.REG[2] = once_value_3;
- CALL_abstract_collection___Sequence___append(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
- fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
+ } else fra.me.REG[0] = once_value_3;
+ fra.me.REG[0] = fra.me.REG[0];
+ CALL_abstract_collection___Sequence___append(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[0]);
/* ./metamodel//partial_order.nit:76 */
+ fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
goto label4;
label4: while(0);
stack_frame_head = fra.me.prev;
return fra.me.REG[1];
}
+ void OC_partial_order___PartialOrder___to_dot_1(struct stack_frame_t *closctx, val_t p0, struct stack_frame_t *closctx_param, fun_t clos_fun0){
+ struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
+ val_t REGB0;
+ val_t REGB1;
+ fun_t CREG[1];
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___to_dot;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 5;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.REG[1] = NIT_NULL;
+ fra.me.REG[2] = NIT_NULL;
+ fra.me.REG[3] = NIT_NULL;
+ fra.me.REG[4] = NIT_NULL;
+ fra.me.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./metamodel//partial_order.nit:70 */
+ fra.me.REG[1] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_partial_order___PartialOrder___to_dot_node(closctx->REG[0])(closctx->REG[0], fra.me.REG[1]);
+ CALL_abstract_collection___Sequence___append(closctx->REG[1])(closctx->REG[1], fra.me.REG[1]);
+ /* ./metamodel//partial_order.nit:71 */
+ fra.me.REG[1] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[0])(fra.me.REG[0]);
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB0 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[1])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[1]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[2] = ATTR_array___Array____items(fra.me.REG[1]);
+ /* ./../lib/standard//collection//array.nit:237 */
+ while(1) {
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[1])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[1]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB1)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[3] = ((Nit_NativeArray)fra.me.REG[2])->val[UNTAG_Int(REGB0)];
+ /* ./metamodel//partial_order.nit:72 */
+ fra.me.REG[4] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[3] = CALL_partial_order___PartialOrder___to_dot_edge(closctx->REG[0])(closctx->REG[0], fra.me.REG[4], fra.me.REG[3]);
+ CALL_abstract_collection___Sequence___append(closctx->REG[1])(closctx->REG[1], fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB1 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB0 = REGB1;
+ } else {
+ /* ./../lib/standard//collection//array.nit:237 */
+ goto label2;
+ }
+ }
+ label2: while(0);
+ stack_frame_head = fra.me.prev;
+ return;
+ }
val_t partial_order___PartialOrder___to_dot_header(val_t p0){
struct {struct stack_frame_t me;} fra;
val_t REGB0;
once_value_1 = fra.me.REG[0];
register_static_object(&once_value_1);
} else fra.me.REG[0] = once_value_1;
+ fra.me.REG[0] = fra.me.REG[0];
goto label2;
label2: while(0);
stack_frame_head = fra.me.prev;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
+ /* ./metamodel//partial_order.nit:88 */
REGB0 = TAG_Int(3);
fra.me.REG[0] = NEW_Array_array___Array___with_capacity(REGB0);
- /* ./metamodel//partial_order.nit:88 */
if (!once_value_1) {
fra.me.REG[2] = BOX_NativeString("\"");
REGB0 = TAG_Int(1);
once_value_1 = fra.me.REG[2];
register_static_object(&once_value_1);
} else fra.me.REG[2] = once_value_1;
- array___Array___add(fra.me.REG[0], fra.me.REG[2]);
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
if (!once_value_2) {
fra.me.REG[1] = BOX_NativeString("\";\n");
REGB0 = TAG_Int(3);
once_value_2 = fra.me.REG[1];
register_static_object(&once_value_2);
} else fra.me.REG[1] = once_value_2;
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ fra.me.REG[1] = fra.me.REG[1];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
fra.me.REG[0] = CALL_string___Object___to_s(fra.me.REG[0])(fra.me.REG[0]);
goto label3;
label3: while(0);
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
+ /* ./metamodel//partial_order.nit:94 */
REGB0 = TAG_Int(5);
fra.me.REG[0] = NEW_Array_array___Array___with_capacity(REGB0);
- /* ./metamodel//partial_order.nit:94 */
if (!once_value_1) {
fra.me.REG[3] = BOX_NativeString("\"");
REGB0 = TAG_Int(1);
once_value_1 = fra.me.REG[3];
register_static_object(&once_value_1);
} else fra.me.REG[3] = once_value_1;
- array___Array___add(fra.me.REG[0], fra.me.REG[3]);
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[3]);
fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
if (!once_value_2) {
fra.me.REG[1] = BOX_NativeString("\" -> \"");
REGB0 = TAG_Int(6);
once_value_2 = fra.me.REG[1];
register_static_object(&once_value_2);
} else fra.me.REG[1] = once_value_2;
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ fra.me.REG[1] = fra.me.REG[1];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
fra.me.REG[2] = CALL_string___Object___to_s(fra.me.REG[2])(fra.me.REG[2]);
- array___Array___add(fra.me.REG[0], fra.me.REG[2]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
if (!once_value_3) {
fra.me.REG[2] = BOX_NativeString("\";\n");
REGB0 = TAG_Int(3);
once_value_3 = fra.me.REG[2];
register_static_object(&once_value_3);
} else fra.me.REG[2] = once_value_3;
- array___Array___add(fra.me.REG[0], fra.me.REG[2]);
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
fra.me.REG[0] = CALL_string___Object___to_s(fra.me.REG[0])(fra.me.REG[0]);
goto label4;
label4: while(0);
return fra.me.REG[0];
}
val_t partial_order___PartialOrder___select_smallests(val_t p0, val_t p1){
- struct {struct stack_frame_t me; val_t MORE_REG[5];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
val_t REGB0;
val_t REGB1;
val_t tmp;
fra.me.line = 97;
fra.me.meth = LOCATE_partial_order___PartialOrder___select_smallests;
fra.me.has_broke = 0;
- fra.me.REG_size = 6;
+ fra.me.REG_size = 5;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[3] = NIT_NULL;
fra.me.REG[4] = NIT_NULL;
- fra.me.REG[5] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
/* ./metamodel//partial_order.nit:100 */
+ REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
fra.me.REG[2] = NEW_Array_array___Array___init();
goto label1;
}
- REGB0 = CALL_partial_order___PartialOrder___has_all(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
/* ./metamodel//partial_order.nit:101 */
+ REGB0 = CALL_partial_order___PartialOrder___has_all(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Assert failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 101);
- nit_exit(1);
+ nit_abort("Assert failed", NULL, LOCATE_partial_order, 101);
}
- REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
/* ./metamodel//partial_order.nit:102 */
+ REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
if (UNTAG_Bool(REGB0)) {
- fprintf(stderr, "Reciever is null");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 102);
- nit_exit(1);
+ nit_abort("Reciever is null", NULL, LOCATE_partial_order, 102);
}
REGB0 = CALL_abstract_collection___Collection___length(fra.me.REG[1])(fra.me.REG[1]);
fra.me.REG[3] = NEW_Array_array___Array___with_capacity(REGB0);
- REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
/* ./metamodel//partial_order.nit:103 */
+ REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
if (UNTAG_Bool(REGB0)) {
- fprintf(stderr, "Reciever is null");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 103);
- nit_exit(1);
+ nit_abort("Reciever is null", NULL, LOCATE_partial_order, 103);
}
REGB0 = CALL_abstract_collection___Collection___length(fra.me.REG[1])(fra.me.REG[1]);
fra.me.REG[4] = NEW_Array_array___Array___with_capacity(REGB0);
- fra.me.REG[1] = CALL_abstract_collection___Collection___iterator(fra.me.REG[1])(fra.me.REG[1]);
/* ./metamodel//partial_order.nit:104 */
- while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[1])(fra.me.REG[1]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[5] = CALL_abstract_collection___Iterator___item(fra.me.REG[1])(fra.me.REG[1]);
- REGB0 = CALL_partial_order___PartialOrder___add_to_smallests(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[5], fra.me.REG[3], fra.me.REG[4]);
- /* ./metamodel//partial_order.nit:107 */
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[5] = fra.me.REG[4];
- fra.me.REG[4] = fra.me.REG[3];
- fra.me.REG[3] = fra.me.REG[5];
- /* ./metamodel//partial_order.nit:112 */
- }
- } else {
- /* ./metamodel//partial_order.nit:104 */
- goto label2;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[1])(fra.me.REG[1]);
+ REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ nit_abort("Reciever is null", NULL, LOCATE_partial_order, 104);
}
- label2: while(0);
- fra.me.REG[2] = fra.me.REG[3];
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[1])(fra.me.REG[1], (&(fra.me)), ((fun_t)OC_partial_order___PartialOrder___select_smallests_2));
/* ./metamodel//partial_order.nit:115 */
+ fra.me.REG[2] = fra.me.REG[3];
goto label1;
label1: while(0);
stack_frame_head = fra.me.prev;
return fra.me.REG[2];
}
+ void OC_partial_order___PartialOrder___select_smallests_2(struct stack_frame_t *closctx, val_t p0, struct stack_frame_t *closctx_param, fun_t clos_fun0){
+ struct {struct stack_frame_t me;} fra;
+ val_t REGB0;
+ fun_t CREG[1];
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___select_smallests;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./metamodel//partial_order.nit:106 */
+ REGB0 = CALL_partial_order___PartialOrder___add_to_smallests(closctx->REG[0])(closctx->REG[0], fra.me.REG[0], closctx->REG[3], closctx->REG[4]);
+ /* ./metamodel//partial_order.nit:107 */
+ if (UNTAG_Bool(REGB0)) {
+ /* ./metamodel//partial_order.nit:110 */
+ fra.me.REG[0] = closctx->REG[4];
+ /* ./metamodel//partial_order.nit:111 */
+ closctx->REG[4] = closctx->REG[3];
+ /* ./metamodel//partial_order.nit:112 */
+ closctx->REG[3] = fra.me.REG[0];
+ }
+ stack_frame_head = fra.me.prev;
+ return;
+ }
val_t partial_order___PartialOrder___add(val_t p0, val_t p1, val_t p2){
struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
val_t REGB0;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
+ /* ./metamodel//partial_order.nit:121 */
REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
- /* ./metamodel//partial_order.nit:121 */
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Assert failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 121);
- nit_exit(1);
+ nit_abort("Assert failed", NULL, LOCATE_partial_order, 121);
}
- REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
/* ./metamodel//partial_order.nit:122 */
+ REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
}
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Assert failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 122);
- nit_exit(1);
+ nit_abort("Assert failed", NULL, LOCATE_partial_order, 122);
}
+ /* ./metamodel//partial_order.nit:123 */
fra.me.REG[3] = CALL_partial_order___PartialOrder___select_smallests(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
+ /* ./metamodel//partial_order.nit:124 */
fra.me.REG[3] = CALL_partial_order___PartialOrder___new_poe(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1], fra.me.REG[3]);
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:125 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 125);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 125);
}
fra.me.REG[4] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
CALL_abstract_collection___Map_____braeq(fra.me.REG[4])(fra.me.REG[4], fra.me.REG[1], fra.me.REG[3]);
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:126 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements_list");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 126);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements_list", LOCATE_partial_order, 126);
}
fra.me.REG[4] = ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]);
- array___Array___add(fra.me.REG[4], fra.me.REG[1]);
- REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[4])(fra.me.REG[4], fra.me.REG[1]);
/* ./metamodel//partial_order.nit:127 */
+ REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
} else {
REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
if (UNTAG_Bool(REGB1)) {
- fprintf(stderr, "Reciever is null");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 127);
- nit_exit(1);
+ nit_abort("Reciever is null", NULL, LOCATE_partial_order, 127);
}
REGB1 = CALL_abstract_collection___Collection___is_empty(fra.me.REG[2])(fra.me.REG[2]);
REGB0 = REGB1;
}
if (UNTAG_Bool(REGB0)) {
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____roots(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:128 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____roots(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_roots");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 128);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_roots", LOCATE_partial_order, 128);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____roots(fra.me.REG[0]);
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
}
/* ./metamodel//partial_order.nit:130 */
goto label1;
return fra.me.REG[3];
}
val_t partial_order___PartialOrder___has_all(val_t p0, val_t p1){
- struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
val_t REGB0;
- val_t REGB1;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
fra.me.line = 133;
fra.me.meth = LOCATE_partial_order___PartialOrder___has_all;
fra.me.has_broke = 0;
- fra.me.REG_size = 3;
+ fra.me.REG_size = 2;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
- fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- fra.me.REG[1] = CALL_abstract_collection___Collection___iterator(fra.me.REG[1])(fra.me.REG[1]);
- /* ./metamodel//partial_order.nit:136 */
- while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[1])(fra.me.REG[1]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[2] = CALL_abstract_collection___Iterator___item(fra.me.REG[1])(fra.me.REG[1]);
- REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
- REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
- /* ./metamodel//partial_order.nit:137 */
- if (UNTAG_Bool(REGB0)) {
- REGB0 = TAG_Bool(false);
- /* ./metamodel//partial_order.nit:138 */
- goto label1;
- }
- } else {
- /* ./metamodel//partial_order.nit:136 */
- goto label2;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[1])(fra.me.REG[1]);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[1])(fra.me.REG[1], (&(fra.me)), ((fun_t)OC_partial_order___PartialOrder___has_all_1));
+ switch ((&(fra.me))->has_broke) {
+ case 0: break;
+ case 1: (&(fra.me))->has_broke = 0; goto label3;
}
- label2: while(0);
- REGB1 = TAG_Bool(true);
- REGB0 = REGB1;
/* ./metamodel//partial_order.nit:141 */
- goto label1;
- label1: while(0);
+ REGB0 = TAG_Bool(true);
+ fra.me.REG[1] = REGB0;
+ goto label3;
+ label3: while(0);
stack_frame_head = fra.me.prev;
- return REGB0;
+ return fra.me.REG[1];
}
+ void OC_partial_order___PartialOrder___has_all_1(struct stack_frame_t *closctx, val_t p0, struct stack_frame_t *closctx_param, fun_t clos_fun0){
+ struct {struct stack_frame_t me;} fra;
+ val_t REGB0;
+ fun_t CREG[1];
+ val_t tmp;
+ /* ./metamodel//partial_order.nit:136 */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___has_all;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./metamodel//partial_order.nit:137 */
+ REGB0 = CALL_abstract_collection___Collection___has(closctx->REG[0])(closctx->REG[0], fra.me.REG[0]);
+ REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
+ if (UNTAG_Bool(REGB0)) {
+ /* ./metamodel//partial_order.nit:138 */
+ REGB0 = TAG_Bool(false);
+ closctx->REG[1] = REGB0;
+ closctx->has_broke = 1;
+ goto label2;
+ }
+ label2: while(0);
+ stack_frame_head = fra.me.prev;
+ return;
+ }
val_t partial_order___PartialOrder___new_poe(val_t p0, val_t p1, val_t p2){
struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
val_t tmp;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
- fra.me.REG[2] = NEW_PartialOrderElement_partial_order___PartialOrderElement___init(fra.me.REG[0], fra.me.REG[1], fra.me.REG[2]);
/* ./metamodel//partial_order.nit:147 */
+ fra.me.REG[2] = NEW_PartialOrderElement_partial_order___PartialOrderElement___init(fra.me.REG[0], fra.me.REG[1], fra.me.REG[2]);
goto label1;
label1: while(0);
stack_frame_head = fra.me.prev;
return fra.me.REG[2];
}
val_t partial_order___PartialOrder___add_to_smallests(val_t p0, val_t p1, val_t p2, val_t p3){
- struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[5];} fra;
val_t REGB0;
val_t REGB1;
+ val_t REGB2;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
fra.me.line = 150;
fra.me.meth = LOCATE_partial_order___PartialOrder___add_to_smallests;
fra.me.has_broke = 0;
- fra.me.REG_size = 5;
+ fra.me.REG_size = 6;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[3] = NIT_NULL;
fra.me.REG[4] = NIT_NULL;
+ fra.me.REG[5] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
fra.me.REG[3] = p3;
/* ./metamodel//partial_order.nit:157 */
CALL_abstract_collection___RemovableCollection___clear(fra.me.REG[3])(fra.me.REG[3]);
+ /* ./metamodel//partial_order.nit:158 */
fra.me.REG[0] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
- fra.me.REG[2] = CALL_abstract_collection___Collection___iterator(fra.me.REG[2])(fra.me.REG[2]);
- /* ./metamodel//partial_order.nit:159 */
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB0 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[2])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[2]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[4] = ATTR_array___Array____items(fra.me.REG[2]);
+ /* ./../lib/standard//collection//array.nit:237 */
while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[2])(fra.me.REG[2]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[4] = CALL_abstract_collection___Iterator___item(fra.me.REG[2])(fra.me.REG[2]);
- REGB0 = CALL_partial_order___PartialOrderElement_____g(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[4]);
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[2])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[2]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB1)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB1 = TAG_Bool(fra.me.REG[4]==NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[5] = ((Nit_NativeArray)fra.me.REG[4])->val[UNTAG_Int(REGB0)];
/* ./metamodel//partial_order.nit:160 */
- if (UNTAG_Bool(REGB0)) {
- REGB0 = TAG_Bool(false);
+ REGB1 = CALL_partial_order___PartialOrderElement_____g(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[5]);
+ if (UNTAG_Bool(REGB1)) {
/* ./metamodel//partial_order.nit:161 */
+ REGB1 = TAG_Bool(false);
goto label1;
}
- REGB1 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[4]);
- REGB1 = TAG_Bool(!UNTAG_Bool(REGB1));
/* ./metamodel//partial_order.nit:163 */
- if (UNTAG_Bool(REGB1)) {
+ REGB2 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[5]);
+ REGB2 = TAG_Bool(!UNTAG_Bool(REGB2));
+ if (UNTAG_Bool(REGB2)) {
/* ./metamodel//partial_order.nit:164 */
- array___Array___add(fra.me.REG[3], fra.me.REG[4]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[5]);
}
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB2 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB2 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB2));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB0 = REGB2;
} else {
- /* ./metamodel//partial_order.nit:159 */
+ /* ./../lib/standard//collection//array.nit:237 */
goto label2;
}
- CALL_abstract_collection___Iterator___next(fra.me.REG[2])(fra.me.REG[2]);
}
label2: while(0);
/* ./metamodel//partial_order.nit:167 */
- array___Array___add(fra.me.REG[3], fra.me.REG[1]);
- REGB1 = TAG_Bool(true);
- REGB0 = REGB1;
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[1]);
/* ./metamodel//partial_order.nit:168 */
+ REGB0 = TAG_Bool(true);
+ REGB1 = REGB0;
goto label1;
label1: while(0);
stack_frame_head = fra.me.prev;
- return REGB0;
+ return REGB1;
}
void partial_order___PartialOrder___compute_smallers_for(val_t p0, val_t p1, val_t p2){
- struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
val_t REGB0;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.line = 171;
fra.me.meth = LOCATE_partial_order___PartialOrder___compute_smallers_for;
fra.me.has_broke = 0;
- fra.me.REG_size = 4;
+ fra.me.REG_size = 3;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
- fra.me.REG[3] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
+ /* ./metamodel//partial_order.nit:173 */
fra.me.REG[1] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[1])(fra.me.REG[1]);
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:174 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrder____elements(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_elements");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 174);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_elements", LOCATE_partial_order, 174);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]);
- fra.me.REG[0] = CALL_abstract_collection___Collection___iterator(fra.me.REG[0])(fra.me.REG[0]);
- while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[0])(fra.me.REG[0]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[3] = CALL_abstract_collection___Iterator___item(fra.me.REG[0])(fra.me.REG[0]);
- REGB0 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[1]);
- /* ./metamodel//partial_order.nit:175 */
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[3] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[3])(fra.me.REG[3]);
- /* ./metamodel//partial_order.nit:176 */
- CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
- }
- } else {
- /* ./metamodel//partial_order.nit:174 */
- goto label1;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[0])(fra.me.REG[0]);
- }
- label1: while(0);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[0])(fra.me.REG[0], (&(fra.me)), ((fun_t)OC_partial_order___PartialOrder___compute_smallers_for_1));
stack_frame_head = fra.me.prev;
return;
}
+ void OC_partial_order___PartialOrder___compute_smallers_for_1(struct stack_frame_t *closctx, val_t p0, struct stack_frame_t *closctx_param, fun_t clos_fun0){
+ struct {struct stack_frame_t me;} fra;
+ val_t REGB0;
+ fun_t CREG[1];
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_partial_order___PartialOrder___compute_smallers_for;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./metamodel//partial_order.nit:175 */
+ REGB0 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[0])(fra.me.REG[0], closctx->REG[1]);
+ if (UNTAG_Bool(REGB0)) {
+ /* ./metamodel//partial_order.nit:176 */
+ fra.me.REG[0] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(closctx->REG[2])(closctx->REG[2], fra.me.REG[0]);
+ }
+ stack_frame_head = fra.me.prev;
+ return;
+ }
void partial_order___PartialOrder___init(val_t p0, int* init_table){
int itpos0 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_PartialOrder].i;
struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
- fra.me.REG[1] = NEW_HashMap_hash_collection___HashMap___init();
/* ./metamodel//partial_order.nit:183 */
+ fra.me.REG[1] = NEW_HashMap_hash_collection___HashMap___init();
ATTR_partial_order___PartialOrder____elements(fra.me.REG[0]) = fra.me.REG[1];
- fra.me.REG[1] = NEW_Array_array___Array___init();
/* ./metamodel//partial_order.nit:184 */
- ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]) = fra.me.REG[1];
fra.me.REG[1] = NEW_Array_array___Array___init();
+ ATTR_partial_order___PartialOrder____elements_list(fra.me.REG[0]) = fra.me.REG[1];
/* ./metamodel//partial_order.nit:185 */
+ fra.me.REG[1] = NEW_Array_array___Array___init();
ATTR_partial_order___PartialOrder____roots(fra.me.REG[0]) = fra.me.REG[1];
stack_frame_head = fra.me.prev;
init_table[itpos0] = 1;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:190 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 190);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 190);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
}
val_t partial_order___PartialOrderElement___value(val_t p0){
struct {struct stack_frame_t me;} fra;
+ val_t REGB0;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
/* ./metamodel//partial_order.nit:193 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 193);
+ }
+ fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
return fra.me.REG[0];
}
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____rank(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:196 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____rank(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_rank");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 196);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_rank", LOCATE_partial_order, 196);
}
REGB0 = ATTR_partial_order___PartialOrderElement____rank(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_greaters(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:202 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_direct_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 202);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_direct_greaters", LOCATE_partial_order, 202);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____direct_greaters(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:205 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_direct_smallers");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 205);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_direct_smallers", LOCATE_partial_order, 205);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
fra.me.REG_size = 1;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:208 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 208);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_greaters", LOCATE_partial_order, 208);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]);
stack_frame_head = fra.me.prev;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:217 */
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____greaters_and_self_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
- /* ./metamodel//partial_order.nit:217 */
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
}
}
if (UNTAG_Bool(REGB0)) {
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:218 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 218);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_greaters", LOCATE_partial_order, 218);
}
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]);
fra.me.REG[1] = CALL_array___Collection___to_a(fra.me.REG[1])(fra.me.REG[1]);
ATTR_partial_order___PartialOrderElement____greaters_and_self_cache(fra.me.REG[0]) = fra.me.REG[1];
+ /* ./metamodel//partial_order.nit:219 */
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____greaters_and_self_cache(fra.me.REG[0]);
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 219);
+ }
fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
- /* ./metamodel//partial_order.nit:219 */
if (UNTAG_Bool(REGB0)) {
- fprintf(stderr, "Reciever is null");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 219);
- nit_exit(1);
+ nit_abort("Reciever is null", NULL, LOCATE_partial_order, 219);
}
- array___Array___add(fra.me.REG[1], fra.me.REG[2]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
}
+ /* ./metamodel//partial_order.nit:221 */
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____greaters_and_self_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[0]!=NIT_NULL);
- /* ./metamodel//partial_order.nit:221 */
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Cast failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 221);
- nit_exit(1);
+ nit_abort("Cast failed", NULL, LOCATE_partial_order, 221);
}
goto label1;
label1: while(0);
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____smallers_last_length(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:233 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____smallers_last_length(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_smallers_last_length");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 233);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_smallers_last_length", LOCATE_partial_order, 233);
}
REGB0 = ATTR_partial_order___PartialOrderElement____smallers_last_length(fra.me.REG[0]);
REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 233);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 233);
}
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
REGB1 = CALL_abstract_collection___Collection___length(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./../lib/standard//kernel.nit:212 */
REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
/* ./metamodel//partial_order.nit:233 */
if (UNTAG_Bool(REGB1)) {
- REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:234 */
+ REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 234);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 234);
}
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_smallers_cache");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 234);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_smallers_cache", LOCATE_partial_order, 234);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0]);
CALL_partial_order___PartialOrder___compute_smallers_for(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[0], fra.me.REG[2]);
- REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:235 */
+ REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 235);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 235);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
REGB1 = CALL_abstract_collection___Collection___length(fra.me.REG[2])(fra.me.REG[2]);
ATTR_partial_order___PartialOrderElement____smallers_last_length(fra.me.REG[0]) = REGB1;
}
- REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:237 */
+ REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_smallers_cache");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 237);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_smallers_cache", LOCATE_partial_order, 237);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0]);
goto label1;
return fra.me.REG[0];
}
val_t partial_order___PartialOrderElement___linear_extension(val_t p0){
- struct {struct stack_frame_t me; val_t MORE_REG[6];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[8];} fra;
val_t REGB0;
val_t REGB1;
+ val_t REGB2;
val_t tmp;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.file = LOCATE_partial_order;
fra.me.line = 243;
fra.me.meth = LOCATE_partial_order___PartialOrderElement___linear_extension;
fra.me.has_broke = 0;
- fra.me.REG_size = 7;
+ fra.me.REG_size = 9;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[4] = NIT_NULL;
fra.me.REG[5] = NIT_NULL;
fra.me.REG[6] = NIT_NULL;
+ fra.me.REG[7] = NIT_NULL;
+ fra.me.REG[8] = NIT_NULL;
fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:247 */
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____linear_extension_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
- /* ./metamodel//partial_order.nit:247 */
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
}
}
if (UNTAG_Bool(REGB0)) {
+ /* ./metamodel//partial_order.nit:248 */
fra.me.REG[1] = NEW_Array_array___Array___init();
+ /* ./metamodel//partial_order.nit:249 */
fra.me.REG[2] = NEW_Array_array___Array___init();
- fra.me.REG[3] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
/* ./metamodel//partial_order.nit:250 */
- array___Array___add(fra.me.REG[1], fra.me.REG[3]);
- fra.me.REG[3] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[0])(fra.me.REG[0]);
- fra.me.REG[3] = CALL_abstract_collection___Collection___iterator(fra.me.REG[3])(fra.me.REG[3]);
+ fra.me.REG[3] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
/* ./metamodel//partial_order.nit:251 */
+ fra.me.REG[3] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[0])(fra.me.REG[0]);
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB0 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[3])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[4] = ATTR_array___Array____items(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:237 */
while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[3])(fra.me.REG[3]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[4] = CALL_abstract_collection___Iterator___item(fra.me.REG[3])(fra.me.REG[3]);
- fra.me.REG[5] = CALL_partial_order___PartialOrderElement___order(fra.me.REG[0])(fra.me.REG[0]);
- fra.me.REG[4] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[5])(fra.me.REG[5], fra.me.REG[4]);
- fra.me.REG[4] = CALL_partial_order___PartialOrderElement___linear_extension(fra.me.REG[4])(fra.me.REG[4]);
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[3])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[3]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB1)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB1 = TAG_Bool(fra.me.REG[4]==NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[5] = ((Nit_NativeArray)fra.me.REG[4])->val[UNTAG_Int(REGB0)];
+ /* ./metamodel//partial_order.nit:252 */
+ fra.me.REG[6] = CALL_partial_order___PartialOrderElement___order(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[5] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[6])(fra.me.REG[6], fra.me.REG[5]);
+ fra.me.REG[5] = CALL_partial_order___PartialOrderElement___linear_extension(fra.me.REG[5])(fra.me.REG[5]);
/* ./metamodel//partial_order.nit:253 */
CALL_abstract_collection___RemovableCollection___clear(fra.me.REG[2])(fra.me.REG[2]);
- fra.me.REG[5] = CALL_abstract_collection___Collection___iterator(fra.me.REG[1])(fra.me.REG[1]);
- /* ./metamodel//partial_order.nit:254 */
+ /* ./../lib/standard//collection//array.nit:231 */
+ fra.me.REG[6] = fra.me.REG[1];
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB1 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB2 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[6])!=NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB2 = ATTR_array___AbstractArrayRead____length(fra.me.REG[6]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[7] = ATTR_array___Array____items(fra.me.REG[6]);
+ /* ./../lib/standard//collection//array.nit:237 */
while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[5])(fra.me.REG[5]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[6] = CALL_abstract_collection___Iterator___item(fra.me.REG[5])(fra.me.REG[5]);
- REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[4])(fra.me.REG[4], fra.me.REG[6]);
- REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB2 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[6])!=NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB2 = ATTR_array___AbstractArrayRead____length(fra.me.REG[6]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB2 = TAG_Bool(UNTAG_Int(REGB1)<UNTAG_Int(REGB2));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB2)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB2 = TAG_Bool(fra.me.REG[7]==NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[8] = ((Nit_NativeArray)fra.me.REG[7])->val[UNTAG_Int(REGB1)];
/* ./metamodel//partial_order.nit:255 */
- if (UNTAG_Bool(REGB0)) {
- array___Array___add(fra.me.REG[2], fra.me.REG[6]);
+ REGB2 = CALL_abstract_collection___Collection___has(fra.me.REG[5])(fra.me.REG[5], fra.me.REG[8]);
+ REGB2 = TAG_Bool(!UNTAG_Bool(REGB2));
+ if (UNTAG_Bool(REGB2)) {
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[8]);
}
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB2 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB2 = TAG_Int(UNTAG_Int(REGB1)+UNTAG_Int(REGB2));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB1 = REGB2;
} else {
- /* ./metamodel//partial_order.nit:254 */
+ /* ./../lib/standard//collection//array.nit:237 */
goto label1;
}
- CALL_abstract_collection___Iterator___next(fra.me.REG[5])(fra.me.REG[5]);
}
label1: while(0);
/* ./metamodel//partial_order.nit:257 */
- CALL_abstract_collection___Sequence___append(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[4]);
- fra.me.REG[4] = fra.me.REG[1];
+ CALL_abstract_collection___Sequence___append(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[5]);
+ /* ./metamodel//partial_order.nit:259 */
+ fra.me.REG[5] = fra.me.REG[1];
+ /* ./metamodel//partial_order.nit:260 */
fra.me.REG[1] = fra.me.REG[2];
- fra.me.REG[2] = fra.me.REG[4];
- /* ./metamodel//partial_order.nit:261 */
+ /* ./metamodel//partial_order.nit:261 */
+ fra.me.REG[2] = fra.me.REG[5];
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB1 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB0 = REGB1;
} else {
- /* ./metamodel//partial_order.nit:251 */
+ /* ./../lib/standard//collection//array.nit:237 */
goto label2;
}
- CALL_abstract_collection___Iterator___next(fra.me.REG[3])(fra.me.REG[3]);
}
label2: while(0);
/* ./metamodel//partial_order.nit:263 */
ATTR_partial_order___PartialOrderElement____linear_extension_cache(fra.me.REG[0]) = fra.me.REG[1];
}
+ /* ./metamodel//partial_order.nit:265 */
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____linear_extension_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[0]!=NIT_NULL);
- /* ./metamodel//partial_order.nit:265 */
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Cast failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 265);
- nit_exit(1);
+ nit_abort("Cast failed", NULL, LOCATE_partial_order, 265);
}
goto label3;
label3: while(0);
return fra.me.REG[0];
}
val_t partial_order___PartialOrderElement___reverse_linear_extension(val_t p0){
- struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[5];} fra;
val_t REGB0;
val_t REGB1;
val_t tmp;
fra.me.line = 271;
fra.me.meth = LOCATE_partial_order___PartialOrderElement___reverse_linear_extension;
fra.me.has_broke = 0;
- fra.me.REG_size = 5;
+ fra.me.REG_size = 6;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[3] = NIT_NULL;
fra.me.REG[4] = NIT_NULL;
+ fra.me.REG[5] = NIT_NULL;
fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:275 */
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____reverse_linear_extension_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
- /* ./metamodel//partial_order.nit:275 */
if (UNTAG_Bool(REGB0)) {
} else {
REGB1 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
}
}
if (UNTAG_Bool(REGB0)) {
+ /* ./metamodel//partial_order.nit:276 */
fra.me.REG[1] = NEW_HashSet_hash_collection___HashSet___init();
- fra.me.REG[2] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[0])(fra.me.REG[0]);
- fra.me.REG[2] = CALL_abstract_collection___Collection___iterator(fra.me.REG[2])(fra.me.REG[2]);
/* ./metamodel//partial_order.nit:277 */
+ fra.me.REG[2] = CALL_partial_order___PartialOrderElement___direct_greaters(fra.me.REG[0])(fra.me.REG[0]);
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB0 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[2])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[2]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[3] = ATTR_array___Array____items(fra.me.REG[2]);
+ /* ./../lib/standard//collection//array.nit:237 */
while(1) {
- REGB0 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[2])(fra.me.REG[2]);
- if (UNTAG_Bool(REGB0)) {
- fra.me.REG[3] = CALL_abstract_collection___Iterator___item(fra.me.REG[2])(fra.me.REG[2]);
- fra.me.REG[4] = CALL_partial_order___PartialOrderElement___order(fra.me.REG[0])(fra.me.REG[0]);
- fra.me.REG[3] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[4])(fra.me.REG[4], fra.me.REG[3]);
- fra.me.REG[3] = CALL_partial_order___PartialOrderElement___linear_extension(fra.me.REG[3])(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB1 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[2])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB1 = ATTR_array___AbstractArrayRead____length(fra.me.REG[2]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB1)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB1 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[4] = ((Nit_NativeArray)fra.me.REG[3])->val[UNTAG_Int(REGB0)];
+ /* ./metamodel//partial_order.nit:278 */
+ fra.me.REG[5] = CALL_partial_order___PartialOrderElement___order(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[4] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[5])(fra.me.REG[5], fra.me.REG[4]);
+ fra.me.REG[4] = CALL_partial_order___PartialOrderElement___linear_extension(fra.me.REG[4])(fra.me.REG[4]);
/* ./metamodel//partial_order.nit:279 */
- CALL_abstract_collection___SimpleCollection___add_all(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ CALL_abstract_collection___SimpleCollection___add_all(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[4]);
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB1 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB0 = REGB1;
} else {
- /* ./metamodel//partial_order.nit:277 */
+ /* ./../lib/standard//collection//array.nit:237 */
goto label1;
}
- CALL_abstract_collection___Iterator___next(fra.me.REG[2])(fra.me.REG[2]);
}
label1: while(0);
- fra.me.REG[2] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
/* ./metamodel//partial_order.nit:281 */
- CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
- fra.me.REG[1] = CALL_array___Collection___to_a(fra.me.REG[1])(fra.me.REG[1]);
+ fra.me.REG[3] = CALL_partial_order___PartialOrderElement___value(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
/* ./metamodel//partial_order.nit:282 */
+ fra.me.REG[1] = CALL_array___Collection___to_a(fra.me.REG[1])(fra.me.REG[1]);
ATTR_partial_order___PartialOrderElement____linear_extension_cache(fra.me.REG[0]) = fra.me.REG[1];
}
+ /* ./metamodel//partial_order.nit:284 */
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____linear_extension_cache(fra.me.REG[0]);
REGB0 = TAG_Bool(fra.me.REG[0]!=NIT_NULL);
- /* ./metamodel//partial_order.nit:284 */
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Cast failed");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 284);
- nit_exit(1);
+ nit_abort("Cast failed", NULL, LOCATE_partial_order, 284);
}
goto label2;
label2: while(0);
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:290 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 290);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_greaters", LOCATE_partial_order, 290);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]);
REGB0 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
- REGB0 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[2],fra.me.REG[1]));
/* ./metamodel//partial_order.nit:296 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
- if (UNTAG_Bool(REGB1)) {
- REGB1 = TAG_Bool(false);
- REGB0 = REGB1;
- } else {
- REGB1 = CALL_kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
- REGB0 = REGB1;
- }
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 296);
+ }
+ fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
+ REGB0 = TAG_Bool(IS_EQUAL_OO(fra.me.REG[2],fra.me.REG[1]));
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ REGB1 = CALL_kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ REGB0 = REGB1;
}
if (UNTAG_Bool(REGB0)) {
REGB0 = TAG_Bool(true);
REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 296);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_greaters", LOCATE_partial_order, 296);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]);
REGB1 = CALL_abstract_collection___Collection___has(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:302 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 302);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 302);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
fra.me.REG[1] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 302);
+ }
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
REGB0 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[0]);
goto label1;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
- REGB0 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[2],fra.me.REG[1]));
/* ./metamodel//partial_order.nit:308 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
- if (UNTAG_Bool(REGB1)) {
- REGB1 = TAG_Bool(false);
- REGB0 = REGB1;
- } else {
- REGB1 = CALL_kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
- REGB0 = REGB1;
- }
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 308);
+ }
+ fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
+ REGB0 = TAG_Bool(IS_EQUAL_OO(fra.me.REG[2],fra.me.REG[1]));
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ REGB1 = CALL_kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ REGB0 = REGB1;
}
if (UNTAG_Bool(REGB0)) {
REGB0 = TAG_Bool(true);
REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB1)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 308);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 308);
}
fra.me.REG[2] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
fra.me.REG[1] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB1)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_value", LOCATE_partial_order, 308);
+ }
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]);
REGB1 = CALL_partial_order___PartialOrderElement_____l(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[0]);
REGB0 = REGB1;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:313 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_direct_smallers");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 313);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_direct_smallers", LOCATE_partial_order, 313);
}
fra.me.REG[0] = ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0]);
- array___Array___add(fra.me.REG[0], fra.me.REG[1]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
stack_frame_head = fra.me.prev;
return;
}
void partial_order___PartialOrderElement___init(val_t p0, val_t p1, val_t p2, val_t p3, int* init_table){
int itpos1 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_PartialOrderElement].i;
- struct {struct stack_frame_t me; val_t MORE_REG[5];} fra;
+ struct {struct stack_frame_t me; val_t MORE_REG[6];} fra;
val_t REGB0;
val_t REGB1;
val_t REGB2;
+ val_t REGB3;
val_t tmp;
if (init_table[itpos1]) return;
fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
fra.me.line = 316;
fra.me.meth = LOCATE_partial_order___PartialOrderElement___init;
fra.me.has_broke = 0;
- fra.me.REG_size = 6;
+ fra.me.REG_size = 7;
fra.me.REG[0] = NIT_NULL;
fra.me.REG[1] = NIT_NULL;
fra.me.REG[2] = NIT_NULL;
fra.me.REG[3] = NIT_NULL;
fra.me.REG[4] = NIT_NULL;
fra.me.REG[5] = NIT_NULL;
+ fra.me.REG[6] = NIT_NULL;
fra.me.REG[0] = p0;
fra.me.REG[1] = p1;
fra.me.REG[2] = p2;
ATTR_partial_order___PartialOrderElement____value(fra.me.REG[0]) = fra.me.REG[2];
/* ./metamodel//partial_order.nit:320 */
ATTR_partial_order___PartialOrderElement____direct_greaters(fra.me.REG[0]) = fra.me.REG[3];
- fra.me.REG[1] = NEW_Array_array___Array___init();
/* ./metamodel//partial_order.nit:321 */
+ fra.me.REG[1] = NEW_Array_array___Array___init();
ATTR_partial_order___PartialOrderElement____direct_smallers(fra.me.REG[0]) = fra.me.REG[1];
- fra.me.REG[1] = NEW_HashSet_hash_collection___HashSet___init();
/* ./metamodel//partial_order.nit:323 */
- ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]) = fra.me.REG[1];
fra.me.REG[1] = NEW_HashSet_hash_collection___HashSet___init();
+ ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]) = fra.me.REG[1];
/* ./metamodel//partial_order.nit:324 */
+ fra.me.REG[1] = NEW_HashSet_hash_collection___HashSet___init();
ATTR_partial_order___PartialOrderElement____smallers_cache(fra.me.REG[0]) = fra.me.REG[1];
- REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
/* ./metamodel//partial_order.nit:326 */
+ REGB0 = TAG_Bool(ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0])!=NIT_NULL);
if (UNTAG_Bool(REGB0)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_greaters");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 326);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_greaters", LOCATE_partial_order, 326);
}
fra.me.REG[1] = ATTR_partial_order___PartialOrderElement____greaters(fra.me.REG[0]);
+ /* ./metamodel//partial_order.nit:327 */
REGB0 = TAG_Int(0);
- fra.me.REG[3] = CALL_abstract_collection___Collection___iterator(fra.me.REG[3])(fra.me.REG[3]);
- /* ./metamodel//partial_order.nit:328 */
+ /* ./../lib/standard//collection//array.nit:234 */
+ REGB1 = TAG_Int(0);
+ /* ./../lib/standard//collection//array.nit:235 */
+ REGB2 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[3])!=NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 235);
+ }
+ REGB2 = ATTR_array___AbstractArrayRead____length(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:236 */
+ fra.me.REG[4] = ATTR_array___Array____items(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:237 */
while(1) {
- REGB1 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[3])(fra.me.REG[3]);
- if (UNTAG_Bool(REGB1)) {
- fra.me.REG[4] = CALL_abstract_collection___Iterator___item(fra.me.REG[3])(fra.me.REG[3]);
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB2 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[3])!=NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB2 = ATTR_array___AbstractArrayRead____length(fra.me.REG[3]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB2 = TAG_Bool(UNTAG_Int(REGB1)<UNTAG_Int(REGB2));
+ /* ./../lib/standard//collection//array.nit:237 */
+ if (UNTAG_Bool(REGB2)) {
+ /* ./../lib/standard//collection//array.nit:238 */
+ REGB2 = TAG_Bool(fra.me.REG[4]==NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 238);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[5] = ((Nit_NativeArray)fra.me.REG[4])->val[UNTAG_Int(REGB1)];
/* ./metamodel//partial_order.nit:329 */
- CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[4]);
- REGB1 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[5]);
/* ./metamodel//partial_order.nit:330 */
- if (UNTAG_Bool(REGB1)) {
+ REGB2 = TAG_Bool(ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB2)) {
} else {
- fprintf(stderr, "Uninitialized attribute %s", "_order");
- fprintf(stderr, " (%s:%d)\n", LOCATE_partial_order, 330);
- nit_exit(1);
+ nit_abort("Uninitialized attribute %s", "_order", LOCATE_partial_order, 330);
}
- fra.me.REG[5] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
- fra.me.REG[4] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[5])(fra.me.REG[5], fra.me.REG[4]);
- REGB1 = CALL_partial_order___PartialOrderElement___rank(fra.me.REG[4])(fra.me.REG[4]);
- REGB1 = TAG_Bool(UNTAG_Int(REGB1)>=UNTAG_Int(REGB0));
+ fra.me.REG[6] = ATTR_partial_order___PartialOrderElement____order(fra.me.REG[0]);
+ fra.me.REG[5] = CALL_partial_order___PartialOrder_____bra(fra.me.REG[6])(fra.me.REG[6], fra.me.REG[5]);
/* ./metamodel//partial_order.nit:331 */
- if (UNTAG_Bool(REGB1)) {
- REGB1 = CALL_partial_order___PartialOrderElement___rank(fra.me.REG[4])(fra.me.REG[4]);
- REGB2 = TAG_Int(1);
- REGB2 = TAG_Int(UNTAG_Int(REGB1)+UNTAG_Int(REGB2));
- REGB0 = REGB2;
- /* ./metamodel//partial_order.nit:332 */
+ REGB2 = CALL_partial_order___PartialOrderElement___rank(fra.me.REG[5])(fra.me.REG[5]);
+ /* ./../lib/standard//kernel.nit:213 */
+ REGB2 = TAG_Bool(UNTAG_Int(REGB2)>=UNTAG_Int(REGB0));
+ /* ./metamodel//partial_order.nit:331 */
+ if (UNTAG_Bool(REGB2)) {
+ /* ./metamodel//partial_order.nit:332 */
+ REGB2 = CALL_partial_order___PartialOrderElement___rank(fra.me.REG[5])(fra.me.REG[5]);
+ REGB3 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB3 = TAG_Int(UNTAG_Int(REGB2)+UNTAG_Int(REGB3));
+ /* ./metamodel//partial_order.nit:332 */
+ REGB0 = REGB3;
}
/* ./metamodel//partial_order.nit:334 */
- CALL_partial_order___PartialOrderElement___register_direct_smallers(fra.me.REG[4])(fra.me.REG[4], fra.me.REG[2]);
- fra.me.REG[4] = CALL_partial_order___PartialOrderElement___greaters(fra.me.REG[4])(fra.me.REG[4]);
- fra.me.REG[4] = CALL_abstract_collection___Collection___iterator(fra.me.REG[4])(fra.me.REG[4]);
+ CALL_partial_order___PartialOrderElement___register_direct_smallers(fra.me.REG[5])(fra.me.REG[5], fra.me.REG[2]);
/* ./metamodel//partial_order.nit:335 */
- while(1) {
- REGB2 = CALL_abstract_collection___Iterator___is_ok(fra.me.REG[4])(fra.me.REG[4]);
- if (UNTAG_Bool(REGB2)) {
- fra.me.REG[5] = CALL_abstract_collection___Iterator___item(fra.me.REG[4])(fra.me.REG[4]);
- /* ./metamodel//partial_order.nit:336 */
- CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[5]);
- } else {
- /* ./metamodel//partial_order.nit:335 */
- goto label1;
- }
- CALL_abstract_collection___Iterator___next(fra.me.REG[4])(fra.me.REG[4]);
- }
- label1: while(0);
+ fra.me.REG[5] = CALL_partial_order___PartialOrderElement___greaters(fra.me.REG[5])(fra.me.REG[5]);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[5])(fra.me.REG[5], (&(fra.me)), ((fun_t)OC_partial_order___PartialOrderElement___init_1));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB3 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB3 = TAG_Int(UNTAG_Int(REGB1)+UNTAG_Int(REGB3));
+ /* ./../lib/standard//collection//array.nit:239 */
+ REGB1 = REGB3;
} else {
- /* ./metamodel//partial_order.nit:328 */
+ /* ./../lib/standard//collection//array.nit:237 */
goto label2;
}
- CALL_abstract_collection___Iterator___next(fra.me.REG[3])(fra.me.REG[3]);
}
label2: while(0);
/* ./metamodel//partial_order.nit:339 */
init_table[itpos1] = 1;
return;
}
+ void OC_partial_order___PartialOrderElement___init_1(struct stack_frame_t *closctx, val_t p0){
+ struct {struct stack_frame_t me;} fra;
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_partial_order;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_partial_order___PartialOrderElement___init;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.REG[0] = p0;
+ /* ./metamodel//partial_order.nit:336 */
+ CALL_abstract_collection___SimpleCollection___add(closctx->REG[1])(closctx->REG[1], fra.me.REG[0]);
+ stack_frame_head = fra.me.prev;
+ return;
+ }