}
static int
-HandleSymbolsVar(SymbolsInfo *info, VarDef *stmt)
+HandleGlobalVar(SymbolsInfo *info, VarDef *stmt)
{
const char *elem, *field;
ExprDef *arrayNdx;
for (; def; def = (VarDef *) def->common.next) {
if (def->name && def->name->op == EXPR_FIELD_REF) {
- ok = HandleSymbolsVar(info, def);
+ log_err(info->keymap->ctx,
+ "Cannot set a global default value from within a key statement; "
+ "Move statements to the global file scope\n");
continue;
}
ok = HandleSymbolsDef(info, (SymbolsDef *) stmt);
break;
case STMT_VAR:
- ok = HandleSymbolsVar(info, (VarDef *) stmt);
+ ok = HandleGlobalVar(info, (VarDef *) stmt);
break;
case STMT_VMOD:
ok = HandleVModDef((VModDef *) stmt, info->keymap, merge,