/* This C file is generated by NIT to compile module abstracttool. */
#include "abstracttool._sep.h"
-void abstracttool___AbstractCompiler___init(val_t self, int* init_table) {
- struct trace_t trace = {NULL, NULL, 28, LOCATE_abstracttool___AbstractCompiler___init};
- val_t variable0;
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- if (init_table[VAL2OBJ( self)->vft[INIT_TABLE_POS_AbstractCompiler].i]) return;
- ((mmloader___ToolContext___init_t)CALL( self,COLOR_mmloader___ToolContext___init))( self, init_table /*YYY*/) /*ToolContext::init*/;
- variable0 = NEW_syntax___SrcModuleLoader___init(); /*new SrcModuleLoader*/
- ((mmloader___ToolContext___register_loader_t)CALL( self,COLOR_mmloader___ToolContext___register_loader))( self, variable0) /*ToolContext::register_loader*/;
- init_table[VAL2OBJ( self)->vft[INIT_TABLE_POS_AbstractCompiler].i] = 1;
- tracehead = trace.prev;
+void abstracttool___AbstractCompiler___init(val_t p0, val_t p1, int* init_table){
+ int itpos0 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_AbstractCompiler].i;
+ struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
+ val_t tmp;
+ if (init_table[itpos0]) return;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 29;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___init;
+ fra.me.has_broke = 0;
+ 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[0] = p0;
+ fra.me.REG[1] = p1;
+ /* ./abstracttool.nit:29 */
+ fra.me.REG[2] = fra.me.REG[0];
+ /* ./abstracttool.nit:31 */
+ ATTR_abstracttool___AbstractCompiler____tool_name(fra.me.REG[2]) = fra.me.REG[1];
+ /* ./abstracttool.nit:32 */
+ CALL_mmloader___ToolContext___init(fra.me.REG[0])(fra.me.REG[0], init_table);
+ /* ./abstracttool.nit:33 */
+ fra.me.REG[0] = NEW_SrcModuleLoader_syntax___SrcModuleLoader___init();
+ CALL_mmloader___ToolContext___register_loader(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[0]);
+ stack_frame_head = fra.me.prev;
+ init_table[itpos0] = 1;
return;
}
-void abstracttool___AbstractCompiler___exec_cmd_line(val_t self) {
- struct trace_t trace = {NULL, NULL, 34, LOCATE_abstracttool___AbstractCompiler___exec_cmd_line};
- val_t variable0;
- val_t variable1;
- val_t variable2;
- val_t variable3;
- val_t variable4;
- val_t variable5;
- val_t variable6;
- val_t variable7;
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- ((mmloader___ToolContext___process_options_t)CALL( self,COLOR_mmloader___ToolContext___process_options))( self) /*ToolContext::process_options*/;
- variable0 = ((mmloader___ToolContext___opt_help_t)CALL( self,COLOR_mmloader___ToolContext___opt_help))( self) /*ToolContext::opt_help*/;
- variable0 = ((opts___Option___value_t)CALL(variable0,COLOR_opts___Option___value))(variable0) /*Option::value*/;
- if (UNTAG_Bool(variable0)) { /*if*/
- variable0 = ((mmloader___ToolContext___option_context_t)CALL( self,COLOR_mmloader___ToolContext___option_context))( self) /*ToolContext::option_context*/;
- ((opts___OptionContext___usage_t)CALL(variable0,COLOR_opts___OptionContext___usage))(variable0) /*OptionContext::usage*/;
- exit(UNTAG_Int( TAG_Int(0)));
+val_t abstracttool___AbstractCompiler___tool_name(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_abstracttool;
+ fra.me.line = 36;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___tool_name;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 1;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.REG[0] = p0;
+ /* ./abstracttool.nit:36 */
+ REGB0 = TAG_Bool(ATTR_abstracttool___AbstractCompiler____tool_name(fra.me.REG[0])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_tool_name", LOCATE_abstracttool, 36);
}
- variable0 = ((mmloader___ToolContext___option_context_t)CALL( self,COLOR_mmloader___ToolContext___option_context))( self) /*ToolContext::option_context*/;
- variable0 = ((opts___OptionContext___rest_t)CALL(variable0,COLOR_opts___OptionContext___rest))(variable0) /*OptionContext::rest*/;
- variable0 = ((array___AbstractArray___length_t)CALL(variable0,COLOR_abstract_collection___Collection___length))(variable0) /*AbstractArray::length*/;
- variable0 = TAG_Bool((variable0)==( TAG_Int(0)));
- if (UNTAG_Bool(variable0)) { /*if*/
- variable0 = ((mmloader___ToolContext___option_context_t)CALL( self,COLOR_mmloader___ToolContext___option_context))( self) /*ToolContext::option_context*/;
- ((opts___OptionContext___usage_t)CALL(variable0,COLOR_opts___OptionContext___usage))(variable0) /*OptionContext::usage*/;
- exit(UNTAG_Int( TAG_Int(1)));
+ fra.me.REG[0] = ATTR_abstracttool___AbstractCompiler____tool_name(fra.me.REG[0]);
+ stack_frame_head = fra.me.prev;
+ return fra.me.REG[0];
+}
+void abstracttool___AbstractCompiler___exec_cmd_line(val_t p0){
+ struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
+ val_t REGB0;
+ val_t REGB1;
+ val_t REGB2;
+ val_t REGB3;
+ val_t REGB4;
+ val_t tmp;
+ static val_t once_value_1; /* Once value */
+ static val_t once_value_2; /* Once value */
+ static val_t once_value_3; /* Once value */
+ static val_t once_value_4; /* Once value */
+ static val_t once_value_5; /* Once value */
+ static val_t once_value_6; /* Once value */
+ static val_t once_value_7; /* Once value */
+ static val_t once_value_8; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 40;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___exec_cmd_line;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 4;
+ 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;
+ /* ./abstracttool.nit:42 */
+ CALL_mmloader___ToolContext___process_options(fra.me.REG[0])(fra.me.REG[0]);
+ /* ./abstracttool.nit:44 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___opt_version(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___Option___value(fra.me.REG[1])(fra.me.REG[1]);
+ if (UNTAG_Bool(fra.me.REG[1])) {
+ /* ./abstracttool.nit:45 */
+ REGB0 = TAG_Int(5);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_1) {
+ fra.me.REG[2] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_1 = fra.me.REG[2];
+ register_static_object(&once_value_1);
+ } else fra.me.REG[2] = once_value_1;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_abstracttool___AbstractCompiler___tool_name(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_2) {
+ fra.me.REG[2] = BOX_NativeString(" version ");
+ REGB0 = TAG_Int(9);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_2 = fra.me.REG[2];
+ register_static_object(&once_value_2);
+ } else fra.me.REG[2] = once_value_2;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_nit_version___Object___nit_version(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_3) {
+ fra.me.REG[2] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_3 = fra.me.REG[2];
+ register_static_object(&once_value_3);
+ } else fra.me.REG[2] = once_value_3;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(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]);
+ CALL_file___Object___print(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
+ /* ./abstracttool.nit:46 */
+ REGB0 = TAG_Int(0);
+ CALL_kernel___Object___exit(fra.me.REG[0])(fra.me.REG[0], REGB0);
+ }
+ /* ./abstracttool.nit:49 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___opt_help(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___Option___value(fra.me.REG[1])(fra.me.REG[1]);
+ if (UNTAG_Bool(fra.me.REG[1])) {
+ /* ./abstracttool.nit:50 */
+ REGB0 = TAG_Int(3);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_4) {
+ fra.me.REG[2] = BOX_NativeString("usage: ");
+ REGB0 = TAG_Int(7);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_4 = fra.me.REG[2];
+ register_static_object(&once_value_4);
+ } else fra.me.REG[2] = once_value_4;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_abstracttool___AbstractCompiler___tool_name(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_5) {
+ fra.me.REG[2] = BOX_NativeString(" [options] file...");
+ REGB0 = TAG_Int(18);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_5 = fra.me.REG[2];
+ register_static_object(&once_value_5);
+ } else fra.me.REG[2] = once_value_5;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(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]);
+ CALL_file___Object___print(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
+ /* ./abstracttool.nit:51 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___option_context(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_opts___OptionContext___usage(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./abstracttool.nit:52 */
+ REGB0 = TAG_Int(0);
+ CALL_kernel___Object___exit(fra.me.REG[0])(fra.me.REG[0], REGB0);
+ }
+ /* ./abstracttool.nit:55 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___option_context(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___OptionContext___rest(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./../lib/standard//collection//array.nit:23 */
+ REGB0 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[1])!=NIT_NULL);
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 23);
+ }
+ REGB0 = ATTR_array___AbstractArrayRead____length(fra.me.REG[1]);
+ /* ./abstracttool.nit:55 */
+ REGB1 = TAG_Int(0);
+ REGB2 = TAG_Bool(IS_EQUAL_OO(REGB0,REGB1));
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ /* ./../lib/standard//kernel.nit:207 */
+ REGB1 = TAG_Bool((REGB0)==(REGB1));
+ /* ./abstracttool.nit:55 */
+ REGB2 = REGB1;
}
- variable1 = ((mmloader___ToolContext___option_context_t)CALL( self,COLOR_mmloader___ToolContext___option_context))( self) /*ToolContext::option_context*/;
- variable1 = ((opts___OptionContext___rest_t)CALL(variable1,COLOR_opts___OptionContext___rest))(variable1) /*OptionContext::rest*/;
- variable0 = variable1;
- variable2 = NEW_array___Array___init(); /*new Array[E]*/
- variable1 = variable2;
- variable2 = ((array___AbstractArray___length_t)CALL( variable0 /*rest*/,COLOR_abstract_collection___Collection___length))( variable0 /*rest*/) /*AbstractArray::length*/;
- variable3 = NEW_range___Range___without_last( TAG_Int(0), variable2); /*new Range[E]*/
- variable2 = variable3;
- variable2 = ((range___Range___iterator_t)CALL(variable2,COLOR_abstract_collection___Collection___iterator))(variable2) /*Range::iterator*/;
- while (true) { /*for*/
- variable3 = ((abstract_collection___Iterator___is_ok_t)CALL(variable2,COLOR_abstract_collection___Iterator___is_ok))(variable2) /*Iterator::is_ok*/;
- if (!UNTAG_Bool(variable3)) break; /*for*/
- variable3 = ((abstract_collection___Iterator___item_t)CALL(variable2,COLOR_abstract_collection___Iterator___item))(variable2) /*Iterator::item*/;
- variable5 = variable3 /*i*/;
- variable6 = TAG_Bool(UNTAG_Int( variable5 /*index*/)>=UNTAG_Int( TAG_Int(0)));
- variable7 = variable6;
- if (UNTAG_Bool(variable7)) { /* and */
- variable7 = ATTR_array___AbstractArray____length( variable0 /*rest*/) /*AbstractArray::_length*/;
- variable7 = TAG_Bool(UNTAG_Int( variable5 /*index*/)<UNTAG_Int(variable7));
+ if (UNTAG_Bool(REGB2)) {
+ /* ./abstracttool.nit:56 */
+ REGB2 = TAG_Int(3);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB2);
+ if (!once_value_6) {
+ fra.me.REG[2] = BOX_NativeString("usage: ");
+ REGB2 = TAG_Int(7);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB2);
+ once_value_6 = fra.me.REG[2];
+ register_static_object(&once_value_6);
+ } else fra.me.REG[2] = once_value_6;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_abstracttool___AbstractCompiler___tool_name(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_7) {
+ fra.me.REG[2] = BOX_NativeString(" [options] file...");
+ REGB2 = TAG_Int(18);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB2);
+ once_value_7 = fra.me.REG[2];
+ register_static_object(&once_value_7);
+ } else fra.me.REG[2] = once_value_7;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(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]);
+ CALL_file___Object___print(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
+ /* ./abstracttool.nit:57 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___option_context(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_opts___OptionContext___usage(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./abstracttool.nit:58 */
+ REGB2 = TAG_Int(1);
+ CALL_kernel___Object___exit(fra.me.REG[0])(fra.me.REG[0], REGB2);
+ }
+ /* ./abstracttool.nit:61 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___option_context(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___OptionContext___rest(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./abstracttool.nit:62 */
+ fra.me.REG[2] = NEW_Array_array___Array___init();
+ /* ./abstracttool.nit:63 */
+ if (!once_value_8) {
+ fra.me.REG[3] = BOX_NativeString("Syntax analysis");
+ REGB2 = TAG_Int(15);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB2);
+ once_value_8 = fra.me.REG[3];
+ register_static_object(&once_value_8);
+ } else fra.me.REG[3] = once_value_8;
+ fra.me.REG[3] = fra.me.REG[3];
+ REGB2 = TAG_Int(1);
+ CALL_mmloader___ToolContext___info(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[3], REGB2);
+ /* ./abstracttool.nit:64 */
+ REGB2 = TAG_Int(0);
+ /* ./../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:332 */
+ while(1) {
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB0 = TAG_Bool(UNTAG_Int(REGB2)<UNTAG_Int(REGB1));
+ /* ./../lib/standard//kernel.nit:332 */
+ if (UNTAG_Bool(REGB0)) {
+ /* ./abstracttool.nit:64 */
+ REGB0 = REGB2;
+ /* ./../lib/standard//collection//array.nit:243 */
+ fra.me.REG[3] = fra.me.REG[1];
+ /* ./../lib/standard//collection//array.nit:245 */
+ REGB3 = TAG_Int(0);
+ /* ./../lib/standard//kernel.nit:213 */
+ REGB3 = TAG_Bool(UNTAG_Int(REGB0)>=UNTAG_Int(REGB3));
+ /* ./../lib/standard//collection//array.nit:245 */
+ if (UNTAG_Bool(REGB3)) {
+ REGB3 = TAG_Bool(ATTR_array___AbstractArrayRead____length(fra.me.REG[3])!=NIT_NULL);
+ if (UNTAG_Bool(REGB3)) {
+ } else {
+ nit_abort("Uninitialized attribute %s", "_length", LOCATE_array, 245);
+ }
+ REGB3 = ATTR_array___AbstractArrayRead____length(fra.me.REG[3]);
+ /* ./../lib/standard//kernel.nit:212 */
+ REGB3 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB3));
+ } else {
+ /* ./../lib/standard//collection//array.nit:245 */
+ REGB4 = TAG_Bool(false);
+ REGB3 = REGB4;
+ }
+ if (UNTAG_Bool(REGB3)) {
+ } else {
+ nit_abort("Assert %s failed", "'index'", LOCATE_array, 245);
+ }
+ /* ./../lib/standard//collection//array.nit:246 */
+ fra.me.REG[3] = ATTR_array___Array____items(fra.me.REG[3]);
+ REGB3 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
+ if (UNTAG_Bool(REGB3)) {
+ nit_abort("Reciever is null", NULL, LOCATE_array, 246);
+ }
+ /* ./../lib/standard//collection//array.nit:654 */
+ fra.me.REG[3] = ((Nit_NativeArray)fra.me.REG[3])->val[UNTAG_Int(REGB0)];
+ /* ./../lib/standard//collection//array.nit:246 */
+ goto label9;
+ label9: while(0);
+ /* ./abstracttool.nit:65 */
+ fra.me.REG[3] = CALL_mmloader___ToolContext___get_module_from_filename(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[3]);
+ /* ./abstracttool.nit:66 */
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ /* ./../lib/standard//kernel.nit:334 */
+ REGB0 = TAG_Int(1);
+ /* ./../lib/standard//kernel.nit:215 */
+ REGB0 = TAG_Int(UNTAG_Int(REGB2)+UNTAG_Int(REGB0));
+ /* ./../lib/standard//kernel.nit:334 */
+ REGB2 = REGB0;
+ } else {
+ /* ./../lib/standard//kernel.nit:332 */
+ goto label10;
}
- variable6 = variable7;
- if (!UNTAG_Bool(variable6)) { fprintf(stderr, "Assert%s failed", " 'index' "); fprintf(stderr, " in %s (%s:%d)\n", LOCATE_array___Array_____bra, LOCATE_abstracttool, 229); nit_exit(1);}
- variable6 = ATTR_array___Array____items( variable0 /*rest*/) /*Array::_items*/;
- variable6 = UNBOX_NativeArray(variable6)[UNTAG_Int( variable5 /*index*/)];
- goto return_label3;
- return_label3: while(false);
- variable5 = variable6;
- variable5 = ((mmloader___ToolContext___get_module_from_filename_t)CALL( self,COLOR_mmloader___ToolContext___get_module_from_filename))( self, variable5) /*ToolContext::get_module_from_filename*/;
- variable4 = variable5;
- ((array___AbstractArray___add_t)CALL( variable1 /*to_do*/,COLOR_abstract_collection___SimpleCollection___add))( variable1 /*to_do*/, variable4 /*mod*/) /*AbstractArray::add*/;
- continue_2: while(0);
- ((abstract_collection___Iterator___next_t)CALL(variable2,COLOR_abstract_collection___Iterator___next))(variable2) /*Iterator::next*/;
}
- break_2: while(0);
- variable2 = ((mmloader___ToolContext___opt_log_t)CALL( self,COLOR_mmloader___ToolContext___opt_log))( self) /*ToolContext::opt_log*/;
- variable2 = ((opts___Option___value_t)CALL(variable2,COLOR_opts___Option___value))(variable2) /*Option::value*/;
- if (UNTAG_Bool(variable2)) { /*if*/
- ((abstracttool___AbstractCompiler___dump_context_info_t)CALL( self,COLOR_abstracttool___AbstractCompiler___dump_context_info))( self) /*AbstractCompiler::dump_context_info*/;
+ label10: while(0);
+ /* ./abstracttool.nit:68 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___opt_log(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___Option___value(fra.me.REG[1])(fra.me.REG[1]);
+ if (UNTAG_Bool(fra.me.REG[1])) {
+ /* ./abstracttool.nit:69 */
+ CALL_abstracttool___AbstractCompiler___dump_context_info(fra.me.REG[0])(fra.me.REG[0]);
+ }
+ /* ./abstracttool.nit:72 */
+ REGB2 = CALL_abstract_collection___Collection___is_empty(fra.me.REG[2])(fra.me.REG[2]);
+ REGB2 = TAG_Bool(!UNTAG_Bool(REGB2));
+ if (UNTAG_Bool(REGB2)) {
+ fra.me.REG[1] = CALL_mmloader___ToolContext___opt_only_metamodel(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___Option___value(fra.me.REG[1])(fra.me.REG[1]);
+ REGB2 = TAG_Bool(!UNTAG_Bool(fra.me.REG[1]));
+ } else {
+ REGB1 = TAG_Bool(false);
+ REGB2 = REGB1;
}
- variable2 = ((array___AbstractArray___is_empty_t)CALL( variable1 /*to_do*/,COLOR_abstract_collection___Collection___is_empty))( variable1 /*to_do*/) /*AbstractArray::is_empty*/;
- variable2 = TAG_Bool(!UNTAG_Bool(variable2));
- if (UNTAG_Bool(variable2)) { /* and */
- variable2 = ((mmloader___ToolContext___opt_only_metamodel_t)CALL( self,COLOR_mmloader___ToolContext___opt_only_metamodel))( self) /*ToolContext::opt_only_metamodel*/;
- variable2 = ((opts___Option___value_t)CALL(variable2,COLOR_opts___Option___value))(variable2) /*Option::value*/;
- variable2 = TAG_Bool(!UNTAG_Bool(variable2));
+ if (UNTAG_Bool(REGB2)) {
+ fra.me.REG[1] = CALL_mmloader___ToolContext___opt_only_parse(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_opts___Option___value(fra.me.REG[1])(fra.me.REG[1]);
+ REGB2 = TAG_Bool(!UNTAG_Bool(fra.me.REG[1]));
+ } else {
+ REGB1 = TAG_Bool(false);
+ REGB2 = REGB1;
}
- if (UNTAG_Bool(variable2)) { /*if*/
- ((abstracttool___AbstractCompiler___perform_work_t)CALL( self,COLOR_abstracttool___AbstractCompiler___perform_work))( self, variable1 /*to_do*/) /*AbstractCompiler::perform_work*/;
+ if (UNTAG_Bool(REGB2)) {
+ /* ./abstracttool.nit:73 */
+ CALL_abstracttool___AbstractCompiler___perform_work(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
}
- tracehead = trace.prev;
+ stack_frame_head = fra.me.prev;
return;
}
-void abstracttool___AbstractCompiler___perform_work(val_t self, val_t param0) {
- struct trace_t trace = {NULL, NULL, 63, LOCATE_abstracttool___AbstractCompiler___perform_work};
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- fprintf(stderr, "Deferred method %s called");
- fprintf(stderr, " in %s (%s:%d)\n", LOCATE_array___Array_____bra, LOCATE_abstracttool, 63);
- nit_exit(1);
- tracehead = trace.prev;
+void abstracttool___AbstractCompiler___perform_work(val_t p0, val_t p1){
+ 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_abstracttool;
+ fra.me.line = 77;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___perform_work;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 0;
+ /* ./abstracttool.nit:77 */
+ nit_abort("Deferred method called", NULL, LOCATE_abstracttool, 77);
+ stack_frame_head = fra.me.prev;
return;
}
-void abstracttool___AbstractCompiler___dump_context_info(val_t self) {
- struct trace_t trace = {NULL, NULL, 65, LOCATE_abstracttool___AbstractCompiler___dump_context_info};
- val_t variable0;
- val_t variable1;
- val_t variable2;
- val_t variable3;
- val_t variable4;
- val_t variable5;
- val_t variable6;
- val_t variable7;
- val_t variable8;
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- variable0 = ((abstractmetamodel___MMContext___module_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMContext___module_hierarchy))( self) /*MMContext::module_hierarchy*/;
- variable0 = ((partial_order___PartialOrder___iterator_t)CALL(variable0,COLOR_abstract_collection___Collection___iterator))(variable0) /*PartialOrder::iterator*/;
- while (true) { /*for*/
- variable1 = ((abstract_collection___Iterator___is_ok_t)CALL(variable0,COLOR_abstract_collection___Iterator___is_ok))(variable0) /*Iterator::is_ok*/;
- if (!UNTAG_Bool(variable1)) break; /*for*/
- variable1 = ((abstract_collection___Iterator___item_t)CALL(variable0,COLOR_abstract_collection___Iterator___item))(variable0) /*Iterator::item*/;
- ((abstracttool___MMModule___dump_module_info_t)CALL( variable1 /*mod*/,COLOR_abstracttool___MMModule___dump_module_info))( variable1 /*mod*/) /*MMModule::dump_module_info*/;
- continue_5: while(0);
- ((abstract_collection___Iterator___next_t)CALL(variable0,COLOR_abstract_collection___Iterator___next))(variable0) /*Iterator::next*/;
- }
- break_5: while(0);
- variable1 = NEW_array___Array___init(); /*new Array[E]*/
- variable0 = variable1;
- variable1 = ((abstractmetamodel___MMContext___module_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMContext___module_hierarchy))( self) /*MMContext::module_hierarchy*/;
- ((abstract_collection___SimpleCollection___add_all_t)CALL( variable0 /*tab*/,COLOR_abstract_collection___SimpleCollection___add_all))( variable0 /*tab*/, variable1) /*SimpleCollection::add_all*/;
- variable2 = ((abstractmetamodel___MMContext___module_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMContext___module_hierarchy))( self) /*MMContext::module_hierarchy*/;
- variable2 = ((partial_order___PartialOrder___select_smallests_t)CALL(variable2,COLOR_partial_order___PartialOrder___select_smallests))(variable2, variable0 /*tab*/) /*PartialOrder::select_smallests*/;
- variable3 = NEW_string___String___with_native(BOX_NativeString("-"), TAG_Int(1)); /*new String*/
- variable2 = ((string___Collection___join_t)CALL(variable2,COLOR_string___Collection___join))(variable2, variable3) /*Collection::join*/;
- variable1 = variable2;
- variable3 = NEW_string___String___init(); /*new String*/
- variable4 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable5 = variable4;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable5) /*String::append*/;
- variable6 = variable1 /*name*/;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable6) /*String::append*/;
- variable7 = NEW_string___String___with_native(BOX_NativeString(".full_class_hierarchy.new.dot"), TAG_Int(29)); /*new String*/
- variable8 = variable7;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable8) /*String::append*/;
- variable4 = NEW_file___OFStream___open(variable3); /*new OFStream*/
- variable3 = variable4;
- variable2 = variable3;
- variable3 = ((abstractmetamodel___MMContext___class_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMContext___class_hierarchy))( self) /*MMContext::class_hierarchy*/;
- variable3 = ((partial_order___PartialOrder___to_dot_t)CALL(variable3,COLOR_partial_order___PartialOrder___to_dot))(variable3) /*PartialOrder::to_dot*/;
- ((file___OFStream___write_t)CALL( variable2 /*f*/,COLOR_stream___OStream___write))( variable2 /*f*/, variable3) /*OFStream::write*/;
- ((file___OFStream___close_t)CALL( variable2 /*f*/,COLOR_stream___IOS___close))( variable2 /*f*/) /*OFStream::close*/;
- variable3 = NEW_string___String___init(); /*new String*/
- variable4 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable5 = variable4;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable5) /*String::append*/;
- variable6 = variable1 /*name*/;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable6) /*String::append*/;
- variable7 = NEW_string___String___with_native(BOX_NativeString(".module_hierarchy.new.dot"), TAG_Int(25)); /*new String*/
- variable8 = variable7;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable8) /*String::append*/;
- variable4 = NEW_file___OFStream___open(variable3); /*new OFStream*/
- variable3 = variable4;
- variable2 = variable3 /*f=*/;
- variable3 = ((abstractmetamodel___MMContext___module_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMContext___module_hierarchy))( self) /*MMContext::module_hierarchy*/;
- variable3 = ((partial_order___PartialOrder___to_dot_t)CALL(variable3,COLOR_partial_order___PartialOrder___to_dot))(variable3) /*PartialOrder::to_dot*/;
- ((file___OFStream___write_t)CALL( variable2 /*f*/,COLOR_stream___OStream___write))( variable2 /*f*/, variable3) /*OFStream::write*/;
- ((file___OFStream___close_t)CALL( variable2 /*f*/,COLOR_stream___IOS___close))( variable2 /*f*/) /*OFStream::close*/;
- tracehead = trace.prev;
+void abstracttool___AbstractCompiler___dump_context_info(val_t p0){
+ struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
+ val_t REGB0;
+ val_t tmp;
+ static val_t once_value_2; /* Once value */
+ static val_t once_value_3; /* Once value */
+ static val_t once_value_4; /* Once value */
+ static val_t once_value_5; /* Once value */
+ static val_t once_value_6; /* Once value */
+ static val_t once_value_7; /* Once value */
+ static val_t once_value_8; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 79;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___dump_context_info;
+ 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.REG[0] = p0;
+ /* ./abstracttool.nit:81 */
+ fra.me.REG[1] = CALL_abstractmetamodel___MMContext___module_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[1])(fra.me.REG[1], (&(fra.me)), ((fun_t)OC_abstracttool___AbstractCompiler___dump_context_info_1));
+ /* ./abstracttool.nit:84 */
+ fra.me.REG[1] = NEW_Array_array___Array___init();
+ /* ./abstracttool.nit:85 */
+ fra.me.REG[2] = CALL_abstractmetamodel___MMContext___module_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add_all(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ /* ./abstracttool.nit:86 */
+ fra.me.REG[2] = CALL_abstractmetamodel___MMContext___module_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_partial_order___PartialOrder___select_smallests(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ if (!once_value_2) {
+ fra.me.REG[2] = BOX_NativeString("-");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_2 = fra.me.REG[2];
+ register_static_object(&once_value_2);
+ } else fra.me.REG[2] = once_value_2;
+ fra.me.REG[2] = fra.me.REG[2];
+ fra.me.REG[2] = CALL_string___Collection___join(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ /* ./abstracttool.nit:88 */
+ REGB0 = TAG_Int(5);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_3) {
+ fra.me.REG[3] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_3 = fra.me.REG[3];
+ register_static_object(&once_value_3);
+ } else fra.me.REG[3] = once_value_3;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ fra.me.REG[3] = CALL_mmloader___ToolContext___log_directory(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]);
+ if (!once_value_4) {
+ fra.me.REG[3] = BOX_NativeString("/");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_4 = fra.me.REG[3];
+ register_static_object(&once_value_4);
+ } else fra.me.REG[3] = once_value_4;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_5) {
+ fra.me.REG[3] = BOX_NativeString(".full_class_hierarchy.new.dot");
+ REGB0 = TAG_Int(29);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_5 = fra.me.REG[3];
+ register_static_object(&once_value_5);
+ } else fra.me.REG[3] = once_value_5;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
+ fra.me.REG[1] = NEW_OFStream_file___OFStream___open(fra.me.REG[1]);
+ /* ./abstracttool.nit:89 */
+ fra.me.REG[3] = CALL_abstractmetamodel___MMContext___class_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[3] = CALL_partial_order___PartialOrder___to_dot(fra.me.REG[3])(fra.me.REG[3]);
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ /* ./abstracttool.nit:90 */
+ CALL_stream___IOS___close(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./abstracttool.nit:92 */
+ REGB0 = TAG_Int(5);
+ fra.me.REG[3] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_6) {
+ fra.me.REG[4] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[4] = NEW_String_string___String___with_native(fra.me.REG[4], REGB0);
+ once_value_6 = fra.me.REG[4];
+ register_static_object(&once_value_6);
+ } else fra.me.REG[4] = once_value_6;
+ fra.me.REG[4] = fra.me.REG[4];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[4]);
+ fra.me.REG[4] = CALL_mmloader___ToolContext___log_directory(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[4]);
+ if (!once_value_7) {
+ fra.me.REG[4] = BOX_NativeString("/");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[4] = NEW_String_string___String___with_native(fra.me.REG[4], REGB0);
+ once_value_7 = fra.me.REG[4];
+ register_static_object(&once_value_7);
+ } else fra.me.REG[4] = once_value_7;
+ fra.me.REG[4] = fra.me.REG[4];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[4]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
+ if (!once_value_8) {
+ fra.me.REG[2] = BOX_NativeString(".module_hierarchy.new.dot");
+ REGB0 = TAG_Int(25);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_8 = fra.me.REG[2];
+ register_static_object(&once_value_8);
+ } else fra.me.REG[2] = once_value_8;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
+ fra.me.REG[3] = CALL_string___Object___to_s(fra.me.REG[3])(fra.me.REG[3]);
+ fra.me.REG[3] = NEW_OFStream_file___OFStream___open(fra.me.REG[3]);
+ fra.me.REG[1] = fra.me.REG[3];
+ /* ./abstracttool.nit:93 */
+ fra.me.REG[0] = CALL_abstractmetamodel___MMContext___module_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[0] = CALL_partial_order___PartialOrder___to_dot(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[0]);
+ /* ./abstracttool.nit:94 */
+ CALL_stream___IOS___close(fra.me.REG[1])(fra.me.REG[1]);
+ stack_frame_head = fra.me.prev;
return;
}
-void abstracttool___MMModule___dump_module_info(val_t self) {
- struct trace_t trace = {NULL, NULL, 85, LOCATE_abstracttool___MMModule___dump_module_info};
- val_t variable0;
- val_t variable1;
- val_t variable2;
- val_t variable3;
- val_t variable4;
- val_t variable5;
- val_t variable6;
- val_t variable7;
- val_t variable8;
- val_t variable9;
- val_t variable10;
- val_t variable11;
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- variable1 = ((mmloader___MMModule___filename_t)CALL( self,COLOR_mmloader___MMModule___filename))( self) /*MMModule::filename*/;
- variable1 = ((file___String___file_path_t)CALL(variable1,COLOR_file___String___file_path))(variable1) /*String::file_path*/;
- variable0 = variable1;
- variable2 = NEW_string___String___init(); /*new String*/
- variable3 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable4 = variable3;
- ((string___String___append_t)CALL(variable2,COLOR_abstract_collection___IndexedCollection___append))(variable2, variable4) /*String::append*/;
- variable5 = variable0 /*p*/;
- ((string___String___append_t)CALL(variable2,COLOR_abstract_collection___IndexedCollection___append))(variable2, variable5) /*String::append*/;
- variable6 = NEW_string___String___with_native(BOX_NativeString("/"), TAG_Int(1)); /*new String*/
- variable7 = variable6;
- ((string___String___append_t)CALL(variable2,COLOR_abstract_collection___IndexedCollection___append))(variable2, variable7) /*String::append*/;
- variable8 = ((abstractmetamodel___MMModule___name_t)CALL( self,COLOR_abstractmetamodel___MMModule___name))( self) /*MMModule::name*/;
- variable9 = variable8;
- variable9 = ((string___String___to_s_t)CALL(variable9,COLOR_string___Object___to_s))(variable9) /*String::to_s*/;
- ((string___String___append_t)CALL(variable2,COLOR_abstract_collection___IndexedCollection___append))(variable2, variable9) /*String::append*/;
- variable10 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable11 = variable10;
- ((string___String___append_t)CALL(variable2,COLOR_abstract_collection___IndexedCollection___append))(variable2, variable11) /*String::append*/;
- variable1 = variable2;
- variable3 = NEW_string___String___init(); /*new String*/
- variable4 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable5 = variable4;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable5) /*String::append*/;
- variable6 = variable1 /*fname*/;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable6) /*String::append*/;
- variable7 = NEW_string___String___with_native(BOX_NativeString(".class_hierarchy.new.dot"), TAG_Int(24)); /*new String*/
- variable8 = variable7;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable8) /*String::append*/;
- variable4 = NEW_file___OFStream___open(variable3); /*new OFStream*/
- variable3 = variable4;
- variable2 = variable3;
- variable3 = ((abstractmetamodel___MMModule___class_specialization_hierarchy_t)CALL( self,COLOR_abstractmetamodel___MMModule___class_specialization_hierarchy))( self) /*MMModule::class_specialization_hierarchy*/;
- variable3 = ((partial_order___PartialOrder___to_dot_t)CALL(variable3,COLOR_partial_order___PartialOrder___to_dot))(variable3) /*PartialOrder::to_dot*/;
- ((file___OFStream___write_t)CALL( variable2 /*f*/,COLOR_stream___OStream___write))( variable2 /*f*/, variable3) /*OFStream::write*/;
- ((file___OFStream___close_t)CALL( variable2 /*f*/,COLOR_stream___IOS___close))( variable2 /*f*/) /*OFStream::close*/;
- variable3 = NEW_string___String___init(); /*new String*/
- variable4 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable5 = variable4;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable5) /*String::append*/;
- variable6 = variable1 /*fname*/;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable6) /*String::append*/;
- variable7 = NEW_string___String___with_native(BOX_NativeString(".properties.log"), TAG_Int(15)); /*new String*/
- variable8 = variable7;
- ((string___String___append_t)CALL(variable3,COLOR_abstract_collection___IndexedCollection___append))(variable3, variable8) /*String::append*/;
- variable4 = NEW_file___OFStream___open(variable3); /*new OFStream*/
- variable3 = variable4;
- variable2 = variable3 /*f=*/;
- variable3 = ((abstractmetamodel___MMModule___local_classes_t)CALL( self,COLOR_abstractmetamodel___MMModule___local_classes))( self) /*MMModule::local_classes*/;
- variable3 = ((array___AbstractArray___iterator_t)CALL(variable3,COLOR_abstract_collection___Collection___iterator))(variable3) /*AbstractArray::iterator*/;
- while (true) { /*for*/
- variable4 = ((array___ArrayIterator___is_ok_t)CALL(variable3,COLOR_abstract_collection___Iterator___is_ok))(variable3) /*ArrayIterator::is_ok*/;
- if (!UNTAG_Bool(variable4)) break; /*for*/
- variable4 = ((array___ArrayIterator___item_t)CALL(variable3,COLOR_abstract_collection___Iterator___item))(variable3) /*ArrayIterator::item*/;
- ((abstracttool___MMLocalClass___dump_properties_t)CALL( variable4 /*cla*/,COLOR_abstracttool___MMLocalClass___dump_properties))( variable4 /*cla*/, variable2 /*f*/) /*MMLocalClass::dump_properties*/;
- variable5 = NEW_string___String___with_native(BOX_NativeString("\n"), TAG_Int(1)); /*new String*/
- ((file___OFStream___write_t)CALL( variable2 /*f*/,COLOR_stream___OStream___write))( variable2 /*f*/, variable5) /*OFStream::write*/;
- continue_7: while(0);
- ((array___ArrayIterator___next_t)CALL(variable3,COLOR_abstract_collection___Iterator___next))(variable3) /*ArrayIterator::next*/;
+ void OC_abstracttool___AbstractCompiler___dump_context_info_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[1];} fra;
+ fun_t CREG[1];
+ val_t tmp;
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_abstracttool___AbstractCompiler___dump_context_info;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 2;
+ fra.me.REG[0] = NIT_NULL;
+ fra.me.REG[1] = NIT_NULL;
+ fra.me.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./abstracttool.nit:82 */
+ fra.me.REG[1] = CALL_mmloader___ToolContext___log_directory(closctx->REG[0])(closctx->REG[0]);
+ CALL_abstracttool___MMModule___dump_module_info(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
+ stack_frame_head = fra.me.prev;
+ return;
}
- break_7: while(0);
- ((file___OFStream___close_t)CALL( variable2 /*f*/,COLOR_stream___IOS___close))( variable2 /*f*/) /*OFStream::close*/;
- tracehead = trace.prev;
+void abstracttool___MMModule___dump_module_info(val_t p0, val_t p1){
+ struct {struct stack_frame_t me; val_t MORE_REG[4];} fra;
+ val_t REGB0;
+ val_t tmp;
+ static val_t once_value_1; /* Once value */
+ static val_t once_value_2; /* Once value */
+ static val_t once_value_3; /* Once value */
+ static val_t once_value_4; /* Once value */
+ static val_t once_value_5; /* Once value */
+ static val_t once_value_6; /* Once value */
+ static val_t once_value_7; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 99;
+ fra.me.meth = LOCATE_abstracttool___MMModule___dump_module_info;
+ 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.REG[0] = p0;
+ fra.me.REG[1] = p1;
+ /* ./abstracttool.nit:101 */
+ REGB0 = TAG_Int(5);
+ fra.me.REG[2] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_1) {
+ fra.me.REG[3] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_1 = fra.me.REG[3];
+ register_static_object(&once_value_1);
+ } else fra.me.REG[3] = once_value_1;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ if (!once_value_2) {
+ fra.me.REG[1] = BOX_NativeString("/");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[1] = NEW_String_string___String___with_native(fra.me.REG[1], REGB0);
+ once_value_2 = fra.me.REG[1];
+ register_static_object(&once_value_2);
+ } else fra.me.REG[1] = once_value_2;
+ fra.me.REG[1] = fra.me.REG[1];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ fra.me.REG[1] = CALL_abstractmetamodel___MMModule___name(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ if (!once_value_3) {
+ fra.me.REG[1] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[1] = NEW_String_string___String___with_native(fra.me.REG[1], REGB0);
+ once_value_3 = fra.me.REG[1];
+ register_static_object(&once_value_3);
+ } else fra.me.REG[1] = once_value_3;
+ fra.me.REG[1] = fra.me.REG[1];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
+ fra.me.REG[2] = CALL_string___Object___to_s(fra.me.REG[2])(fra.me.REG[2]);
+ /* ./abstracttool.nit:102 */
+ REGB0 = TAG_Int(3);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_4) {
+ fra.me.REG[3] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_4 = fra.me.REG[3];
+ register_static_object(&once_value_4);
+ } else fra.me.REG[3] = once_value_4;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_5) {
+ fra.me.REG[3] = BOX_NativeString(".class_hierarchy.new.dot");
+ REGB0 = TAG_Int(24);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_5 = fra.me.REG[3];
+ register_static_object(&once_value_5);
+ } else fra.me.REG[3] = once_value_5;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ fra.me.REG[1] = CALL_string___Object___to_s(fra.me.REG[1])(fra.me.REG[1]);
+ fra.me.REG[1] = NEW_OFStream_file___OFStream___open(fra.me.REG[1]);
+ /* ./abstracttool.nit:103 */
+ fra.me.REG[3] = CALL_abstractmetamodel___MMModule___class_specialization_hierarchy(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[3] = CALL_partial_order___PartialOrder___to_dot(fra.me.REG[3])(fra.me.REG[3]);
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ /* ./abstracttool.nit:104 */
+ CALL_stream___IOS___close(fra.me.REG[1])(fra.me.REG[1]);
+ /* ./abstracttool.nit:106 */
+ REGB0 = TAG_Int(3);
+ fra.me.REG[3] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_6) {
+ fra.me.REG[4] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[4] = NEW_String_string___String___with_native(fra.me.REG[4], REGB0);
+ once_value_6 = fra.me.REG[4];
+ register_static_object(&once_value_6);
+ } else fra.me.REG[4] = once_value_6;
+ fra.me.REG[4] = fra.me.REG[4];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[4]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
+ if (!once_value_7) {
+ fra.me.REG[2] = BOX_NativeString(".properties.log");
+ REGB0 = TAG_Int(15);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_7 = fra.me.REG[2];
+ register_static_object(&once_value_7);
+ } else fra.me.REG[2] = once_value_7;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
+ fra.me.REG[3] = CALL_string___Object___to_s(fra.me.REG[3])(fra.me.REG[3]);
+ fra.me.REG[3] = NEW_OFStream_file___OFStream___open(fra.me.REG[3]);
+ fra.me.REG[1] = fra.me.REG[3];
+ /* ./abstracttool.nit:107 */
+ fra.me.REG[0] = CALL_abstractmetamodel___MMModule___local_classes(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[0])(fra.me.REG[0], (&(fra.me)), ((fun_t)OC_abstracttool___MMModule___dump_module_info_8));
+ /* ./abstracttool.nit:111 */
+ CALL_stream___IOS___close(fra.me.REG[1])(fra.me.REG[1]);
+ stack_frame_head = fra.me.prev;
return;
}
-void abstracttool___MMLocalClass___dump_properties(val_t self, val_t param0) {
- struct trace_t trace = {NULL, NULL, 103, LOCATE_abstracttool___MMLocalClass___dump_properties};
- val_t variable0;
- val_t variable1;
- val_t variable2;
- val_t variable3;
- val_t variable4;
- val_t variable5;
- val_t variable6;
- val_t variable7;
- val_t variable8;
- val_t variable9;
- val_t variable10;
- val_t variable11;
- val_t variable12;
- val_t variable13;
- trace.prev = tracehead; tracehead = &trace;
- trace.file = LOCATE_abstracttool;
- variable0 = param0;
- variable1 = NEW_string___String___init(); /*new String*/
- variable2 = NEW_string___String___with_native(BOX_NativeString("class "), TAG_Int(6)); /*new String*/
- variable3 = variable2;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable3) /*String::append*/;
- variable4 = self;
- variable4 = ((string___String___to_s_t)CALL(variable4,COLOR_string___Object___to_s))(variable4) /*String::to_s*/;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable4) /*String::append*/;
- variable5 = NEW_string___String___with_native(BOX_NativeString("\n"), TAG_Int(1)); /*new String*/
- variable6 = variable5;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable6) /*String::append*/;
- ((stream___OStream___write_t)CALL( variable0 /*file*/,COLOR_stream___OStream___write))( variable0 /*file*/, variable1) /*OStream::write*/;
- variable1 = ((abstractmetamodel___MMLocalClass___global_properties_t)CALL( self,COLOR_abstractmetamodel___MMLocalClass___global_properties))( self) /*MMLocalClass::global_properties*/;
- variable1 = ((abstract_collection___Collection___iterator_t)CALL(variable1,COLOR_abstract_collection___Collection___iterator))(variable1) /*Collection::iterator*/;
- while (true) { /*for*/
- variable2 = ((abstract_collection___Iterator___is_ok_t)CALL(variable1,COLOR_abstract_collection___Iterator___is_ok))(variable1) /*Iterator::is_ok*/;
- if (!UNTAG_Bool(variable2)) break; /*for*/
- variable2 = ((abstract_collection___Iterator___item_t)CALL(variable1,COLOR_abstract_collection___Iterator___item))(variable1) /*Iterator::item*/;
- variable4 = ((inheritance___MMLocalClass_____bra_t)CALL( self,COLOR_abstractmetamodel___MMLocalClass_____bra))( self, variable2 /*p*/) /*MMLocalClass::[]*/;
- variable3 = variable4;
- variable4 = NEW_string___String___init(); /*new String*/
- variable5 = NEW_string___String___with_native(BOX_NativeString("\t"), TAG_Int(1)); /*new String*/
- variable6 = variable5;
- ((string___String___append_t)CALL(variable4,COLOR_abstract_collection___IndexedCollection___append))(variable4, variable6) /*String::append*/;
- variable7 = variable3 /*lp*/;
- variable7 = ((string___String___to_s_t)CALL(variable7,COLOR_string___Object___to_s))(variable7) /*String::to_s*/;
- ((string___String___append_t)CALL(variable4,COLOR_abstract_collection___IndexedCollection___append))(variable4, variable7) /*String::append*/;
- variable8 = NEW_string___String___with_native(BOX_NativeString(""), TAG_Int(0)); /*new String*/
- variable9 = variable8;
- ((string___String___append_t)CALL(variable4,COLOR_abstract_collection___IndexedCollection___append))(variable4, variable9) /*String::append*/;
- variable10 = ((genericity___MMLocalClass___get_type_t)CALL( self,COLOR_static_type___MMLocalClass___get_type))( self) /*MMLocalClass::get_type*/;
- variable10 = ((static_type___MMLocalProperty___signature_for_t)CALL( variable3 /*lp*/,COLOR_static_type___MMLocalProperty___signature_for))( variable3 /*lp*/, variable10) /*MMLocalProperty::signature_for*/;
- variable11 = variable10;
- variable11 = ((string___String___to_s_t)CALL(variable11,COLOR_string___Object___to_s))(variable11) /*String::to_s*/;
- ((string___String___append_t)CALL(variable4,COLOR_abstract_collection___IndexedCollection___append))(variable4, variable11) /*String::append*/;
- variable12 = NEW_string___String___with_native(BOX_NativeString("\n"), TAG_Int(1)); /*new String*/
- variable13 = variable12;
- ((string___String___append_t)CALL(variable4,COLOR_abstract_collection___IndexedCollection___append))(variable4, variable13) /*String::append*/;
- ((stream___OStream___write_t)CALL( variable0 /*file*/,COLOR_stream___OStream___write))( variable0 /*file*/, variable4) /*OStream::write*/;
- continue_9: while(0);
- ((abstract_collection___Iterator___next_t)CALL(variable1,COLOR_abstract_collection___Iterator___next))(variable1) /*Iterator::next*/;
+ void OC_abstracttool___MMModule___dump_module_info_8(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;
+ static val_t once_value_9; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_abstracttool___MMModule___dump_module_info;
+ 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;
+ /* ./abstracttool.nit:108 */
+ CALL_abstracttool___MMLocalClass___dump_properties(fra.me.REG[0])(fra.me.REG[0], closctx->REG[1]);
+ /* ./abstracttool.nit:109 */
+ if (!once_value_9) {
+ fra.me.REG[0] = BOX_NativeString("\n");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[0] = NEW_String_string___String___with_native(fra.me.REG[0], REGB0);
+ once_value_9 = fra.me.REG[0];
+ register_static_object(&once_value_9);
+ } else fra.me.REG[0] = once_value_9;
+ fra.me.REG[0] = fra.me.REG[0];
+ CALL_stream___OStream___write(closctx->REG[1])(closctx->REG[1], fra.me.REG[0]);
+ stack_frame_head = fra.me.prev;
+ return;
+ }
+void abstracttool___MMLocalClass___dump_properties(val_t p0, val_t p1){
+ struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
+ val_t REGB0;
+ val_t REGB1;
+ val_t REGB2;
+ val_t tmp;
+ static val_t once_value_1; /* Once value */
+ static val_t once_value_2; /* Once value */
+ static val_t once_value_3; /* Once value */
+ static val_t once_value_4; /* Once value */
+ static val_t once_value_9; /* Once value */
+ static val_t once_value_10; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 116;
+ fra.me.meth = LOCATE_abstracttool___MMLocalClass___dump_properties;
+ fra.me.has_broke = 0;
+ fra.me.REG_size = 4;
+ 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;
+ /* ./abstracttool.nit:118 */
+ REGB0 = TAG_Int(3);
+ fra.me.REG[2] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_1) {
+ fra.me.REG[3] = BOX_NativeString("class ");
+ REGB0 = TAG_Int(6);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_1 = fra.me.REG[3];
+ register_static_object(&once_value_1);
+ } else fra.me.REG[3] = once_value_1;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ fra.me.REG[3] = CALL_string___Object___to_s(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ if (!once_value_2) {
+ fra.me.REG[3] = BOX_NativeString("\n");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_2 = fra.me.REG[3];
+ register_static_object(&once_value_2);
+ } else fra.me.REG[3] = once_value_2;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ fra.me.REG[2] = CALL_string___Object___to_s(fra.me.REG[2])(fra.me.REG[2]);
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ /* ./abstracttool.nit:119 */
+ fra.me.REG[2] = CALL_abstractmetamodel___MMLocalClass___global(fra.me.REG[0])(fra.me.REG[0]);
+ REGB0 = CALL_abstractmetamodel___MMGlobalClass___visibility_level(fra.me.REG[2])(fra.me.REG[2]);
+ REGB1 = TAG_Int(3);
+ REGB2 = TAG_Bool(IS_EQUAL_OO(REGB0,REGB1));
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ /* ./../lib/standard//kernel.nit:207 */
+ REGB1 = TAG_Bool((REGB0)==(REGB1));
+ /* ./abstracttool.nit:119 */
+ REGB2 = REGB1;
+ }
+ if (UNTAG_Bool(REGB2)) {
+ fra.me.REG[2] = CALL_abstractmetamodel___MMLocalClass___global(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[2] = CALL_abstractmetamodel___MMGlobalClass___intro(fra.me.REG[2])(fra.me.REG[2]);
+ REGB2 = TAG_Bool(IS_EQUAL_OO(fra.me.REG[0],fra.me.REG[2]));
+ if (UNTAG_Bool(REGB2)) {
+ } else {
+ REGB1 = CALL_kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
+ REGB2 = REGB1;
+ }
+ REGB2 = TAG_Bool(!UNTAG_Bool(REGB2));
+ } else {
+ REGB1 = TAG_Bool(false);
+ REGB2 = REGB1;
+ }
+ if (UNTAG_Bool(REGB2)) {
+ /* ./abstracttool.nit:120 */
+ if (!once_value_3) {
+ fra.me.REG[2] = BOX_NativeString("\tclass not visible in this module\n");
+ REGB2 = TAG_Int(34);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB2);
+ once_value_3 = fra.me.REG[2];
+ register_static_object(&once_value_3);
+ } else fra.me.REG[2] = once_value_3;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ } else {
+ /* ./abstracttool.nit:121 */
+ fra.me.REG[2] = CALL_abstractmetamodel___MMLocalClass___mmmodule(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[3] = CALL_abstractmetamodel___MMLocalClass___global(fra.me.REG[0])(fra.me.REG[0]);
+ fra.me.REG[3] = CALL_abstractmetamodel___MMGlobalClass___mmmodule(fra.me.REG[3])(fra.me.REG[3]);
+ REGB2 = CALL_abstractmetamodel___MMModule___visibility_for(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
+ REGB1 = TAG_Int(0);
+ REGB0 = TAG_Bool(IS_EQUAL_OO(REGB2,REGB1));
+ if (UNTAG_Bool(REGB0)) {
+ } else {
+ /* ./../lib/standard//kernel.nit:207 */
+ REGB1 = TAG_Bool((REGB2)==(REGB1));
+ /* ./abstracttool.nit:121 */
+ REGB0 = REGB1;
+ }
+ if (UNTAG_Bool(REGB0)) {
+ /* ./abstracttool.nit:122 */
+ if (!once_value_4) {
+ fra.me.REG[3] = BOX_NativeString("\tclass is defined later in the hierarchy\n");
+ REGB0 = TAG_Int(41);
+ fra.me.REG[3] = NEW_String_string___String___with_native(fra.me.REG[3], REGB0);
+ once_value_4 = fra.me.REG[3];
+ register_static_object(&once_value_4);
+ } else fra.me.REG[3] = once_value_4;
+ fra.me.REG[3] = fra.me.REG[3];
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ } else {
+ /* ./abstracttool.nit:124 */
+ fra.me.REG[3] = CALL_abstractmetamodel___MMLocalClass___global_properties(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___Collection___iterate(fra.me.REG[3])(fra.me.REG[3], (&(fra.me)), ((fun_t)OC_abstracttool___MMLocalClass___dump_properties_5));
+ }
}
- break_9: while(0);
- variable1 = NEW_string___String___init(); /*new String*/
- variable2 = NEW_string___String___with_native(BOX_NativeString("end # "), TAG_Int(6)); /*new String*/
- variable3 = variable2;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable3) /*String::append*/;
- variable4 = self;
- variable4 = ((string___String___to_s_t)CALL(variable4,COLOR_string___Object___to_s))(variable4) /*String::to_s*/;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable4) /*String::append*/;
- variable5 = NEW_string___String___with_native(BOX_NativeString("\n"), TAG_Int(1)); /*new String*/
- variable6 = variable5;
- ((string___String___append_t)CALL(variable1,COLOR_abstract_collection___IndexedCollection___append))(variable1, variable6) /*String::append*/;
- ((stream___OStream___write_t)CALL( variable0 /*file*/,COLOR_stream___OStream___write))( variable0 /*file*/, variable1) /*OStream::write*/;
- tracehead = trace.prev;
+ /* ./abstracttool.nit:129 */
+ REGB0 = TAG_Int(3);
+ fra.me.REG[3] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_9) {
+ fra.me.REG[2] = BOX_NativeString("end # ");
+ REGB0 = TAG_Int(6);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_9 = fra.me.REG[2];
+ register_static_object(&once_value_9);
+ } else fra.me.REG[2] = once_value_9;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
+ fra.me.REG[0] = CALL_string___Object___to_s(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[0]);
+ if (!once_value_10) {
+ fra.me.REG[0] = BOX_NativeString("\n");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[0] = NEW_String_string___String___with_native(fra.me.REG[0], REGB0);
+ once_value_10 = fra.me.REG[0];
+ register_static_object(&once_value_10);
+ } else fra.me.REG[0] = once_value_10;
+ fra.me.REG[0] = fra.me.REG[0];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[0]);
+ fra.me.REG[3] = CALL_string___Object___to_s(fra.me.REG[3])(fra.me.REG[3]);
+ CALL_stream___OStream___write(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
+ stack_frame_head = fra.me.prev;
return;
}
+ void OC_abstracttool___MMLocalClass___dump_properties_5(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[2];} fra;
+ val_t REGB0;
+ fun_t CREG[1];
+ val_t tmp;
+ static val_t once_value_6; /* Once value */
+ static val_t once_value_7; /* Once value */
+ static val_t once_value_8; /* Once value */
+ fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
+ fra.me.file = LOCATE_abstracttool;
+ fra.me.line = 0;
+ fra.me.meth = LOCATE_abstracttool___MMLocalClass___dump_properties;
+ fra.me.has_broke = 0;
+ 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.closure_ctx = closctx_param;
+ fra.me.closure_funs = CREG;
+ fra.me.REG[0] = p0;
+ CREG[0] = clos_fun0;
+ /* ./abstracttool.nit:125 */
+ fra.me.REG[0] = CALL_abstractmetamodel___MMLocalClass_____bra(closctx->REG[0])(closctx->REG[0], fra.me.REG[0]);
+ /* ./abstracttool.nit:126 */
+ REGB0 = TAG_Int(5);
+ fra.me.REG[1] = NEW_Array_array___Array___with_capacity(REGB0);
+ if (!once_value_6) {
+ fra.me.REG[2] = BOX_NativeString("\t");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_6 = fra.me.REG[2];
+ register_static_object(&once_value_6);
+ } else fra.me.REG[2] = once_value_6;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_string___Object___to_s(fra.me.REG[0])(fra.me.REG[0]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_7) {
+ fra.me.REG[2] = BOX_NativeString("");
+ REGB0 = TAG_Int(0);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_7 = fra.me.REG[2];
+ register_static_object(&once_value_7);
+ } else fra.me.REG[2] = once_value_7;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_static_type___MMLocalClass___get_type(closctx->REG[0])(closctx->REG[0]);
+ fra.me.REG[2] = CALL_static_type___MMLocalProperty___signature_for(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
+ fra.me.REG[2] = CALL_string___Object___to_s(fra.me.REG[2])(fra.me.REG[2]);
+ CALL_abstract_collection___SimpleCollection___add(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
+ if (!once_value_8) {
+ fra.me.REG[2] = BOX_NativeString("\n");
+ REGB0 = TAG_Int(1);
+ fra.me.REG[2] = NEW_String_string___String___with_native(fra.me.REG[2], REGB0);
+ once_value_8 = fra.me.REG[2];
+ register_static_object(&once_value_8);
+ } else fra.me.REG[2] = once_value_8;
+ fra.me.REG[2] = fra.me.REG[2];
+ CALL_abstract_collection___SimpleCollection___add(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]);
+ CALL_stream___OStream___write(closctx->REG[1])(closctx->REG[1], fra.me.REG[1]);
+ stack_frame_head = fra.me.prev;
+ return;
+ }