Searched refs:math_state (Results 1 – 3 of 3) sorted by relevance
251 evaluate_string(arith_state_t *math_state, const char *expr);254 arith_lookup_val(arith_state_t *math_state, var_or_num_t *t) in arith_lookup_val() argument257 const char *p = math_state->lookupvar(t->var); in arith_lookup_val()265 for (cur = math_state->list_of_recursed_names; cur; cur = cur->next) { in arith_lookup_val()273 cur = math_state->list_of_recursed_names; in arith_lookup_val()276 math_state->list_of_recursed_names = &cur_save; in arith_lookup_val()279 t->val = evaluate_string(math_state, p); in arith_lookup_val()282 math_state->list_of_recursed_names = cur; in arith_lookup_val()284 return math_state->errmsg; in arith_lookup_val()296 arith_apply(arith_state_t *math_state, operator op, var_or_num_t *numstack, var_or_num_t **numstack… in arith_apply() argument[all …]
6453 arith_state_t math_state; in expand_and_evaluate_arith() local6457 math_state.lookupvar = get_local_var_value; in expand_and_evaluate_arith()6458 math_state.setvar = set_local_var_from_halves; in expand_and_evaluate_arith()6461 res = arith(&math_state, exp_str ? exp_str : arg); in expand_and_evaluate_arith()6464 *errmsg_p = math_state.errmsg; in expand_and_evaluate_arith()6465 if (math_state.errmsg) in expand_and_evaluate_arith()6466 msg_and_die_if_script(math_state.errmsg); in expand_and_evaluate_arith()
6022 arith_state_t math_state; in ash_arith() local6025 math_state.lookupvar = lookupvar; in ash_arith()6026 math_state.setvar = setvar0; in ash_arith()6030 result = arith(&math_state, s); in ash_arith()6031 if (math_state.errmsg) in ash_arith()6032 ash_msg_and_raise_error(math_state.errmsg); in ash_arith()