/*
- * Copyright (C) 1995-2007 University of Karlsruhe. All right reserved.
+ * Copyright (C) 1995-2008 University of Karlsruhe. All right reserved.
*
* This file is part of libFirm.
*
# include "config.h"
#endif
-#ifdef WITH_LIBCORE
+#include "firm_config.h"
#include "bitset.h"
#include <ctype.h>
-#include <libcore/lc_printf.h>
+#include "lc_printf.h"
#include "firm_common.h"
#include "irnode_t.h"
#include "entity_t.h"
const lc_arg_occ_t *occ, const lc_arg_value_t *arg)
{
int i;
- int amount = arg->v_int * (occ->width > 0 ? occ->width : 1);
+ int width = occ->width > 0 ? occ->width : 1;
+ int amount = arg->v_int * width;
for(i = 0; i < amount; ++i)
- lc_appendable_chadd(app, ' ');
+ lc_appendable_chadd(app, (i % width) == 0 ? '|' : ' ');
return amount;
}
lc_arg_env_t *firm_get_arg_env(void)
{
-#define X(name, letter) {"firm:" name, letter}
static lc_arg_env_t *env = NULL;
const char *name;
char letter;
} args[] = {
+#define X(name, letter) {"firm:" name, letter}
X("type", 't'),
X("entity", 'e'),
X("entity_ld", 'E'),
X("mode", 'm'),
X("block", 'B'),
X("cg_path", 'P'),
+#undef X
};
size_t i;
lc_arg_register(env, args[i].name, args[i].letter, &firm_handler);
lc_arg_register(env, "firm:ident", 'I', &ident_handler);
- lc_arg_register(env, "firm:indent", '>', &indent_handler);
+ lc_arg_register(env, "firm:indent", 'D', &indent_handler);
lc_arg_register(env, "firm:dbg_info", 'G', &debug_handler);
lc_arg_register(env, "firm:bitset", 'B', &bitset_handler);
lc_arg_register(env, "firm:pnc", '=', &pnc_handler);
return env;
}
-
-#endif /* WITH_LIBCORE */