summaryrefslogtreecommitdiffhomepage
path: root/ir/libcore
diff options
context:
space:
mode:
authorChristoph Mallon <mallon@cs.uni-saarland.de>2015-07-14 07:30:00 +0200
committerChristoph Mallon <mallon@cs.uni-saarland.de>2015-07-14 07:30:25 +0200
commit2381fbcafebf898c12e325b0914fb8f279f914b3 (patch)
tree4946c5be91ae6af78d5efd41e5e1aafa5baa99e8 /ir/libcore
parent8d7337e4791179c2566cfc185ded9e8b05ead796 (diff)
Use typedefs for option callback/dump/value dump function declarations.
Diffstat (limited to 'ir/libcore')
-rw-r--r--ir/libcore/lc_opts.h6
-rw-r--r--ir/libcore/lc_opts_enum.h12
2 files changed, 9 insertions, 9 deletions
diff --git a/ir/libcore/lc_opts.h b/ir/libcore/lc_opts.h
index 0919ab7..60d04aa 100644
--- a/ir/libcore/lc_opts.h
+++ b/ir/libcore/lc_opts.h
@@ -122,11 +122,11 @@ lc_opt_entry_t *lc_opt_add_opt(lc_opt_entry_t *grp,
lc_opt_dump_t *dump,
lc_opt_dump_vals_t *dump_vals);
-bool lc_opt_std_cb(const char *name, lc_opt_type_t type, void *data, size_t length, ...);
+lc_opt_callback_t lc_opt_std_cb;
-int lc_opt_std_dump(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t length);
+lc_opt_dump_t lc_opt_std_dump;
-int lc_opt_bool_dump_vals(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t length);
+lc_opt_dump_vals_t lc_opt_bool_dump_vals;
/**
diff --git a/ir/libcore/lc_opts_enum.h b/ir/libcore/lc_opts_enum.h
index abc741e..5a94bd5 100644
--- a/ir/libcore/lc_opts_enum.h
+++ b/ir/libcore/lc_opts_enum.h
@@ -19,9 +19,9 @@ typedef struct { \
const lc_opt_enum_ ## N ## _items_t *items; \
} lc_opt_enum_ ## N ## _var_t; \
\
-bool lc_opt_enum_ ## N ## _cb(const char *name, lc_opt_type_t type, void *data, size_t len, ...); \
-int lc_opt_enum_ ## N ## _dump(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t len); \
-int lc_opt_enum_ ## N ## _dump_vals(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t len); \
+lc_opt_callback_t lc_opt_enum_ ## N ## _cb; \
+lc_opt_dump_t lc_opt_enum_ ## N ## _dump; \
+lc_opt_dump_vals_t lc_opt_enum_ ## N ## _dump_vals; \
#define _LC_OPT_ENT_ENUM(N, name, desc, var) \
_LC_OPT_ENT(name, desc, lc_opt_type_enum, lc_opt_enum_ ## N ## _var_t, var, 0, lc_opt_enum_ ## N ## _cb, lc_opt_enum_ ## N ## _dump, lc_opt_enum_ ## N ## _dump_vals)
@@ -48,8 +48,8 @@ typedef struct {
#define LC_OPT_ENT_ENUM_FUNC_PTR(name, desc, var) _LC_OPT_ENT_ENUM(func_ptr, name, desc, var)
-bool lc_opt_enum_func_ptr_cb(const char *name, lc_opt_type_t type, void *data, size_t len, ...);
-int lc_opt_enum_func_ptr_dump(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t len);
-int lc_opt_enum_func_ptr_dump_vals(char *buf, size_t n, const char *name, lc_opt_type_t type, void *data, size_t len);
+lc_opt_callback_t lc_opt_enum_func_ptr_cb;
+lc_opt_dump_t lc_opt_enum_func_ptr_dump;
+lc_opt_dump_vals_t lc_opt_enum_func_ptr_dump_vals;
#endif