diff options
Diffstat (limited to 'src/decomp')
-rw-r--r-- | src/decomp/lang/java.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/decomp/lang/java.c b/src/decomp/lang/java.c index 7c5750b..e5ebdf9 100644 --- a/src/decomp/lang/java.c +++ b/src/decomp/lang/java.c @@ -346,18 +346,24 @@ static void g_java_output_write_comp_sign(GJavaOutput *output, GBufferLine *line static GBufferLine *g_java_output_start_class(GJavaOutput *output, GCodeBuffer *buffer, const GOpenidaType *type) { GBufferLine *result; /* Adresse nouvelle à remonter */ + char *name; /* Désignation humaine */ result = g_code_buffer_append_new_line_fixme(buffer); g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, "class", 5, RTT_KEY_WORD); g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, " ", 1, RTT_RAW); - /* TODO */ - g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, "XXX", 3, RTT_RAW); + name = _g_openida_type_to_string(type, true); + g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, name, strlen(name), RTT_RAW); + free(name); g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, " ", 1, RTT_RAW); g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, "{", 1, RTT_HOOK); + result = g_code_buffer_append_new_line_fixme(buffer); + + g_code_buffer_inc_indentation(buffer); + return result; } @@ -380,10 +386,14 @@ static void g_java_output_end_class(GJavaOutput *output, GCodeBuffer *buffer) { GBufferLine *result; /* Adresse nouvelle à remonter */ + g_code_buffer_dec_indentation(buffer); + result = g_code_buffer_append_new_line_fixme(buffer); g_buffer_line_insert_text(result, BLC_ASSEMBLY_HEAD, "}", 1, RTT_HOOK); + result = g_code_buffer_append_new_line_fixme(buffer); + return result; } |