Lines Matching refs:param

30 param_init_type(struct param *param, struct arg_type_info *type, int own)  in param_init_type()  argument
32 param->flavor = PARAM_FLAVOR_TYPE; in param_init_type()
33 param->u.type.type = type; in param_init_type()
34 param->u.type.own_type = own; in param_init_type()
38 param_init_stop(struct param *param) in param_init_stop() argument
40 param->flavor = PARAM_FLAVOR_STOP; in param_init_stop()
44 param_init_pack(struct param *param, enum param_pack_flavor ppflavor, in param_init_pack() argument
56 param->flavor = PARAM_FLAVOR_PACK; in param_init_pack()
57 param->u.pack.args = args; in param_init_pack()
58 param->u.pack.nargs = nargs; in param_init_pack()
59 param->u.pack.own_args = own_args; in param_init_pack()
60 param->u.pack.ppflavor = ppflavor; in param_init_pack()
61 param->u.pack.init = init; in param_init_pack()
62 param->u.pack.next = next; in param_init_pack()
63 param->u.pack.stop = stop; in param_init_pack()
64 param->u.pack.done = done; in param_init_pack()
68 param_pack_init(struct param *param, struct value_dict *fargs) in param_pack_init() argument
70 struct value cb_args[param->u.pack.nargs]; in param_pack_init()
80 for (i = 0; i < param->u.pack.nargs; ++i) { in param_pack_init()
81 if (expr_eval(&param->u.pack.args[i], &void_val, in param_pack_init()
86 ret = param->u.pack.init(cb_args, param->u.pack.nargs, fargs); in param_pack_init()
95 param_pack_next(struct param *param, struct param_enum *context, in param_pack_next() argument
98 return param->u.pack.next(context, infop, insert_stop); in param_pack_next()
102 param_pack_stop(struct param *param, in param_pack_stop() argument
105 return param->u.pack.stop(context, value); in param_pack_stop()
109 param_pack_done(struct param *param, struct param_enum *context) in param_pack_done() argument
111 return param->u.pack.done(context); in param_pack_done()
115 param_destroy(struct param *param) in param_destroy() argument
117 if (param == NULL) in param_destroy()
120 switch (param->flavor) { in param_destroy()
122 if (param->u.type.own_type) { in param_destroy()
123 type_destroy(param->u.type.type); in param_destroy()
124 free(param->u.type.type); in param_destroy()
129 if (param->u.pack.own_args) { in param_destroy()
131 for (i = 0; i < param->u.pack.nargs; ++i) in param_destroy()
132 expr_destroy(&param->u.pack.args[i]); in param_destroy()
133 free(param->u.pack.args); in param_destroy()