... as that doesn't make sense.
@item Init(@var{value})
The variable specified by the @code{Var} property should be statically
initialized to @var{value}. [...]
gcc/
* optc-gen.awk: Sanity check that 'Init' doesn't appear without
'Var'.
}
for (i = 0; i < n_opts; i++) {
name = var_name(flags[i]);
- if (name == "")
+ init = opt_args("Init", flags[i])
+
+ if (name == "") {
+ if (init != "")
+ print "#error " opts[i] " must specify Var to use Init"
continue;
+ }
- init = opt_args("Init", flags[i])
if (init != "") {
if (name in var_init && var_init[name] != init)
print "#error multiple initializers for " name