template: Correct comment.
[libfirm] / ir / ir / irargs.c
index e3ea450..c0c49cd 100644 (file)
@@ -66,7 +66,6 @@ static int bitset_emit(lc_appendable_t *app,
 {
        int res = 2;
        bitset_t *b = (bitset_t*)arg->v_ptr;
-       size_t  p;
        char buf[32];
        const char *prefix = "";
 
@@ -118,12 +117,10 @@ static int firm_emit(lc_appendable_t *app,
 
        void *X = (void*)arg->v_ptr;
        firm_kind *obj = (firm_kind*)X;
-       size_t i, n;
        ir_node *block;
        char add[64];
        char buf[256];
        char tv_buf[256];
-       ir_entity *ent;
 
        buf[0] = '\0';
        add[0] = '\0';
@@ -225,24 +222,6 @@ static int firm_emit(lc_appendable_t *app,
                snprintf(buf, sizeof(buf), "%s%s", A("op"), get_op_name(op));
                break;
        }
-       case k_ir_compound_graph_path: {
-               compound_graph_path *path = (compound_graph_path*)X;
-               n = get_compound_graph_path_length(path);
-
-               for (i = 0; i < n; ++i) {
-                       ent = get_compound_graph_path_node(path, i);
-
-                       strncat(buf, ".", sizeof(buf)-1);
-                       strncat(buf, get_entity_name(ent), sizeof(buf)-1);
-                       if (is_Array_type(get_entity_owner(ent))) {
-                               snprintf(add, sizeof(add), "[%ld]",
-                                       get_compound_graph_path_array_index(path, i));
-                               strncat(buf, add, sizeof(buf)-1);
-                       }
-               }
-               add[0] = '\0';
-               break;
-       }
 
        default:
                snprintf(buf, sizeof(buf), "UNKWN");
@@ -250,7 +229,7 @@ static int firm_emit(lc_appendable_t *app,
        }
 
        if (occ->flag_plus)
-               strncat(buf, add, sizeof(buf)-1);
+               strncat(buf, add, sizeof(buf)-strlen(buf)-1);
 
        return lc_arg_append(app, occ, buf, strlen(buf));
 #undef A
@@ -290,7 +269,7 @@ static int firm_emit_indent(lc_appendable_t *app,
 static int firm_emit_pnc(lc_appendable_t *app,
     const lc_arg_occ_t *occ, const lc_arg_value_t *arg)
 {
-       int value = arg->v_int;
+       ir_relation value = (ir_relation)arg->v_int;
        const char *p = get_relation_string(value);
 
        return lc_arg_append(app, occ, p, strlen(p));
@@ -321,7 +300,6 @@ lc_arg_env_t *firm_get_arg_env(void)
                {"firm:irn_nr",    'N'},
                {"firm:mode",      'm'},
                {"firm:block",     'B'},
-               {"firm:cg_path",   'P'},
        };
 
        size_t i;