1 /* This C file is generated by NIT to compile module symbol. */
2 #include "symbol._sep.h"
3 val_t
symbol___String___to_symbol(val_t self
) {
4 struct trace_t trace
= {NULL
, NULL
, 20, LOCATE_symbol___String___to_symbol
};
5 static val_t once_value_1
; static int once_bool_1
; /* Once value for variable[3]*/
7 void **closurevariable
= NULL
;
8 trace
.prev
= tracehead
; tracehead
= &trace
;
9 trace
.file
= LOCATE_symbol
;
11 if (once_bool_1
) variable
[3] = once_value_1
;
13 variable
[3] = NEW_HashMap_hash___HashMap___init(); /*new HashMap[String, Symbol]*/
14 once_value_1
= variable
[3];
17 variable
[2] = variable
[3];
18 variable
[3] = variable
[0];
19 variable
[3] = ((abstract_collection___CoupleMap___has_key_t
)CALL( variable
[2] /*symbol_dictionary*/,COLOR_abstract_collection___Map___has_key
))( variable
[2] /*symbol_dictionary*/, variable
[3]) /*CoupleMap::has_key*/;
20 if (UNTAG_Bool(variable
[3])) { /*if*/
21 variable
[3] = variable
[0];
22 variable
[3] = ((abstract_collection___CoupleMap_____bra_t
)CALL( variable
[2] /*symbol_dictionary*/,COLOR_abstract_collection___Map_____bra
))( variable
[2] /*symbol_dictionary*/, variable
[3]) /*CoupleMap::[]*/;
23 variable
[1] = variable
[3];
26 variable
[4] = variable
[0];
27 variable
[5] = NEW_Symbol_symbol___Symbol___init(variable
[4]); /*new Symbol*/
28 variable
[4] = variable
[5];
29 variable
[3] = variable
[4];
30 variable
[4] = variable
[0];
31 ((hash___HashMap_____braeq_t
)CALL( variable
[2] /*symbol_dictionary*/,COLOR_abstract_collection___Map_____braeq
))( variable
[2] /*symbol_dictionary*/, variable
[4], variable
[3] /*symbol*/) /*HashMap::[]=*/;
32 variable
[1] = variable
[3] /*symbol*/;
35 return_label0
: while(false);
36 tracehead
= trace
.prev
;
39 val_t
symbol___Symbol___to_s(val_t self
) {
40 struct trace_t trace
= {NULL
, NULL
, 37, LOCATE_symbol___Symbol___to_s
};
42 void **closurevariable
= NULL
;
43 trace
.prev
= tracehead
; tracehead
= &trace
;
44 trace
.file
= LOCATE_symbol
;
46 variable
[2] = variable
[0];
47 variable
[2] = ATTR_symbol___Symbol____string(variable
[2]) /*Symbol::_string*/;
48 variable
[2] = ((string___String___to_s_t
)CALL(variable
[2],COLOR_string___Object___to_s
))(variable
[2]) /*String::to_s*/;
49 variable
[1] = variable
[2];
51 return_label2
: while(false);
52 tracehead
= trace
.prev
;
55 void symbol___Symbol___init(val_t self
, val_t param0
, int* init_table
) {
56 struct trace_t trace
= {NULL
, NULL
, 39, LOCATE_symbol___Symbol___init
};
58 void **closurevariable
= NULL
;
59 trace
.prev
= tracehead
; tracehead
= &trace
;
60 trace
.file
= LOCATE_symbol
;
63 if (init_table
[VAL2OBJ( self
)->vft
[INIT_TABLE_POS_Symbol
].i
]) return;
64 variable
[3] = variable
[0];
65 ATTR_symbol___Symbol____string(variable
[3]) /*Symbol::_string*/ = variable
[1] /*s*/;
66 return_label3
: while(false);
67 init_table
[VAL2OBJ( self
)->vft
[INIT_TABLE_POS_Symbol
].i
] = 1;
68 tracehead
= trace
.prev
;