The Lookup* functions should remain a private implementation detail of
the expr.c file.
Signed-off-by: Ran Benita <ran234@gmail.com>
return false;
}
-bool
+static bool
LookupModIndex(struct xkb_context *ctx, const void *priv, xkb_atom_t field,
enum expr_value_type type, xkb_mod_index_t *val_rtrn)
{
ExprDef **index_rtrn);
bool
-LookupModIndex(struct xkb_context *ctx, const void *priv, xkb_atom_t field,
- enum expr_value_type type, xkb_mod_index_t *val_rtrn);
-
-bool
ExprResolveModMask(struct xkb_context *ctx, const ExprDef *expr,
xkb_mod_mask_t *mask_rtrn);
bool ok;
struct xkb_context *ctx = info->keymap->ctx;
- if (!LookupModIndex(ctx, NULL, def->modifier, EXPR_TYPE_INT, &ndx)) {
+ ndx = ModNameToIndex(xkb_atom_text(ctx, def->modifier));
+ if (ndx == XKB_MOD_INVALID) {
log_err(info->keymap->ctx,
"Illegal modifier map definition; "
"Ignoring map for non-modifier \"%s\"\n",