Jack Rosenthal would like Martin Roth and Patrick Georgi to review this change.

View Change

kconfig: allow for optional source with osource

Kconfiglib will error if files sourced do not exist, whereas the C
kconfig implementation will tolerate it.

Kconfiglib has a directive "osource" which is tolerant, like the C
implementation. For cases where we rely on it, I changed source to
osource. Then, I updated the C kconfig implementation to treat
"osource" just like "source". Note this is just temporary until we
get fully switched to kconfiglib.

Note to reviewers: the *.c_shipped files are machine generated by
gperf, flex, and bison, and aren't worth the human eyes for review.

Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I71fbcfc1807e7398da250ddf1e47f6530345e0b5
---
M src/Kconfig
M src/soc/intel/common/basecode/Kconfig
M util/kconfig/zconf.gperf
M util/kconfig/zconf.hash.c_shipped
M util/kconfig/zconf.lex.c_shipped
M util/kconfig/zconf.tab.c_shipped
6 files changed, 1,575 insertions(+), 1,631 deletions(-)

git pull ssh://review.coreboot.org:29418/coreboot refs/changes/77/48677/1
diff --git a/src/Kconfig b/src/Kconfig
index 33065cb..61f976e 100644
--- a/src/Kconfig
+++ b/src/Kconfig
@@ -489,7 +489,7 @@
endmenu

# load site-local kconfig to allow user specific defaults and overrides
-source "site-local/Kconfig"
+osource "site-local/Kconfig"

config SYSTEM_TYPE_LAPTOP
default n
diff --git a/src/soc/intel/common/basecode/Kconfig b/src/soc/intel/common/basecode/Kconfig
index 1c93244..1868a16 100644
--- a/src/soc/intel/common/basecode/Kconfig
+++ b/src/soc/intel/common/basecode/Kconfig
@@ -5,7 +5,7 @@

if SOC_INTEL_COMMON_BASECODE

-source "src/soc/intel/common/basecode/*/Kconfig"
-source "src/soc/intel/common/basecode/*/*/Kconfig"
+osource "src/soc/intel/common/basecode/*/Kconfig"
+osource "src/soc/intel/common/basecode/*/*/Kconfig"

endif
diff --git a/util/kconfig/zconf.gperf b/util/kconfig/zconf.gperf
index b6ac02d..5bde953 100644
--- a/util/kconfig/zconf.gperf
+++ b/util/kconfig/zconf.gperf
@@ -9,13 +9,14 @@

struct kconf_id;

-static const struct kconf_id *kconf_id_lookup(register const char *str, register unsigned int len);
+static const struct kconf_id *kconf_id_lookup(register const char *str, register size_t len);

%%
mainmenu, T_MAINMENU, TF_COMMAND
menu, T_MENU, TF_COMMAND
endmenu, T_ENDMENU, TF_COMMAND
source, T_SOURCE, TF_COMMAND
+osource, T_SOURCE, TF_COMMAND
choice, T_CHOICE, TF_COMMAND
endchoice, T_ENDCHOICE, TF_COMMAND
comment, T_COMMENT, TF_COMMAND
diff --git a/util/kconfig/zconf.hash.c_shipped b/util/kconfig/zconf.hash.c_shipped
index 7dc7159..8de67bf 100644
--- a/util/kconfig/zconf.hash.c_shipped
+++ b/util/kconfig/zconf.hash.c_shipped
@@ -1,5 +1,5 @@
-/* ANSI-C code produced by gperf version 3.0.4 */
-/* Command-line: gperf -t --output-file scripts/kconfig/zconf.hash.c_shipped -a -C -E -g -k '1,3,$' -p -t scripts/kconfig/zconf.gperf */
+/* ANSI-C code produced by gperf version 3.1 */
+/* Command-line: gperf -t --output-file zconf.hash.c_shipped -a -C -E -g -k '1,3,$' -p -t zconf.gperf */

#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \
&& ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \
@@ -25,14 +25,14 @@
&& ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \
&& ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126))
/* The character set is not based on ISO-646. */
-#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>."
+#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>."
#endif

-#line 10 "scripts/kconfig/zconf.gperf"
+#line 10 "zconf.gperf"
struct kconf_id;

-static const struct kconf_id *kconf_id_lookup(register const char *str, register unsigned int len);
-/* maximum key range = 71, duplicates = 0 */
+static const struct kconf_id *kconf_id_lookup(register const char *str, register size_t len);
+/* maximum key range = 60, duplicates = 0 */

#ifdef __GNUC__
__inline
@@ -42,38 +42,38 @@
#endif
#endif
static unsigned int
-kconf_id_hash (register const char *str, register unsigned int len)
+kconf_id_hash (register const char *str, register size_t len)
{
static const unsigned char asso_values[] =
{
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 5, 25, 25,
- 0, 0, 0, 5, 0, 0, 73, 73, 5, 0,
- 10, 5, 45, 73, 20, 20, 0, 15, 15, 73,
- 20, 5, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
- 73, 73, 73, 73, 73, 73
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 10, 20, 30,
+ 0, 0, 0, 5, 0, 0, 62, 62, 5, 0,
+ 15, 5, 20, 62, 25, 25, 0, 20, 10, 62,
+ 15, 10, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62, 62, 62, 62, 62,
+ 62, 62, 62, 62, 62, 62
};
- register int hval = len;
+ register unsigned int hval = len;

switch (hval)
{
@@ -99,30 +99,31 @@
char kconf_id_strings_str12[sizeof("def_tristate")];
char kconf_id_strings_str13[sizeof("def_bool")];
char kconf_id_strings_str14[sizeof("defconfig_list")];
- char kconf_id_strings_str17[sizeof("on")];
+ char kconf_id_strings_str17[sizeof("osource")];
char kconf_id_strings_str18[sizeof("optional")];
- char kconf_id_strings_str21[sizeof("option")];
- char kconf_id_strings_str22[sizeof("endmenu")];
- char kconf_id_strings_str23[sizeof("mainmenu")];
- char kconf_id_strings_str25[sizeof("menuconfig")];
- char kconf_id_strings_str27[sizeof("modules")];
- char kconf_id_strings_str28[sizeof("allnoconfig_y")];
- char kconf_id_strings_str29[sizeof("menu")];
- char kconf_id_strings_str31[sizeof("select")];
- char kconf_id_strings_str32[sizeof("comment")];
- char kconf_id_strings_str33[sizeof("env")];
- char kconf_id_strings_str35[sizeof("range")];
- char kconf_id_strings_str36[sizeof("choice")];
- char kconf_id_strings_str39[sizeof("bool")];
- char kconf_id_strings_str41[sizeof("source")];
+ char kconf_id_strings_str22[sizeof("on")];
+ char kconf_id_strings_str23[sizeof("env")];
+ char kconf_id_strings_str26[sizeof("option")];
+ char kconf_id_strings_str27[sizeof("endmenu")];
+ char kconf_id_strings_str28[sizeof("mainmenu")];
+ char kconf_id_strings_str29[sizeof("help")];
+ char kconf_id_strings_str30[sizeof("menuconfig")];
+ char kconf_id_strings_str31[sizeof("prompt")];
+ char kconf_id_strings_str32[sizeof("modules")];
+ char kconf_id_strings_str33[sizeof("hex")];
+ char kconf_id_strings_str34[sizeof("bool")];
+ char kconf_id_strings_str36[sizeof("select")];
+ char kconf_id_strings_str37[sizeof("comment")];
+ char kconf_id_strings_str38[sizeof("allnoconfig_y")];
+ char kconf_id_strings_str39[sizeof("menu")];
+ char kconf_id_strings_str41[sizeof("choice")];
char kconf_id_strings_str42[sizeof("visible")];
- char kconf_id_strings_str43[sizeof("hex")];
- char kconf_id_strings_str46[sizeof("config")];
+ char kconf_id_strings_str45[sizeof("range")];
char kconf_id_strings_str47[sizeof("boolean")];
- char kconf_id_strings_str51[sizeof("string")];
- char kconf_id_strings_str54[sizeof("help")];
- char kconf_id_strings_str56[sizeof("prompt")];
- char kconf_id_strings_str72[sizeof("depends")];
+ char kconf_id_strings_str51[sizeof("source")];
+ char kconf_id_strings_str52[sizeof("depends")];
+ char kconf_id_strings_str56[sizeof("config")];
+ char kconf_id_strings_str61[sizeof("string")];
};
static const struct kconf_id_strings_t kconf_id_strings_contents =
{
@@ -135,143 +136,136 @@
"def_tristate",
"def_bool",
"defconfig_list",
- "on",
+ "osource",
"optional",
+ "on",
+ "env",
"option",
"endmenu",
"mainmenu",
+ "help",
"menuconfig",
+ "prompt",
"modules",
- "allnoconfig_y",
- "menu",
+ "hex",
+ "bool",
"select",
"comment",
- "env",
- "range",
+ "allnoconfig_y",
+ "menu",
"choice",
- "bool",
- "source",
"visible",
- "hex",
- "config",
+ "range",
"boolean",
- "string",
- "help",
- "prompt",
- "depends"
+ "source",
+ "depends",
+ "config",
+ "string"
};
#define kconf_id_strings ((const char *) &kconf_id_strings_contents)
-#ifdef __GNUC__
-__inline
-#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__
-__attribute__ ((__gnu_inline__))
-#endif
-#endif
const struct kconf_id *
-kconf_id_lookup (register const char *str, register unsigned int len)
+kconf_id_lookup (register const char *str, register size_t len)
{
enum
{
- TOTAL_KEYWORDS = 33,
+ TOTAL_KEYWORDS = 34,
MIN_WORD_LENGTH = 2,
MAX_WORD_LENGTH = 14,
MIN_HASH_VALUE = 2,
- MAX_HASH_VALUE = 72
+ MAX_HASH_VALUE = 61
};

static const struct kconf_id wordlist[] =
{
{-1}, {-1},
-#line 25 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str2, T_IF, TF_COMMAND|TF_PARAM},
-#line 36 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str3, T_TYPE, TF_COMMAND, S_INT},
+#line 26 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str2, T_IF, TF_COMMAND|TF_PARAM},
+#line 37 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str3, T_TYPE, TF_COMMAND, S_INT},
{-1},
-#line 26 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str5, T_ENDIF, TF_COMMAND},
+#line 27 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str5, T_ENDIF, TF_COMMAND},
{-1},
-#line 29 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str7, T_DEFAULT, TF_COMMAND, S_UNKNOWN},
-#line 31 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str8, T_TYPE, TF_COMMAND, S_TRISTATE},
-#line 20 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str9, T_ENDCHOICE, TF_COMMAND},
+#line 30 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str7, T_DEFAULT, TF_COMMAND, S_UNKNOWN},
+#line 32 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str8, T_TYPE, TF_COMMAND, S_TRISTATE},
+#line 21 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str9, T_ENDCHOICE, TF_COMMAND},
{-1}, {-1},
-#line 32 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str12, T_DEFAULT, TF_COMMAND, S_TRISTATE},
-#line 35 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str13, T_DEFAULT, TF_COMMAND, S_BOOLEAN},
-#line 45 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str14, T_OPT_DEFCONFIG_LIST,TF_OPTION},
+#line 33 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str12, T_DEFAULT, TF_COMMAND, S_TRISTATE},
+#line 36 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str13, T_DEFAULT, TF_COMMAND, S_BOOLEAN},
+#line 46 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str14, T_OPT_DEFCONFIG_LIST,TF_OPTION},
{-1}, {-1},
-#line 43 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str17, T_ON, TF_PARAM},
-#line 28 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_OPTIONAL, TF_COMMAND},
- {-1}, {-1},
-#line 42 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str21, T_OPTION, TF_COMMAND},
-#line 17 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str22, T_ENDMENU, TF_COMMAND},
-#line 15 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str23, T_MAINMENU, TF_COMMAND},
- {-1},
-#line 23 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str25, T_MENUCONFIG, TF_COMMAND},
- {-1},
-#line 44 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str27, T_OPT_MODULES, TF_OPTION},
-#line 47 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str28, T_OPT_ALLNOCONFIG_Y,TF_OPTION},
-#line 16 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str29, T_MENU, TF_COMMAND},
- {-1},
-#line 39 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str31, T_SELECT, TF_COMMAND},
-#line 21 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str32, T_COMMENT, TF_COMMAND},
-#line 46 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str33, T_OPT_ENV, TF_OPTION},
- {-1},
-#line 40 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str35, T_RANGE, TF_COMMAND},
-#line 19 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_CHOICE, TF_COMMAND},
- {-1}, {-1},
-#line 33 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str39, T_TYPE, TF_COMMAND, S_BOOLEAN},
- {-1},
-#line 18 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str41, T_SOURCE, TF_COMMAND},
-#line 41 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str42, T_VISIBLE, TF_COMMAND},
-#line 37 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str43, T_TYPE, TF_COMMAND, S_HEX},
- {-1}, {-1},
-#line 22 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str46, T_CONFIG, TF_COMMAND},
-#line 34 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str47, T_TYPE, TF_COMMAND, S_BOOLEAN},
+#line 19 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str17, T_SOURCE, TF_COMMAND},
+#line 29 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_OPTIONAL, TF_COMMAND},
{-1}, {-1}, {-1},
-#line 38 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str51, T_TYPE, TF_COMMAND, S_STRING},
+#line 44 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str22, T_ON, TF_PARAM},
+#line 47 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str23, T_OPT_ENV, TF_OPTION},
{-1}, {-1},
-#line 24 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str54, T_HELP, TF_COMMAND},
+#line 43 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str26, T_OPTION, TF_COMMAND},
+#line 17 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str27, T_ENDMENU, TF_COMMAND},
+#line 15 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str28, T_MAINMENU, TF_COMMAND},
+#line 25 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str29, T_HELP, TF_COMMAND},
+#line 24 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str30, T_MENUCONFIG, TF_COMMAND},
+#line 31 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str31, T_PROMPT, TF_COMMAND},
+#line 45 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str32, T_OPT_MODULES, TF_OPTION},
+#line 38 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str33, T_TYPE, TF_COMMAND, S_HEX},
+#line 34 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str34, T_TYPE, TF_COMMAND, S_BOOLEAN},
{-1},
-#line 30 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str56, T_PROMPT, TF_COMMAND},
- {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1},
- {-1}, {-1}, {-1}, {-1}, {-1}, {-1},
-#line 27 "scripts/kconfig/zconf.gperf"
- {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str72, T_DEPENDS, TF_COMMAND}
+#line 40 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_SELECT, TF_COMMAND},
+#line 22 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str37, T_COMMENT, TF_COMMAND},
+#line 48 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str38, T_OPT_ALLNOCONFIG_Y,TF_OPTION},
+#line 16 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str39, T_MENU, TF_COMMAND},
+ {-1},
+#line 20 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str41, T_CHOICE, TF_COMMAND},
+#line 42 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str42, T_VISIBLE, TF_COMMAND},
+ {-1}, {-1},
+#line 41 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str45, T_RANGE, TF_COMMAND},
+ {-1},
+#line 35 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str47, T_TYPE, TF_COMMAND, S_BOOLEAN},
+ {-1}, {-1}, {-1},
+#line 18 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str51, T_SOURCE, TF_COMMAND},
+#line 28 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str52, T_DEPENDS, TF_COMMAND},
+ {-1}, {-1}, {-1},
+#line 23 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str56, T_CONFIG, TF_COMMAND},
+ {-1}, {-1}, {-1}, {-1},
+#line 39 "zconf.gperf"
+ {(int)(size_t)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str61, T_TYPE, TF_COMMAND, S_STRING}
};

if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH)
{
- register int key = kconf_id_hash (str, len);
+ register unsigned int key = kconf_id_hash (str, len);

- if (key <= MAX_HASH_VALUE && key >= 0)
+ if (key <= MAX_HASH_VALUE)
{
register int o = wordlist[key].name;
if (o >= 0)
@@ -285,4 +279,5 @@
}
return 0;
}
-#line 48 "scripts/kconfig/zconf.gperf"
+#line 49 "zconf.gperf"
+
diff --git a/util/kconfig/zconf.lex.c_shipped b/util/kconfig/zconf.lex.c_shipped
index 4133f71..7b5789c 100644
--- a/util/kconfig/zconf.lex.c_shipped
+++ b/util/kconfig/zconf.lex.c_shipped
@@ -1,17 +1,21 @@

-#line 3 "/home/patrick/Source/coreboot/util/kconfig/zconf.lex.c"
-
#define YY_INT_ALIGNED short int

/* A lexical scanner generated by flex */

#define yy_create_buffer zconf_create_buffer
#define yy_delete_buffer zconf_delete_buffer
-#define yy_flex_debug zconf_flex_debug
+#define yy_scan_buffer zconf_scan_buffer
+#define yy_scan_string zconf_scan_string
+#define yy_scan_bytes zconf_scan_bytes
#define yy_init_buffer zconf_init_buffer
#define yy_flush_buffer zconf_flush_buffer
#define yy_load_buffer_state zconf_load_buffer_state
#define yy_switch_to_buffer zconf_switch_to_buffer
+#define yypush_buffer_state zconfpush_buffer_state
+#define yypop_buffer_state zconfpop_buffer_state
+#define yyensure_buffer_stack zconfensure_buffer_stack
+#define yy_flex_debug zconf_flex_debug
#define yyin zconfin
#define yyleng zconfleng
#define yylex zconflex
@@ -26,12 +30,246 @@

#define FLEX_SCANNER
#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 5
-#define YY_FLEX_SUBMINOR_VERSION 39
+#define YY_FLEX_MINOR_VERSION 6
+#define YY_FLEX_SUBMINOR_VERSION 4
#if YY_FLEX_SUBMINOR_VERSION > 0
#define FLEX_BETA
#endif

+#ifdef yy_create_buffer
+#define zconf_create_buffer_ALREADY_DEFINED
+#else
+#define yy_create_buffer zconf_create_buffer
+#endif
+
+#ifdef yy_delete_buffer
+#define zconf_delete_buffer_ALREADY_DEFINED
+#else
+#define yy_delete_buffer zconf_delete_buffer
+#endif
+
+#ifdef yy_scan_buffer
+#define zconf_scan_buffer_ALREADY_DEFINED
+#else
+#define yy_scan_buffer zconf_scan_buffer
+#endif
+
+#ifdef yy_scan_string
+#define zconf_scan_string_ALREADY_DEFINED
+#else
+#define yy_scan_string zconf_scan_string
+#endif
+
+#ifdef yy_scan_bytes
+#define zconf_scan_bytes_ALREADY_DEFINED
+#else
+#define yy_scan_bytes zconf_scan_bytes
+#endif
+
+#ifdef yy_init_buffer
+#define zconf_init_buffer_ALREADY_DEFINED
+#else
+#define yy_init_buffer zconf_init_buffer
+#endif
+
+#ifdef yy_flush_buffer
+#define zconf_flush_buffer_ALREADY_DEFINED
+#else
+#define yy_flush_buffer zconf_flush_buffer
+#endif
+
+#ifdef yy_load_buffer_state
+#define zconf_load_buffer_state_ALREADY_DEFINED
+#else
+#define yy_load_buffer_state zconf_load_buffer_state
+#endif
+
+#ifdef yy_switch_to_buffer
+#define zconf_switch_to_buffer_ALREADY_DEFINED
+#else
+#define yy_switch_to_buffer zconf_switch_to_buffer
+#endif
+
+#ifdef yypush_buffer_state
+#define zconfpush_buffer_state_ALREADY_DEFINED
+#else
+#define yypush_buffer_state zconfpush_buffer_state
+#endif
+
+#ifdef yypop_buffer_state
+#define zconfpop_buffer_state_ALREADY_DEFINED
+#else
+#define yypop_buffer_state zconfpop_buffer_state
+#endif
+
+#ifdef yyensure_buffer_stack
+#define zconfensure_buffer_stack_ALREADY_DEFINED
+#else
+#define yyensure_buffer_stack zconfensure_buffer_stack
+#endif
+
+#ifdef yylex
+#define zconflex_ALREADY_DEFINED
+#else
+#define yylex zconflex
+#endif
+
+#ifdef yyrestart
+#define zconfrestart_ALREADY_DEFINED
+#else
+#define yyrestart zconfrestart
+#endif
+
+#ifdef yylex_init
+#define zconflex_init_ALREADY_DEFINED
+#else
+#define yylex_init zconflex_init
+#endif
+
+#ifdef yylex_init_extra
+#define zconflex_init_extra_ALREADY_DEFINED
+#else
+#define yylex_init_extra zconflex_init_extra
+#endif
+
+#ifdef yylex_destroy
+#define zconflex_destroy_ALREADY_DEFINED
+#else
+#define yylex_destroy zconflex_destroy
+#endif
+
+#ifdef yyget_debug
+#define zconfget_debug_ALREADY_DEFINED
+#else
+#define yyget_debug zconfget_debug
+#endif
+
+#ifdef yyset_debug
+#define zconfset_debug_ALREADY_DEFINED
+#else
+#define yyset_debug zconfset_debug
+#endif
+
+#ifdef yyget_extra
+#define zconfget_extra_ALREADY_DEFINED
+#else
+#define yyget_extra zconfget_extra
+#endif
+
+#ifdef yyset_extra
+#define zconfset_extra_ALREADY_DEFINED
+#else
+#define yyset_extra zconfset_extra
+#endif
+
+#ifdef yyget_in
+#define zconfget_in_ALREADY_DEFINED
+#else
+#define yyget_in zconfget_in
+#endif
+
+#ifdef yyset_in
+#define zconfset_in_ALREADY_DEFINED
+#else
+#define yyset_in zconfset_in
+#endif
+
+#ifdef yyget_out
+#define zconfget_out_ALREADY_DEFINED
+#else
+#define yyget_out zconfget_out
+#endif
+
+#ifdef yyset_out
+#define zconfset_out_ALREADY_DEFINED
+#else
+#define yyset_out zconfset_out
+#endif
+
+#ifdef yyget_leng
+#define zconfget_leng_ALREADY_DEFINED
+#else
+#define yyget_leng zconfget_leng
+#endif
+
+#ifdef yyget_text
+#define zconfget_text_ALREADY_DEFINED
+#else
+#define yyget_text zconfget_text
+#endif
+
+#ifdef yyget_lineno
+#define zconfget_lineno_ALREADY_DEFINED
+#else
+#define yyget_lineno zconfget_lineno
+#endif
+
+#ifdef yyset_lineno
+#define zconfset_lineno_ALREADY_DEFINED
+#else
+#define yyset_lineno zconfset_lineno
+#endif
+
+#ifdef yywrap
+#define zconfwrap_ALREADY_DEFINED
+#else
+#define yywrap zconfwrap
+#endif
+
+#ifdef yyalloc
+#define zconfalloc_ALREADY_DEFINED
+#else
+#define yyalloc zconfalloc
+#endif
+
+#ifdef yyrealloc
+#define zconfrealloc_ALREADY_DEFINED
+#else
+#define yyrealloc zconfrealloc
+#endif
+
+#ifdef yyfree
+#define zconffree_ALREADY_DEFINED
+#else
+#define yyfree zconffree
+#endif
+
+#ifdef yytext
+#define zconftext_ALREADY_DEFINED
+#else
+#define yytext zconftext
+#endif
+
+#ifdef yyleng
+#define zconfleng_ALREADY_DEFINED
+#else
+#define yyleng zconfleng
+#endif
+
+#ifdef yyin
+#define zconfin_ALREADY_DEFINED
+#else
+#define yyin zconfin
+#endif
+
+#ifdef yyout
+#define zconfout_ALREADY_DEFINED
+#else
+#define yyout zconfout
+#endif
+
+#ifdef yy_flex_debug
+#define zconf_flex_debug_ALREADY_DEFINED
+#else
+#define yy_flex_debug zconf_flex_debug
+#endif
+
+#ifdef yylineno
+#define zconflineno_ALREADY_DEFINED
+#else
+#define yylineno zconflineno
+#endif
+
/* First, we deal with platform-specific or compiler-specific issues. */

/* begin standard C headers. */
@@ -102,60 +340,48 @@
#define UINT32_MAX (4294967295U)
#endif

+#ifndef SIZE_MAX
+#define SIZE_MAX (~(size_t)0)
+#endif
+
#endif /* ! C99 */

#endif /* ! FLEXINT_H */

-#ifdef __cplusplus
+/* begin standard C++ headers. */

-/* The "const" storage-class-modifier is valid. */
-#define YY_USE_CONST
-
-#else /* ! __cplusplus */
-
-/* C99 requires __STDC__ to be defined as 1. */
-#if defined (__STDC__)
-
-#define YY_USE_CONST
-
-#endif /* defined (__STDC__) */
-#endif /* ! __cplusplus */
-
-#ifdef YY_USE_CONST
+/* TODO: this is always defined, so inline it */
#define yyconst const
+
+#if defined(__GNUC__) && __GNUC__ >= 3
+#define yynoreturn __attribute__((__noreturn__))
#else
-#define yyconst
+#define yynoreturn
#endif

/* Returned upon end-of-file. */
#define YY_NULL 0

-/* Promotes a possibly negative, possibly signed char to an unsigned
- * integer for use as an array index. If the signed char is negative,
- * we want to instead treat it as an 8-bit unsigned char, hence the
- * double cast.
+/* Promotes a possibly negative, possibly signed char to an
+ * integer in range [0..255] for use as an array index.
*/
-#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
+#define YY_SC_TO_UI(c) ((YY_CHAR) (c))

/* Enter a start condition. This macro really ought to take a parameter,
* but we do it the disgusting crufty way forced on us by the ()-less
* definition of BEGIN.
*/
#define BEGIN (yy_start) = 1 + 2 *
-
/* Translate the current start state into a value that can be later handed
* to BEGIN to return to the state. The YYSTATE alias is for lex
* compatibility.
*/
#define YY_START (((yy_start) - 1) / 2)
#define YYSTATE YY_START
-
/* Action number for EOF rule of a given start state. */
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-
/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE zconfrestart(zconfin )
-
+#define YY_NEW_FILE yyrestart( yyin )
#define YY_END_OF_BUFFER_CHAR 0

/* Size of default input buffer. */
@@ -185,14 +411,14 @@
typedef size_t yy_size_t;
#endif

-extern yy_size_t zconfleng;
+extern int yyleng;

-extern FILE *zconfin, *zconfout;
+extern FILE *yyin, *yyout;

#define EOB_ACT_CONTINUE_SCAN 0
#define EOB_ACT_END_OF_FILE 1
#define EOB_ACT_LAST_MATCH 2
-
+
#define YY_LESS_LINENO(n)
#define YY_LINENO_REWIND_TO(ptr)

@@ -200,16 +426,15 @@
#define yyless(n) \
do \
{ \
- /* Undo effects of setting up zconftext. */ \
+ /* Undo effects of setting up yytext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
*yy_cp = (yy_hold_char); \
YY_RESTORE_YY_MORE_OFFSET \
(yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
- YY_DO_BEFORE_ACTION; /* set up zconftext again */ \
+ YY_DO_BEFORE_ACTION; /* set up yytext again */ \
} \
while ( 0 )
-
#define unput(c) yyunput( c, (yytext_ptr) )

#ifndef YY_STRUCT_YY_BUFFER_STATE
@@ -224,12 +449,12 @@
/* Size of input buffer in bytes, not including room for EOB
* characters.
*/
- yy_size_t yy_buf_size;
+ int yy_buf_size;

/* Number of characters read into yy_ch_buf, not including EOB
* characters.
*/
- yy_size_t yy_n_chars;
+ int yy_n_chars;

/* Whether we "own" the buffer - i.e., we know we created it,
* and can realloc() it to grow it, and should free() it to
@@ -252,7 +477,7 @@

int yy_bs_lineno; /**< The line count. */
int yy_bs_column; /**< The column count. */
-
+
/* Whether to try to fill the input buffer when we reach the
* end of it.
*/
@@ -269,8 +494,8 @@
* possible backing-up.
*
* When we actually see the EOF, we change the status to "new"
- * (via zconfrestart()), so that the user can continue scanning by
- * just pointing zconfin at a new input file.
+ * (via yyrestart()), so that the user can continue scanning by
+ * just pointing yyin at a new input file.
*/
#define YY_BUFFER_EOF_PENDING 2

@@ -280,7 +505,7 @@
/* Stack of input buffers. */
static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */
static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */
-static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */
+static YY_BUFFER_STATE * yy_buffer_stack = NULL; /**< Stack as an array. */

/* We provide macros for accessing buffer states in case in the
* future we want to put the buffer states in a more general
@@ -291,92 +516,88 @@
#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \
? (yy_buffer_stack)[(yy_buffer_stack_top)] \
: NULL)
-
/* Same as previous macro, but useful when we know that the buffer stack is not
* NULL or when we need an lvalue. For internal use only.
*/
#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)]

-/* yy_hold_char holds the character lost when zconftext is formed. */
+/* yy_hold_char holds the character lost when yytext is formed. */
static char yy_hold_char;
-static yy_size_t yy_n_chars; /* number of characters read into yy_ch_buf */
-yy_size_t zconfleng;
+static int yy_n_chars; /* number of characters read into yy_ch_buf */
+int yyleng;

/* Points to current character in buffer. */
-static char *yy_c_buf_p = (char *) 0;
+static char *yy_c_buf_p = NULL;
static int yy_init = 0; /* whether we need to initialize */
static int yy_start = 0; /* start state number */

-/* Flag which is used to allow zconfwrap()'s to do buffer switches
- * instead of setting up a fresh zconfin. A bit of a hack ...
+/* Flag which is used to allow yywrap()'s to do buffer switches
+ * instead of setting up a fresh yyin. A bit of a hack ...
*/
static int yy_did_buffer_switch_on_eof;

-void zconfrestart (FILE *input_file );
-void zconf_switch_to_buffer (YY_BUFFER_STATE new_buffer );
-YY_BUFFER_STATE zconf_create_buffer (FILE *file,int size );
-void zconf_delete_buffer (YY_BUFFER_STATE b );
-void zconf_flush_buffer (YY_BUFFER_STATE b );
-void zconfpush_buffer_state (YY_BUFFER_STATE new_buffer );
-void zconfpop_buffer_state (void );
+void yyrestart ( FILE *input_file );
+void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer );
+YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size );
+void yy_delete_buffer ( YY_BUFFER_STATE b );
+void yy_flush_buffer ( YY_BUFFER_STATE b );
+void yypush_buffer_state ( YY_BUFFER_STATE new_buffer );
+void yypop_buffer_state ( void );

-static void zconfensure_buffer_stack (void );
-static void zconf_load_buffer_state (void );
-static void zconf_init_buffer (YY_BUFFER_STATE b,FILE *file );
+static void yyensure_buffer_stack ( void );
+static void yy_load_buffer_state ( void );
+static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file );
+#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER )

-#define YY_FLUSH_BUFFER zconf_flush_buffer(YY_CURRENT_BUFFER )
+YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size );
+YY_BUFFER_STATE yy_scan_string ( const char *yy_str );
+YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len );

-YY_BUFFER_STATE zconf_scan_buffer (char *base,yy_size_t size );
-YY_BUFFER_STATE zconf_scan_string (yyconst char *yy_str );
-YY_BUFFER_STATE zconf_scan_bytes (yyconst char *bytes,yy_size_t len );
+void *yyalloc ( yy_size_t );
+void *yyrealloc ( void *, yy_size_t );
+void yyfree ( void * );

-void *zconfalloc (yy_size_t );
-void *zconfrealloc (void *,yy_size_t );
-void zconffree (void * );
-
-#define yy_new_buffer zconf_create_buffer
-
+#define yy_new_buffer yy_create_buffer
#define yy_set_interactive(is_interactive) \
{ \
if ( ! YY_CURRENT_BUFFER ){ \
- zconfensure_buffer_stack (); \
+ yyensure_buffer_stack (); \
YY_CURRENT_BUFFER_LVALUE = \
- zconf_create_buffer(zconfin,YY_BUF_SIZE ); \
+ yy_create_buffer( yyin, YY_BUF_SIZE ); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
}
-
#define yy_set_bol(at_bol) \
{ \
if ( ! YY_CURRENT_BUFFER ){\
- zconfensure_buffer_stack (); \
+ yyensure_buffer_stack (); \
YY_CURRENT_BUFFER_LVALUE = \
- zconf_create_buffer(zconfin,YY_BUF_SIZE ); \
+ yy_create_buffer( yyin, YY_BUF_SIZE ); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
}
-
#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)

/* Begin user sect3 */

-#define zconfwrap() 1
+#define zconfwrap() (/*CONSTCOND*/1)
#define YY_SKIP_YYWRAP
+typedef flex_uint8_t YY_CHAR;

-typedef unsigned char YY_CHAR;
-
-FILE *zconfin = (FILE *) 0, *zconfout = (FILE *) 0;
+FILE *yyin = NULL, *yyout = NULL;

typedef int yy_state_type;

-extern int zconflineno;
+extern int yylineno;
+int yylineno = 1;

-int zconflineno = 1;
+extern char *yytext;
+#ifdef yytext_ptr
+#undef yytext_ptr
+#endif
+#define yytext_ptr yytext

-extern char *zconftext;
-#define yytext_ptr zconftext
-
-static yyconst flex_int16_t yy_nxt[][17] =
+static const flex_int16_t yy_nxt[][17] =
{
{
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -697,21 +918,20 @@

} ;

-static yy_state_type yy_get_previous_state (void );
-static yy_state_type yy_try_NUL_trans (yy_state_type current_state );
-static int yy_get_next_buffer (void );
-static void yy_fatal_error (yyconst char msg[] );
+static yy_state_type yy_get_previous_state ( void );
+static yy_state_type yy_try_NUL_trans ( yy_state_type current_state );
+static int yy_get_next_buffer ( void );
+static void yynoreturn yy_fatal_error ( const char* msg );

/* Done after the current pattern has been matched and before the
- * corresponding action - sets up zconftext.
+ * corresponding action - sets up yytext.
*/
#define YY_DO_BEFORE_ACTION \
(yytext_ptr) = yy_bp; \
- zconfleng = (size_t) (yy_cp - yy_bp); \
+ yyleng = (int) (yy_cp - yy_bp); \
(yy_hold_char) = *yy_cp; \
*yy_cp = '\0'; \
(yy_c_buf_p) = yy_cp;
-
#define YY_NUM_RULES 33
#define YY_END_OF_BUFFER 34
/* This struct is not used in this scanner,
@@ -721,7 +941,7 @@
flex_int32_t yy_verify;
flex_int32_t yy_nxt;
};
-static yyconst flex_int16_t yy_accept[61] =
+static const flex_int16_t yy_accept[61] =
{ 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
34, 5, 4, 2, 3, 7, 8, 6, 32, 29,
@@ -731,7 +951,7 @@
26, 25, 15, 20, 9, 19, 19, 21, 10, 18
} ;

-static yyconst flex_int32_t yy_ec[256] =
+static const YY_CHAR yy_ec[256] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -763,8 +983,8 @@
1, 1, 1, 1, 1
} ;

-extern int zconf_flex_debug;
-int zconf_flex_debug = 0;
+extern int yy_flex_debug;
+int yy_flex_debug = 0;

/* The intent behind this definition is that it'll catch
* any uses of REJECT which flex missed.
@@ -773,7 +993,7 @@
#define yymore() yymore_used_but_not_detected
#define YY_MORE_ADJ 0
#define YY_RESTORE_YY_MORE_OFFSET
-char *zconftext;
+char *yytext;
#define YY_NO_INPUT 1

/*
@@ -859,36 +1079,36 @@
#define YY_EXTRA_TYPE void *
#endif

-static int yy_init_globals (void );
+static int yy_init_globals ( void );

/* Accessor methods to globals.
These are made visible to non-reentrant scanners for convenience. */

-int zconflex_destroy (void );
+int yylex_destroy ( void );

-int zconfget_debug (void );
+int yyget_debug ( void );

-void zconfset_debug (int debug_flag );
+void yyset_debug ( int debug_flag );

-YY_EXTRA_TYPE zconfget_extra (void );
+YY_EXTRA_TYPE yyget_extra ( void );

-void zconfset_extra (YY_EXTRA_TYPE user_defined );
+void yyset_extra ( YY_EXTRA_TYPE user_defined );

-FILE *zconfget_in (void );
+FILE *yyget_in ( void );

-void zconfset_in (FILE * in_str );
+void yyset_in ( FILE * _in_str );

-FILE *zconfget_out (void );
+FILE *yyget_out ( void );

-void zconfset_out (FILE * out_str );
+void yyset_out ( FILE * _out_str );

-yy_size_t zconfget_leng (void );
+ int yyget_leng ( void );

-char *zconfget_text (void );
+char *yyget_text ( void );

-int zconfget_lineno (void );
+int yyget_lineno ( void );

-void zconfset_lineno (int line_number );
+void yyset_lineno ( int _line_number );

/* Macros after this point can all be overridden by user definitions in
* section 1.
@@ -896,28 +1116,31 @@

#ifndef YY_SKIP_YYWRAP
#ifdef __cplusplus
-extern "C" int zconfwrap (void );
+extern "C" int yywrap ( void );
#else
-extern int zconfwrap (void );
+extern int yywrap ( void );
#endif
#endif

- static void yyunput (int c,char *buf_ptr );
+#ifndef YY_NO_UNPUT

+ static void yyunput ( int c, char *buf_ptr );
+
+#endif
+
#ifndef yytext_ptr
-static void yy_flex_strncpy (char *,yyconst char *,int );
+static void yy_flex_strncpy ( char *, const char *, int );
#endif

#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen (yyconst char * );
+static int yy_flex_strlen ( const char * );
#endif

#ifndef YY_NO_INPUT
-
#ifdef __cplusplus
-static int yyinput (void );
+static int yyinput ( void );
#else
-static int input (void );
+static int input ( void );
#endif

#endif
@@ -937,7 +1160,7 @@
/* This used to be an fputs(), but since the string might contain NUL's,
* we now use fwrite().
*/
-#define ECHO do { if (fwrite( zconftext, zconfleng, 1, zconfout )) {} } while (0)
+#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
#endif

/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
@@ -946,7 +1169,7 @@
#ifndef YY_INPUT
#define YY_INPUT(buf,result,max_size) \
errno=0; \
- while ( (result = read( fileno(zconfin), (char *) buf, max_size )) < 0 ) \
+ while ( (result = (int) read( fileno(yyin), buf, (yy_size_t) max_size )) < 0 ) \
{ \
if( errno != EINTR) \
{ \
@@ -954,7 +1177,7 @@
break; \
} \
errno=0; \
- clearerr(zconfin); \
+ clearerr(yyin); \
}\
\

@@ -986,12 +1209,12 @@
#ifndef YY_DECL
#define YY_DECL_IS_OURS 1

-extern int zconflex (void);
+extern int yylex (void);

-#define YY_DECL int zconflex (void)
+#define YY_DECL int yylex (void)
#endif /* !YY_DECL */

-/* Code executed at the beginning of each rule, after zconftext and zconfleng
+/* Code executed at the beginning of each rule, after yytext and yyleng
* have been set up.
*/
#ifndef YY_USER_ACTION
@@ -1000,7 +1223,7 @@

/* Code executed at the end of each rule. */
#ifndef YY_BREAK
-#define YY_BREAK break;
+#define YY_BREAK /*LINTED*/break;
#endif

#define YY_RULE_SETUP \
@@ -1010,9 +1233,9 @@
*/
YY_DECL
{
- register yy_state_type yy_current_state;
- register char *yy_cp, *yy_bp;
- register int yy_act;
+ yy_state_type yy_current_state;
+ char *yy_cp, *yy_bp;
+ int yy_act;

if ( !(yy_init) )
{
@@ -1025,19 +1248,19 @@
if ( ! (yy_start) )
(yy_start) = 1; /* first start state */

- if ( ! zconfin )
- zconfin = stdin;
+ if ( ! yyin )
+ yyin = stdin;

- if ( ! zconfout )
- zconfout = stdout;
+ if ( ! yyout )
+ yyout = stdout;

if ( ! YY_CURRENT_BUFFER ) {
- zconfensure_buffer_stack ();
+ yyensure_buffer_stack ();
YY_CURRENT_BUFFER_LVALUE =
- zconf_create_buffer(zconfin,YY_BUF_SIZE );
+ yy_create_buffer( yyin, YY_BUF_SIZE );
}

- zconf_load_buffer_state( );
+ yy_load_buffer_state( );
}

{
@@ -1045,11 +1268,11 @@
int str = 0;
int ts, i;

- while ( 1 ) /* loops until end-of-file is reached */
+ while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */
{
yy_cp = (yy_c_buf_p);

- /* Support of zconftext. */
+ /* Support of yytext. */
*yy_cp = (yy_hold_char);

/* yy_bp points to the position in yy_ch_buf of the start of
@@ -1096,7 +1319,7 @@
case 5:
YY_RULE_SETUP
{
- unput(zconftext[0]);
+ unput(yytext[0]);
BEGIN(COMMAND);
}
YY_BREAK
@@ -1104,7 +1327,7 @@
case 6:
YY_RULE_SETUP
{
- const struct kconf_id *id = kconf_id_lookup(zconftext, zconfleng);
+ const struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
BEGIN(PARAM);
current_pos.file = current_file;
current_pos.lineno = current_file->lineno;
@@ -1112,7 +1335,7 @@
zconflval.id = id;
return id->token;
}
- alloc_string(zconftext, zconfleng);
+ alloc_string(yytext, yyleng);
zconflval.string = text;
return T_WORD;
}
@@ -1162,7 +1385,7 @@
case 16:
YY_RULE_SETUP
{
- str = zconftext[0];
+ str = yytext[0];
new_string();
BEGIN(STRING);
}
@@ -1179,12 +1402,12 @@
case 19:
YY_RULE_SETUP
{
- const struct kconf_id *id = kconf_id_lookup(zconftext, zconfleng);
+ const struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
if (id && id->flags & TF_PARAM) {
zconflval.id = id;
return id->token;
}
- alloc_string(zconftext, zconfleng);
+ alloc_string(yytext, yyleng);
zconflval.string = text;
return T_WORD;
}
@@ -1210,13 +1433,13 @@

case 23:
/* rule 23 can match eol */
-*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
+*yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
YY_LINENO_REWIND_TO(yy_cp - 1);
(yy_c_buf_p) = yy_cp -= 1;
-YY_DO_BEFORE_ACTION; /* set up zconftext again */
+YY_DO_BEFORE_ACTION; /* set up yytext again */
YY_RULE_SETUP
{
- append_string(zconftext, zconfleng);
+ append_string(yytext, yyleng);
zconflval.string = text;
return T_WORD_QUOTE;
}
@@ -1224,18 +1447,18 @@
case 24:
YY_RULE_SETUP
{
- append_string(zconftext, zconfleng);
+ append_string(yytext, yyleng);
}
YY_BREAK
case 25:
/* rule 25 can match eol */
-*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
+*yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
YY_LINENO_REWIND_TO(yy_cp - 1);
(yy_c_buf_p) = yy_cp -= 1;
-YY_DO_BEFORE_ACTION; /* set up zconftext again */
+YY_DO_BEFORE_ACTION; /* set up yytext again */
YY_RULE_SETUP
{
- append_string(zconftext + 1, zconfleng - 1);
+ append_string(yytext + 1, yyleng - 1);
zconflval.string = text;
return T_WORD_QUOTE;
}
@@ -1243,18 +1466,18 @@
case 26:
YY_RULE_SETUP
{
- append_string(zconftext + 1, zconfleng - 1);
+ append_string(yytext + 1, yyleng - 1);
}
YY_BREAK
case 27:
YY_RULE_SETUP
{
- if (str == zconftext[0]) {
+ if (str == yytext[0]) {
BEGIN(PARAM);
zconflval.string = text;
return T_WORD_QUOTE;
} else
- append_string(zconftext, 1);
+ append_string(yytext, 1);
}
YY_BREAK
case 28:
@@ -1277,8 +1500,8 @@
YY_RULE_SETUP
{
ts = 0;
- for (i = 0; i < zconfleng; i++) {
- if (zconftext[i] == '\t')
+ for (i = 0; i < yyleng; i++) {
+ if (yytext[i] == '\t')
ts = (ts & ~7) + 8;
else
ts++;
@@ -1300,10 +1523,10 @@
YY_BREAK
case 30:
/* rule 30 can match eol */
-*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
+*yy_cp = (yy_hold_char); /* undo effects of setting up yytext */
YY_LINENO_REWIND_TO(yy_cp - 1);
(yy_c_buf_p) = yy_cp -= 1;
-YY_DO_BEFORE_ACTION; /* set up zconftext again */
+YY_DO_BEFORE_ACTION; /* set up yytext again */
YY_RULE_SETUP
{
current_file->lineno++;
@@ -1322,12 +1545,12 @@
case 32:
YY_RULE_SETUP
{
- while (zconfleng) {
- if ((zconftext[zconfleng-1] != ' ') && (zconftext[zconfleng-1] != '\t'))
+ while (yyleng) {
+ if ((yytext[yyleng-1] != ' ') && (yytext[yyleng-1] != '\t'))
break;
- zconfleng--;
+ yyleng--;
}
- append_string(zconftext, zconfleng);
+ append_string(yytext, yyleng);
if (!first_ts)
first_ts = last_ts;
}
@@ -1346,7 +1569,7 @@
zconf_endfile();
return T_EOL;
}
- fclose(zconfin);
+ fclose(yyin);
yyterminate();
}
YY_BREAK
@@ -1368,15 +1591,15 @@
{
/* We're scanning a new file or input source. It's
* possible that this happened because the user
- * just pointed zconfin at a new source and called
- * zconflex(). If so, then we have to assure
+ * just pointed yyin at a new source and called
+ * yylex(). If so, then we have to assure
* consistency between YY_CURRENT_BUFFER and our
* globals. Here is the right place to do so, because
* this is the first action (other than possibly a
* back-up) that will match for the new input source.
*/
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
- YY_CURRENT_BUFFER_LVALUE->yy_input_file = zconfin;
+ YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
}

@@ -1429,11 +1652,11 @@
{
(yy_did_buffer_switch_on_eof) = 0;

- if ( zconfwrap( ) )
+ if ( yywrap( ) )
{
/* Note: because we've taken care in
* yy_get_next_buffer() to have set up
- * zconftext, we can now set up
+ * yytext, we can now set up
* yy_c_buf_p so that if some total
* hoser (like flex itself) wants to
* call the scanner after we return the
@@ -1483,7 +1706,7 @@
} /* end of action switch */
} /* end of scanning one token */
} /* end of user's declarations */
-} /* end of zconflex */
+} /* end of yylex */

/* yy_get_next_buffer - try to read in a new buffer
*
@@ -1494,9 +1717,9 @@
*/
static int yy_get_next_buffer (void)
{
- register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
- register char *source = (yytext_ptr);
- register int number_to_move, i;
+ char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
+ char *source = (yytext_ptr);
+ int number_to_move, i;
int ret_val;

if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
@@ -1525,7 +1748,7 @@
/* Try to read more data. */

/* First move last chars to start of buffer. */
- number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;
+ number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr) - 1);

for ( i = 0; i < number_to_move; ++i )
*(dest++) = *(source++);
@@ -1538,7 +1761,7 @@

else
{
- yy_size_t num_to_read =
+ int num_to_read =
YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;

while ( num_to_read <= 0 )
@@ -1552,7 +1775,7 @@

if ( b->yy_is_our_buffer )
{
- yy_size_t new_size = b->yy_buf_size * 2;
+ int new_size = b->yy_buf_size * 2;

if ( new_size <= 0 )
b->yy_buf_size += b->yy_buf_size / 8;
@@ -1561,11 +1784,12 @@

b->yy_ch_buf = (char *)
/* Include room in for 2 EOB chars. */
- zconfrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 );
+ yyrealloc( (void *) b->yy_ch_buf,
+ (yy_size_t) (b->yy_buf_size + 2) );
}
else
/* Can't grow it, we don't own it. */
- b->yy_ch_buf = 0;
+ b->yy_ch_buf = NULL;

if ( ! b->yy_ch_buf )
YY_FATAL_ERROR(
@@ -1593,7 +1817,7 @@
if ( number_to_move == YY_MORE_ADJ )
{
ret_val = EOB_ACT_END_OF_FILE;
- zconfrestart(zconfin );
+ yyrestart( yyin );
}

else
@@ -1607,12 +1831,15 @@
else
ret_val = EOB_ACT_CONTINUE_SCAN;

- if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
+ if (((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
/* Extend the array by 50%, plus the number we really need. */
- yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) zconfrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size );
+ int new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
+ (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size );
if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
+ /* "- 2" to take care of EOB's */
+ YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
}

(yy_n_chars) += number_to_move;
@@ -1628,8 +1855,8 @@

static yy_state_type yy_get_previous_state (void)
{
- register yy_state_type yy_current_state;
- register char *yy_cp;
+ yy_state_type yy_current_state;
+ char *yy_cp;

yy_current_state = (yy_start);

@@ -1648,7 +1875,7 @@
*/
static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
{
- register int yy_is_jam;
+ int yy_is_jam;

yy_current_state = yy_nxt[yy_current_state][1];
yy_is_jam = (yy_current_state <= 0);
@@ -1656,22 +1883,24 @@
return yy_is_jam ? 0 : yy_current_state;
}

- static void yyunput (int c, register char * yy_bp )
+#ifndef YY_NO_UNPUT
+
+ static void yyunput (int c, char * yy_bp )
{
- register char *yy_cp;
+ char *yy_cp;

yy_cp = (yy_c_buf_p);

- /* undo effects of setting up zconftext */
+ /* undo effects of setting up yytext */
*yy_cp = (yy_hold_char);

if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
{ /* need to shift things up to make room */
/* +2 for EOB chars. */
- register yy_size_t number_to_move = (yy_n_chars) + 2;
- register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
+ int number_to_move = (yy_n_chars) + 2;
+ char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
- register char *source =
+ char *source =
&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];

while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
@@ -1680,7 +1909,7 @@
yy_cp += (int) (dest - source);
yy_bp += (int) (dest - source);
YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
- (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
+ (yy_n_chars) = (int) YY_CURRENT_BUFFER_LVALUE->yy_buf_size;

if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
YY_FATAL_ERROR( "flex scanner push-back overflow" );
@@ -1693,6 +1922,8 @@
(yy_c_buf_p) = yy_cp;
}

+#endif
+
#ifndef YY_NO_INPUT
#ifdef __cplusplus
static int yyinput (void)
@@ -1717,7 +1948,7 @@

else
{ /* need more input */
- yy_size_t offset = (yy_c_buf_p) - (yytext_ptr);
+ int offset = (int) ((yy_c_buf_p) - (yytext_ptr));
++(yy_c_buf_p);

switch ( yy_get_next_buffer( ) )
@@ -1734,14 +1965,14 @@
*/

/* Reset buffer status. */
- zconfrestart(zconfin );
+ yyrestart( yyin );

/*FALLTHROUGH*/

case EOB_ACT_END_OF_FILE:
{
- if ( zconfwrap( ) )
- return EOF;
+ if ( yywrap( ) )
+ return 0;

if ( ! (yy_did_buffer_switch_on_eof) )
YY_NEW_FILE;
@@ -1760,7 +1991,7 @@
}

c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */
- *(yy_c_buf_p) = '\0'; /* preserve zconftext */
+ *(yy_c_buf_p) = '\0'; /* preserve yytext */
(yy_hold_char) = *++(yy_c_buf_p);

return c;
@@ -1772,32 +2003,32 @@
*
* @note This function does not reset the start condition to @c INITIAL .
*/
- void zconfrestart (FILE * input_file )
+ void yyrestart (FILE * input_file )
{

if ( ! YY_CURRENT_BUFFER ){
- zconfensure_buffer_stack ();
+ yyensure_buffer_stack ();
YY_CURRENT_BUFFER_LVALUE =
- zconf_create_buffer(zconfin,YY_BUF_SIZE );
+ yy_create_buffer( yyin, YY_BUF_SIZE );
}

- zconf_init_buffer(YY_CURRENT_BUFFER,input_file );
- zconf_load_buffer_state( );
+ yy_init_buffer( YY_CURRENT_BUFFER, input_file );
+ yy_load_buffer_state( );
}

/** Switch to a different input buffer.
* @param new_buffer The new input buffer.
*
*/
- void zconf_switch_to_buffer (YY_BUFFER_STATE new_buffer )
+ void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer )
{

/* TODO. We should be able to replace this entire function body
* with
- * zconfpop_buffer_state();
- * zconfpush_buffer_state(new_buffer);
+ * yypop_buffer_state();
+ * yypush_buffer_state(new_buffer);
*/
- zconfensure_buffer_stack ();
+ yyensure_buffer_stack ();
if ( YY_CURRENT_BUFFER == new_buffer )
return;

@@ -1810,21 +2041,21 @@
}

YY_CURRENT_BUFFER_LVALUE = new_buffer;
- zconf_load_buffer_state( );
+ yy_load_buffer_state( );

/* We don't actually know whether we did this switch during
- * EOF (zconfwrap()) processing, but the only time this flag
- * is looked at is after zconfwrap() is called, so it's safe
+ * EOF (yywrap()) processing, but the only time this flag
+ * is looked at is after yywrap() is called, so it's safe
* to go ahead and always set it.
*/
(yy_did_buffer_switch_on_eof) = 1;
}

-static void zconf_load_buffer_state (void)
+static void yy_load_buffer_state (void)
{
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
(yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
- zconfin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
+ yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
(yy_hold_char) = *(yy_c_buf_p);
}

@@ -1834,35 +2065,35 @@
*
* @return the allocated buffer state.
*/
- YY_BUFFER_STATE zconf_create_buffer (FILE * file, int size )
+ YY_BUFFER_STATE yy_create_buffer (FILE * file, int size )
{
YY_BUFFER_STATE b;

- b = (YY_BUFFER_STATE) zconfalloc(sizeof( struct yy_buffer_state ) );
+ b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) );
if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in zconf_create_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

b->yy_buf_size = size;

/* yy_ch_buf has to be 2 characters longer than the size given because
* we need to put in 2 end-of-buffer characters.
*/
- b->yy_ch_buf = (char *) zconfalloc(b->yy_buf_size + 2 );
+ b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) );
if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in zconf_create_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );

b->yy_is_our_buffer = 1;

- zconf_init_buffer(b,file );
+ yy_init_buffer( b, file );

return b;
}

/** Destroy the buffer.
- * @param b a buffer created with zconf_create_buffer()
+ * @param b a buffer created with yy_create_buffer()
*
*/
- void zconf_delete_buffer (YY_BUFFER_STATE b )
+ void yy_delete_buffer (YY_BUFFER_STATE b )
{

if ( ! b )
@@ -1872,27 +2103,27 @@
YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;

if ( b->yy_is_our_buffer )
- zconffree((void *) b->yy_ch_buf );
+ yyfree( (void *) b->yy_ch_buf );

- zconffree((void *) b );
+ yyfree( (void *) b );
}

/* Initializes or reinitializes a buffer.
* This function is sometimes called more than once on the same buffer,
- * such as during a zconfrestart() or at EOF.
+ * such as during a yyrestart() or at EOF.
*/
- static void zconf_init_buffer (YY_BUFFER_STATE b, FILE * file )
+ static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file )

{
int oerrno = errno;

- zconf_flush_buffer(b );
+ yy_flush_buffer( b );

b->yy_input_file = file;
b->yy_fill_buffer = 1;

- /* If b is the current buffer, then zconf_init_buffer was _probably_
- * called from zconfrestart() or through yy_get_next_buffer.
+ /* If b is the current buffer, then yy_init_buffer was _probably_
+ * called from yyrestart() or through yy_get_next_buffer.
* In that case, we don't want to reset the lineno or column.
*/
if (b != YY_CURRENT_BUFFER){
@@ -1909,7 +2140,7 @@
* @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
*
*/
- void zconf_flush_buffer (YY_BUFFER_STATE b )
+ void yy_flush_buffer (YY_BUFFER_STATE b )
{
if ( ! b )
return;
@@ -1929,7 +2160,7 @@
b->yy_buffer_status = YY_BUFFER_NEW;

if ( b == YY_CURRENT_BUFFER )
- zconf_load_buffer_state( );
+ yy_load_buffer_state( );
}

/** Pushes the new state onto the stack. The new state becomes
@@ -1938,14 +2169,14 @@
* @param new_buffer The new state.
*
*/
-void zconfpush_buffer_state (YY_BUFFER_STATE new_buffer )
+void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
{
if (new_buffer == NULL)
return;

- zconfensure_buffer_stack();
+ yyensure_buffer_stack();

- /* This block is copied from zconf_switch_to_buffer. */
+ /* This block is copied from yy_switch_to_buffer. */
if ( YY_CURRENT_BUFFER )
{
/* Flush out information for old buffer. */
@@ -1959,8 +2190,8 @@
(yy_buffer_stack_top)++;
YY_CURRENT_BUFFER_LVALUE = new_buffer;

- /* copied from zconf_switch_to_buffer. */
- zconf_load_buffer_state( );
+ /* copied from yy_switch_to_buffer. */
+ yy_load_buffer_state( );
(yy_did_buffer_switch_on_eof) = 1;
}

@@ -1968,18 +2199,18 @@
* The next element becomes the new top.
*
*/
-void zconfpop_buffer_state (void)
+void yypop_buffer_state (void)
{
if (!YY_CURRENT_BUFFER)
return;

- zconf_delete_buffer(YY_CURRENT_BUFFER );
+ yy_delete_buffer(YY_CURRENT_BUFFER );
YY_CURRENT_BUFFER_LVALUE = NULL;
if ((yy_buffer_stack_top) > 0)
--(yy_buffer_stack_top);

if (YY_CURRENT_BUFFER) {
- zconf_load_buffer_state( );
+ yy_load_buffer_state( );
(yy_did_buffer_switch_on_eof) = 1;
}
}
@@ -1987,7 +2218,7 @@
/* Allocates the stack if it does not exist.
* Guarantees space for at least one push.
*/
-static void zconfensure_buffer_stack (void)
+static void yyensure_buffer_stack (void)
{
yy_size_t num_to_alloc;

@@ -1997,15 +2228,15 @@
* scanner will even need a stack. We use 2 instead of 1 to avoid an
* immediate realloc on the next call.
*/
- num_to_alloc = 1;
- (yy_buffer_stack) = (struct yy_buffer_state**)zconfalloc
+ num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
+ (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
(num_to_alloc * sizeof(struct yy_buffer_state*)
);
if ( ! (yy_buffer_stack) )
- YY_FATAL_ERROR( "out of dynamic memory in zconfensure_buffer_stack()" );
-
+ YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
+
memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
-
+
(yy_buffer_stack_max) = num_to_alloc;
(yy_buffer_stack_top) = 0;
return;
@@ -2014,15 +2245,15 @@
if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){

/* Increase the buffer to prepare for a possible push. */
- int grow_size = 8 /* arbitrary grow size */;
+ yy_size_t grow_size = 8 /* arbitrary grow size */;

num_to_alloc = (yy_buffer_stack_max) + grow_size;
- (yy_buffer_stack) = (struct yy_buffer_state**)zconfrealloc
+ (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc
((yy_buffer_stack),
num_to_alloc * sizeof(struct yy_buffer_state*)
);
if ( ! (yy_buffer_stack) )
- YY_FATAL_ERROR( "out of dynamic memory in zconfensure_buffer_stack()" );
+ YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );

/* zero only the new slots.*/
memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
@@ -2034,9 +2265,9 @@
* @param base the character buffer
* @param size the size in bytes of the character buffer
*
- * @return the newly allocated buffer state object.
+ * @return the newly allocated buffer state object.
*/
-YY_BUFFER_STATE zconf_scan_buffer (char * base, yy_size_t size )
+YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size )
{
YY_BUFFER_STATE b;

@@ -2044,69 +2275,69 @@
base[size-2] != YY_END_OF_BUFFER_CHAR ||
base[size-1] != YY_END_OF_BUFFER_CHAR )
/* They forgot to leave room for the EOB's. */
- return 0;
+ return NULL;

- b = (YY_BUFFER_STATE) zconfalloc(sizeof( struct yy_buffer_state ) );
+ b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) );
if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in zconf_scan_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );

- b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
+ b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */
b->yy_buf_pos = b->yy_ch_buf = base;
b->yy_is_our_buffer = 0;
- b->yy_input_file = 0;
+ b->yy_input_file = NULL;
b->yy_n_chars = b->yy_buf_size;
b->yy_is_interactive = 0;
b->yy_at_bol = 1;
b->yy_fill_buffer = 0;
b->yy_buffer_status = YY_BUFFER_NEW;

- zconf_switch_to_buffer(b );
+ yy_switch_to_buffer( b );

return b;
}

-/** Setup the input buffer state to scan a string. The next call to zconflex() will
+/** Setup the input buffer state to scan a string. The next call to yylex() will
* scan from a @e copy of @a str.
* @param yystr a NUL-terminated string to scan
*
* @return the newly allocated buffer state object.
* @note If you want to scan bytes that may contain NUL values, then use
- * zconf_scan_bytes() instead.
+ * yy_scan_bytes() instead.
*/
-YY_BUFFER_STATE zconf_scan_string (yyconst char * yystr )
+YY_BUFFER_STATE yy_scan_string (const char * yystr )
{

- return zconf_scan_bytes(yystr,strlen(yystr) );
+ return yy_scan_bytes( yystr, (int) strlen(yystr) );
}

-/** Setup the input buffer state to scan the given bytes. The next call to zconflex() will
+/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
* scan from a @e copy of @a bytes.
* @param yybytes the byte buffer to scan
* @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
*
* @return the newly allocated buffer state object.
*/
-YY_BUFFER_STATE zconf_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len )
+YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len )
{
YY_BUFFER_STATE b;
char *buf;
yy_size_t n;
- yy_size_t i;
+ int i;

/* Get memory for full buffer, including space for trailing EOB's. */
- n = _yybytes_len + 2;
- buf = (char *) zconfalloc(n );
+ n = (yy_size_t) (_yybytes_len + 2);
+ buf = (char *) yyalloc( n );
if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in zconf_scan_bytes()" );
+ YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );

for ( i = 0; i < _yybytes_len; ++i )
buf[i] = yybytes[i];

buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;

- b = zconf_scan_buffer(buf,n );
+ b = yy_scan_buffer( buf, n );
if ( ! b )
- YY_FATAL_ERROR( "bad buffer in zconf_scan_bytes()" );
+ YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );

/* It's okay to grow etc. this buffer, and we should throw it
* away when we're done.
@@ -2120,9 +2351,9 @@
#define YY_EXIT_FAILURE 2
#endif

-static void yy_fatal_error (yyconst char* msg )
+static void yynoreturn yy_fatal_error (const char* msg )
{
- (void) fprintf( stderr, "%s\n", msg );
+ fprintf( stderr, "%s\n", msg );
exit( YY_EXIT_FAILURE );
}

@@ -2132,14 +2363,14 @@
#define yyless(n) \
do \
{ \
- /* Undo effects of setting up zconftext. */ \
+ /* Undo effects of setting up yytext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
- zconftext[zconfleng] = (yy_hold_char); \
- (yy_c_buf_p) = zconftext + yyless_macro_arg; \
+ yytext[yyleng] = (yy_hold_char); \
+ (yy_c_buf_p) = yytext + yyless_macro_arg; \
(yy_hold_char) = *(yy_c_buf_p); \
*(yy_c_buf_p) = '\0'; \
- zconfleng = yyless_macro_arg; \
+ yyleng = yyless_macro_arg; \
} \
while ( 0 )

@@ -2148,126 +2379,126 @@
/** Get the current line number.
*
*/
-int zconfget_lineno (void)
+int yyget_lineno (void)
{
-
- return zconflineno;
+
+ return yylineno;
}

/** Get the input stream.
*
*/
-FILE *zconfget_in (void)
+FILE *yyget_in (void)
{
- return zconfin;
+ return yyin;
}

/** Get the output stream.
*
*/
-FILE *zconfget_out (void)
+FILE *yyget_out (void)
{
- return zconfout;
+ return yyout;
}

/** Get the length of the current token.
*
*/
-yy_size_t zconfget_leng (void)
+int yyget_leng (void)
{
- return zconfleng;
+ return yyleng;
}

/** Get the current token.
*
*/

-char *zconfget_text (void)
+char *yyget_text (void)
{
- return zconftext;
+ return yytext;
}

/** Set the current line number.
- * @param line_number
+ * @param _line_number line number
*
*/
-void zconfset_lineno (int line_number )
+void yyset_lineno (int _line_number )
{

- zconflineno = line_number;
+ yylineno = _line_number;
}

/** Set the input stream. This does not discard the current
* input buffer.
- * @param in_str A readable stream.
+ * @param _in_str A readable stream.
*
- * @see zconf_switch_to_buffer
+ * @see yy_switch_to_buffer
*/
-void zconfset_in (FILE * in_str )
+void yyset_in (FILE * _in_str )
{
- zconfin = in_str ;
+ yyin = _in_str ;
}

-void zconfset_out (FILE * out_str )
+void yyset_out (FILE * _out_str )
{
- zconfout = out_str ;
+ yyout = _out_str ;
}

-int zconfget_debug (void)
+int yyget_debug (void)
{
- return zconf_flex_debug;
+ return yy_flex_debug;
}

-void zconfset_debug (int bdebug )
+void yyset_debug (int _bdebug )
{
- zconf_flex_debug = bdebug ;
+ yy_flex_debug = _bdebug ;
}

static int yy_init_globals (void)
{
/* Initialization is the same as for the non-reentrant scanner.
- * This function is called from zconflex_destroy(), so don't allocate here.
+ * This function is called from yylex_destroy(), so don't allocate here.
*/

- (yy_buffer_stack) = 0;
+ (yy_buffer_stack) = NULL;
(yy_buffer_stack_top) = 0;
(yy_buffer_stack_max) = 0;
- (yy_c_buf_p) = (char *) 0;
+ (yy_c_buf_p) = NULL;
(yy_init) = 0;
(yy_start) = 0;

/* Defined in main.c */
#ifdef YY_STDINIT
- zconfin = stdin;
- zconfout = stdout;
+ yyin = stdin;
+ yyout = stdout;
#else
- zconfin = (FILE *) 0;
- zconfout = (FILE *) 0;
+ yyin = NULL;
+ yyout = NULL;
#endif

/* For future reference: Set errno on error, since we are called by
- * zconflex_init()
+ * yylex_init()
*/
return 0;
}

-/* zconflex_destroy is for both reentrant and non-reentrant scanners. */
-int zconflex_destroy (void)
+/* yylex_destroy is for both reentrant and non-reentrant scanners. */
+int yylex_destroy (void)
{

/* Pop the buffer stack, destroying each element. */
while(YY_CURRENT_BUFFER){
- zconf_delete_buffer(YY_CURRENT_BUFFER );
+ yy_delete_buffer( YY_CURRENT_BUFFER );
YY_CURRENT_BUFFER_LVALUE = NULL;
- zconfpop_buffer_state();
+ yypop_buffer_state();
}

/* Destroy the stack itself. */
- zconffree((yy_buffer_stack) );
+ yyfree((yy_buffer_stack) );
(yy_buffer_stack) = NULL;

/* Reset the globals. This is important in a non-reentrant scanner so the next time
- * zconflex() is called, initialization will occur. */
+ * yylex() is called, initialization will occur. */
yy_init_globals( );

return 0;
@@ -2278,18 +2509,19 @@
*/

#ifndef yytext_ptr
-static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
+static void yy_flex_strncpy (char* s1, const char * s2, int n )
{
- register int i;
+
+ int i;
for ( i = 0; i < n; ++i )
s1[i] = s2[i];
}
#endif

#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen (yyconst char * s )
+static int yy_flex_strlen (const char * s )
{
- register int n;
+ int n;
for ( n = 0; s[n]; ++n )
;

@@ -2297,13 +2529,14 @@
}
#endif

-void *zconfalloc (yy_size_t size )
+void *yyalloc (yy_size_t size )
{
- return (void *) malloc( size );
+ return malloc(size);
}

-void *zconfrealloc (void * ptr, yy_size_t size )
+void *yyrealloc (void * ptr, yy_size_t size )
{
+
/* The cast to (char *) in the following accommodates both
* implementations that use char* generic pointers, and those
* that use void* generic pointers. It works with the latter
@@ -2311,12 +2544,12 @@
* any pointer type to void*, and deal with argument conversions
* as though doing an assignment.
*/
- return (void *) realloc( (char *) ptr, size );
+ return realloc(ptr, size);
}

-void zconffree (void * ptr )
+void yyfree (void * ptr )
{
- free( (char *) ptr ); /* see zconfrealloc() for (char *) cast */
+ free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
}

#define YYTABLES_NAME "yytables"
@@ -2361,8 +2594,8 @@

void zconf_initscan(const char *name)
{
- zconfin = zconf_fopen(name);
- if (!zconfin) {
+ yyin = zconf_fopen(name);
+ if (!yyin) {
printf("can't find file %s\n", name);
exit(1);
}
@@ -2382,13 +2615,13 @@
memset(buf, 0, sizeof(*buf));

current_buf->state = YY_CURRENT_BUFFER;
- zconfin = zconf_fopen(file->name);
- if (!zconfin) {
+ yyin = zconf_fopen(file->name);
+ if (!yyin) {
printf("%s:%d: can't open file \"%s\"\n",
zconf_curname(), zconf_lineno(), file->name);
exit(1);
}
- zconf_switch_to_buffer(zconf_create_buffer(zconfin,YY_BUF_SIZE));
+ yy_switch_to_buffer(yy_create_buffer(yyin, YY_BUF_SIZE));
buf->parent = current_buf;
current_buf = buf;

@@ -2450,9 +2683,9 @@

parent = current_buf->parent;
if (parent) {
- fclose(zconfin);
- zconf_delete_buffer(YY_CURRENT_BUFFER);
- zconf_switch_to_buffer(parent->state);
+ fclose(yyin);
+ yy_delete_buffer(YY_CURRENT_BUFFER);
+ yy_switch_to_buffer(parent->state);
}
free(current_buf);
current_buf = parent;
@@ -2467,3 +2700,4 @@
{
return current_pos.file ? current_pos.file->name : "<none>";
}
+
diff --git a/util/kconfig/zconf.tab.c_shipped b/util/kconfig/zconf.tab.c_shipped
index 069a71b..6c0818b 100644
--- a/util/kconfig/zconf.tab.c_shipped
+++ b/util/kconfig/zconf.tab.c_shipped
@@ -1,19 +1,20 @@
-/* A Bison parser, made by GNU Bison 2.7. */
+/* A Bison parser, made by GNU Bison 3.7.3. */

/* Bison implementation for Yacc-like parsers in C
-
- Copyright (C) 1984, 1989-1990, 2000-2012 Free Software Foundation, Inc.
-
+
+ Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2020 Free Software Foundation,
+ Inc.
+
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */

@@ -26,13 +27,17 @@
special exception, which will cause the skeleton and the resulting
Bison output files to be licensed under the GNU General Public
License without this special exception.
-
+
This special exception was added by the Free Software Foundation in
version 2.2 of Bison. */

/* C LALR(1) parser skeleton written by Richard Stallman, by
simplifying the original so-called "semantic" parser. */

+/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual,
+ especially those whose name start with YY_ or yy_. They are
+ private implementation details that can be changed or removed. */
+
/* All symbols defined below should begin with yy or YY, to avoid
infringing on user name space. This should be done even for local
variables, as they might otherwise be expanded by user macros.
@@ -44,7 +49,7 @@
#define YYBISON 1

/* Bison version. */
-#define YYBISON_VERSION "2.7"
+#define YYBISON_VERSION "3.7.3"

/* Skeleton name. */
#define YYSKELETON_NAME "yacc.c"
@@ -63,13 +68,12 @@
#define yyparse zconfparse
#define yylex zconflex
#define yyerror zconferror
-#define yylval zconflval
-#define yychar zconfchar
#define yydebug zconfdebug
#define yynerrs zconfnerrs
+#define yylval zconflval
+#define yychar zconfchar

-/* Copy the first part of user declarations. */
-
+/* First part of user prologue. */

/*
* Copyright (C) 2002 Roman Zippel <zippel@linux-m68k.org>
@@ -104,25 +108,29 @@



-
-# ifndef YY_NULL
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULL nullptr
+# ifndef YY_CAST
+# ifdef __cplusplus
+# define YY_CAST(Type, Val) static_cast<Type> (Val)
+# define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val)
# else
-# define YY_NULL 0
+# define YY_CAST(Type, Val) ((Type) (Val))
+# define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
+# endif
+# endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
# endif
# endif

-/* Enabling verbose error messages. */
-#ifdef YYERROR_VERBOSE
-# undef YYERROR_VERBOSE
-# define YYERROR_VERBOSE 1
-#else
-# define YYERROR_VERBOSE 0
-#endif

-
-/* Enabling traces. */
+/* Debug traces. */
#ifndef YYDEBUG
# define YYDEBUG 1
#endif
@@ -130,54 +138,57 @@
extern int zconfdebug;
#endif

-/* Tokens. */
+/* Token kinds. */
#ifndef YYTOKENTYPE
# define YYTOKENTYPE
- /* Put the tokens into the symbol table, so that GDB and other debuggers
- know about them. */
- enum yytokentype {
- T_MAINMENU = 258,
- T_MENU = 259,
- T_ENDMENU = 260,
- T_SOURCE = 261,
- T_CHOICE = 262,
- T_ENDCHOICE = 263,
- T_COMMENT = 264,
- T_CONFIG = 265,
- T_MENUCONFIG = 266,
- T_HELP = 267,
- T_HELPTEXT = 268,
- T_IF = 269,
- T_ENDIF = 270,
- T_DEPENDS = 271,
- T_OPTIONAL = 272,
- T_PROMPT = 273,
- T_TYPE = 274,
- T_DEFAULT = 275,
- T_SELECT = 276,
- T_RANGE = 277,
- T_VISIBLE = 278,
- T_OPTION = 279,
- T_ON = 280,
- T_WORD = 281,
- T_WORD_QUOTE = 282,
- T_UNEQUAL = 283,
- T_CLOSE_PAREN = 284,
- T_OPEN_PAREN = 285,
- T_EOL = 286,
- T_OR = 287,
- T_AND = 288,
- T_EQUAL = 289,
- T_NOT = 290
- };
+ enum yytokentype
+ {
+ YYEMPTY = -2,
+ YYEOF = 0, /* "end of file" */
+ YYerror = 256, /* error */
+ YYUNDEF = 257, /* "invalid token" */
+ T_MAINMENU = 258, /* T_MAINMENU */
+ T_MENU = 259, /* T_MENU */
+ T_ENDMENU = 260, /* T_ENDMENU */
+ T_SOURCE = 261, /* T_SOURCE */
+ T_CHOICE = 262, /* T_CHOICE */
+ T_ENDCHOICE = 263, /* T_ENDCHOICE */
+ T_COMMENT = 264, /* T_COMMENT */
+ T_CONFIG = 265, /* T_CONFIG */
+ T_MENUCONFIG = 266, /* T_MENUCONFIG */
+ T_HELP = 267, /* T_HELP */
+ T_HELPTEXT = 268, /* T_HELPTEXT */
+ T_IF = 269, /* T_IF */
+ T_ENDIF = 270, /* T_ENDIF */
+ T_DEPENDS = 271, /* T_DEPENDS */
+ T_OPTIONAL = 272, /* T_OPTIONAL */
+ T_PROMPT = 273, /* T_PROMPT */
+ T_TYPE = 274, /* T_TYPE */
+ T_DEFAULT = 275, /* T_DEFAULT */
+ T_SELECT = 276, /* T_SELECT */
+ T_RANGE = 277, /* T_RANGE */
+ T_VISIBLE = 278, /* T_VISIBLE */
+ T_OPTION = 279, /* T_OPTION */
+ T_ON = 280, /* T_ON */
+ T_WORD = 281, /* T_WORD */
+ T_WORD_QUOTE = 282, /* T_WORD_QUOTE */
+ T_UNEQUAL = 283, /* T_UNEQUAL */
+ T_CLOSE_PAREN = 284, /* T_CLOSE_PAREN */
+ T_OPEN_PAREN = 285, /* T_OPEN_PAREN */
+ T_EOL = 286, /* T_EOL */
+ T_OR = 287, /* T_OR */
+ T_AND = 288, /* T_AND */
+ T_EQUAL = 289, /* T_EQUAL */
+ T_NOT = 290 /* T_NOT */
+ };
+ typedef enum yytokentype yytoken_kind_t;
#endif

-
+/* Value type. */
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-typedef union YYSTYPE
+union YYSTYPE
{

-
char *string;
struct file *file;
struct symbol *symbol;
@@ -186,33 +197,113 @@
const struct kconf_id *id;


-
-} YYSTYPE;
+};
+typedef union YYSTYPE YYSTYPE;
# define YYSTYPE_IS_TRIVIAL 1
-# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
#endif

+
extern YYSTYPE zconflval;

-#ifdef YYPARSE_PARAM
-#if defined __STDC__ || defined __cplusplus
-int zconfparse (void *YYPARSE_PARAM);
-#else
-int zconfparse ();
-#endif
-#else /* ! YYPARSE_PARAM */
-#if defined __STDC__ || defined __cplusplus
int zconfparse (void);
-#else
-int zconfparse ();
-#endif
-#endif /* ! YYPARSE_PARAM */


+/* Symbol kind. */
+enum yysymbol_kind_t
+{
+ YYSYMBOL_YYEMPTY = -2,
+ YYSYMBOL_YYEOF = 0, /* "end of file" */
+ YYSYMBOL_YYerror = 1, /* error */
+ YYSYMBOL_YYUNDEF = 2, /* "invalid token" */
+ YYSYMBOL_T_MAINMENU = 3, /* T_MAINMENU */
+ YYSYMBOL_T_MENU = 4, /* T_MENU */
+ YYSYMBOL_T_ENDMENU = 5, /* T_ENDMENU */
+ YYSYMBOL_T_SOURCE = 6, /* T_SOURCE */
+ YYSYMBOL_T_CHOICE = 7, /* T_CHOICE */
+ YYSYMBOL_T_ENDCHOICE = 8, /* T_ENDCHOICE */
+ YYSYMBOL_T_COMMENT = 9, /* T_COMMENT */
+ YYSYMBOL_T_CONFIG = 10, /* T_CONFIG */
+ YYSYMBOL_T_MENUCONFIG = 11, /* T_MENUCONFIG */
+ YYSYMBOL_T_HELP = 12, /* T_HELP */
+ YYSYMBOL_T_HELPTEXT = 13, /* T_HELPTEXT */
+ YYSYMBOL_T_IF = 14, /* T_IF */
+ YYSYMBOL_T_ENDIF = 15, /* T_ENDIF */
+ YYSYMBOL_T_DEPENDS = 16, /* T_DEPENDS */
+ YYSYMBOL_T_OPTIONAL = 17, /* T_OPTIONAL */
+ YYSYMBOL_T_PROMPT = 18, /* T_PROMPT */
+ YYSYMBOL_T_TYPE = 19, /* T_TYPE */
+ YYSYMBOL_T_DEFAULT = 20, /* T_DEFAULT */
+ YYSYMBOL_T_SELECT = 21, /* T_SELECT */
+ YYSYMBOL_T_RANGE = 22, /* T_RANGE */
+ YYSYMBOL_T_VISIBLE = 23, /* T_VISIBLE */
+ YYSYMBOL_T_OPTION = 24, /* T_OPTION */
+ YYSYMBOL_T_ON = 25, /* T_ON */
+ YYSYMBOL_T_WORD = 26, /* T_WORD */
+ YYSYMBOL_T_WORD_QUOTE = 27, /* T_WORD_QUOTE */
+ YYSYMBOL_T_UNEQUAL = 28, /* T_UNEQUAL */
+ YYSYMBOL_T_CLOSE_PAREN = 29, /* T_CLOSE_PAREN */
+ YYSYMBOL_T_OPEN_PAREN = 30, /* T_OPEN_PAREN */
+ YYSYMBOL_T_EOL = 31, /* T_EOL */
+ YYSYMBOL_T_OR = 32, /* T_OR */
+ YYSYMBOL_T_AND = 33, /* T_AND */
+ YYSYMBOL_T_EQUAL = 34, /* T_EQUAL */
+ YYSYMBOL_T_NOT = 35, /* T_NOT */
+ YYSYMBOL_YYACCEPT = 36, /* $accept */
+ YYSYMBOL_input = 37, /* input */
+ YYSYMBOL_start = 38, /* start */
+ YYSYMBOL_stmt_list = 39, /* stmt_list */
+ YYSYMBOL_option_name = 40, /* option_name */
+ YYSYMBOL_common_stmt = 41, /* common_stmt */
+ YYSYMBOL_option_error = 42, /* option_error */
+ YYSYMBOL_config_entry_start = 43, /* config_entry_start */
+ YYSYMBOL_config_stmt = 44, /* config_stmt */
+ YYSYMBOL_menuconfig_entry_start = 45, /* menuconfig_entry_start */
+ YYSYMBOL_menuconfig_stmt = 46, /* menuconfig_stmt */
+ YYSYMBOL_config_option_list = 47, /* config_option_list */
+ YYSYMBOL_config_option = 48, /* config_option */
+ YYSYMBOL_symbol_option = 49, /* symbol_option */
+ YYSYMBOL_symbol_option_list = 50, /* symbol_option_list */
+ YYSYMBOL_symbol_option_arg = 51, /* symbol_option_arg */
+ YYSYMBOL_choice = 52, /* choice */
+ YYSYMBOL_choice_entry = 53, /* choice_entry */
+ YYSYMBOL_choice_end = 54, /* choice_end */
+ YYSYMBOL_choice_stmt = 55, /* choice_stmt */
+ YYSYMBOL_choice_option_list = 56, /* choice_option_list */
+ YYSYMBOL_choice_option = 57, /* choice_option */
+ YYSYMBOL_choice_block = 58, /* choice_block */
+ YYSYMBOL_if_entry = 59, /* if_entry */
+ YYSYMBOL_if_end = 60, /* if_end */
+ YYSYMBOL_if_stmt = 61, /* if_stmt */
+ YYSYMBOL_if_block = 62, /* if_block */
+ YYSYMBOL_mainmenu_stmt = 63, /* mainmenu_stmt */
+ YYSYMBOL_menu = 64, /* menu */
+ YYSYMBOL_menu_entry = 65, /* menu_entry */
+ YYSYMBOL_menu_end = 66, /* menu_end */
+ YYSYMBOL_menu_stmt = 67, /* menu_stmt */
+ YYSYMBOL_menu_block = 68, /* menu_block */
+ YYSYMBOL_source_stmt = 69, /* source_stmt */
+ YYSYMBOL_comment = 70, /* comment */
+ YYSYMBOL_comment_stmt = 71, /* comment_stmt */
+ YYSYMBOL_help_start = 72, /* help_start */
+ YYSYMBOL_help = 73, /* help */
+ YYSYMBOL_depends_list = 74, /* depends_list */
+ YYSYMBOL_depends = 75, /* depends */
+ YYSYMBOL_visibility_list = 76, /* visibility_list */
+ YYSYMBOL_visible = 77, /* visible */
+ YYSYMBOL_prompt_stmt_opt = 78, /* prompt_stmt_opt */
+ YYSYMBOL_prompt = 79, /* prompt */
+ YYSYMBOL_end = 80, /* end */
+ YYSYMBOL_nl = 81, /* nl */
+ YYSYMBOL_if_expr = 82, /* if_expr */
+ YYSYMBOL_expr = 83, /* expr */
+ YYSYMBOL_symbol = 84, /* symbol */
+ YYSYMBOL_word_opt = 85 /* word_opt */
+};
+typedef enum yysymbol_kind_t yysymbol_kind_t;

-/* Copy the second part of user declarations. */

+/* Second part of user prologue. */

/* Include zconf.hash.c here so it can see the token constants. */
#include "zconf.hash.c"
@@ -223,31 +314,75 @@
# undef short
#endif

-#ifdef YYTYPE_UINT8
-typedef YYTYPE_UINT8 yytype_uint8;
-#else
-typedef unsigned char yytype_uint8;
+/* On compilers that do not define __PTRDIFF_MAX__ etc., make sure
+ <limits.h> and (if available) <stdint.h> are included
+ so that the code can choose integer types of a good width. */
+
+#ifndef __PTRDIFF_MAX__
+# include <limits.h> /* INFRINGES ON USER NAME SPACE */
+# if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
+# include <stdint.h> /* INFRINGES ON USER NAME SPACE */
+# define YY_STDINT_H
+# endif
#endif

-#ifdef YYTYPE_INT8
-typedef YYTYPE_INT8 yytype_int8;
-#elif (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+/* Narrow types that promote to a signed type and that can represent a
+ signed or unsigned integer of at least N bits. In tables they can
+ save space and decrease cache pressure. Promoting to a signed type
+ helps avoid bugs in integer arithmetic. */
+
+#ifdef __INT_LEAST8_MAX__
+typedef __INT_LEAST8_TYPE__ yytype_int8;
+#elif defined YY_STDINT_H
+typedef int_least8_t yytype_int8;
+#else
typedef signed char yytype_int8;
-#else
-typedef short int yytype_int8;
#endif

-#ifdef YYTYPE_UINT16
-typedef YYTYPE_UINT16 yytype_uint16;
+#ifdef __INT_LEAST16_MAX__
+typedef __INT_LEAST16_TYPE__ yytype_int16;
+#elif defined YY_STDINT_H
+typedef int_least16_t yytype_int16;
#else
-typedef unsigned short int yytype_uint16;
+typedef short yytype_int16;
#endif

-#ifdef YYTYPE_INT16
-typedef YYTYPE_INT16 yytype_int16;
+#if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
+typedef __UINT_LEAST8_TYPE__ yytype_uint8;
+#elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
+ && UINT_LEAST8_MAX <= INT_MAX)
+typedef uint_least8_t yytype_uint8;
+#elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
+typedef unsigned char yytype_uint8;
#else
-typedef short int yytype_int16;
+typedef short yytype_uint8;
+#endif
+
+#if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
+typedef __UINT_LEAST16_TYPE__ yytype_uint16;
+#elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
+ && UINT_LEAST16_MAX <= INT_MAX)
+typedef uint_least16_t yytype_uint16;
+#elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
+typedef unsigned short yytype_uint16;
+#else
+typedef int yytype_uint16;
+#endif
+
+#ifndef YYPTRDIFF_T
+# if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
+# define YYPTRDIFF_T __PTRDIFF_TYPE__
+# define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
+# elif defined PTRDIFF_MAX
+# ifndef ptrdiff_t
+# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
+# endif
+# define YYPTRDIFF_T ptrdiff_t
+# define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
+# else
+# define YYPTRDIFF_T long
+# define YYPTRDIFF_MAXIMUM LONG_MAX
+# endif
#endif

#ifndef YYSIZE_T
@@ -255,16 +390,28 @@
# define YYSIZE_T __SIZE_TYPE__
# elif defined size_t
# define YYSIZE_T size_t
-# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+# elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
# define YYSIZE_T size_t
# else
-# define YYSIZE_T unsigned int
+# define YYSIZE_T unsigned
# endif
#endif

-#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
+#define YYSIZE_MAXIMUM \
+ YY_CAST (YYPTRDIFF_T, \
+ (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \
+ ? YYPTRDIFF_MAXIMUM \
+ : YY_CAST (YYSIZE_T, -1)))
+
+#define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
+
+
+/* Stored state numbers (used for stacks). */
+typedef yytype_uint8 yy_state_t;
+
+/* State numbers in computations. */
+typedef int yy_state_fast_t;

#ifndef YY_
# if defined YYENABLE_NLS && YYENABLE_NLS
@@ -278,6 +425,23 @@
# endif
#endif

+
+#ifndef YY_ATTRIBUTE_PURE
+# if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
+# define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
+# else
+# define YY_ATTRIBUTE_PURE
+# endif
+#endif
+
+#ifndef YY_ATTRIBUTE_UNUSED
+# if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
+# define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
+# else
+# define YY_ATTRIBUTE_UNUSED
+# endif
+#endif
+
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
@@ -285,25 +449,41 @@
# define YYUSE(E) /* empty */
#endif

-/* Identity function, used to suppress warnings about constant conditions. */
-#ifndef lint
-# define YYID(N) (N)
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+/* Suppress an incorrect diagnostic about yylval being uninitialized. */
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
+ _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
+ _Pragma ("GCC diagnostic pop")
#else
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
-static int
-YYID (int yyi)
-#else
-static int
-YYID (yyi)
- int yyi;
+# define YY_INITIAL_VALUE(Value) Value
#endif
-{
- return yyi;
-}
+#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END
+#endif
+#ifndef YY_INITIAL_VALUE
+# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif

-#if ! defined yyoverflow || YYERROR_VERBOSE
+#if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
+# define YY_IGNORE_USELESS_CAST_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
+# define YY_IGNORE_USELESS_CAST_END \
+ _Pragma ("GCC diagnostic pop")
+#endif
+#ifndef YY_IGNORE_USELESS_CAST_BEGIN
+# define YY_IGNORE_USELESS_CAST_BEGIN
+# define YY_IGNORE_USELESS_CAST_END
+#endif
+
+
+#define YY_ASSERT(E) ((void) (0 && (E)))
+
+#if !defined yyoverflow

/* The parser invokes alloca or malloc; define the necessary symbols. */

@@ -320,8 +500,7 @@
# define alloca _alloca
# else
# define YYSTACK_ALLOC alloca
-# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
/* Use EXIT_SUCCESS as a witness for stdlib.h. */
# ifndef EXIT_SUCCESS
@@ -333,8 +512,8 @@
# endif

# ifdef YYSTACK_ALLOC
- /* Pacify GCC's `empty if-body' warning. */
-# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
+ /* Pacify GCC's 'empty if-body' warning. */
+# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
# ifndef YYSTACK_ALLOC_MAXIMUM
/* The OS might guarantee only one guard page at the bottom of the stack,
and a page size can be as small as 4096 bytes. So we cannot safely
@@ -350,7 +529,7 @@
# endif
# if (defined __cplusplus && ! defined EXIT_SUCCESS \
&& ! ((defined YYMALLOC || defined malloc) \
- && (defined YYFREE || defined free)))
+ && (defined YYFREE || defined free)))
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
# ifndef EXIT_SUCCESS
# define EXIT_SUCCESS 0
@@ -358,40 +537,37 @@
# endif
# ifndef YYMALLOC
# define YYMALLOC malloc
-# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+# if ! defined malloc && ! defined EXIT_SUCCESS
void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
# endif
# endif
# ifndef YYFREE
# define YYFREE free
-# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+# if ! defined free && ! defined EXIT_SUCCESS
void free (void *); /* INFRINGES ON USER NAME SPACE */
# endif
# endif
# endif
-#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
-
+#endif /* !defined yyoverflow */

#if (! defined yyoverflow \
&& (! defined __cplusplus \
- || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
+ || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))

/* A type that is properly aligned for any stack member. */
union yyalloc
{
- yytype_int16 yyss_alloc;
+ yy_state_t yyss_alloc;
YYSTYPE yyvs_alloc;
};

/* The size of the maximum gap between one aligned stack and the next. */
-# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
+# define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)

/* The size of an array large to enough to hold all stacks, each with
N elements. */
# define YYSTACK_BYTES(N) \
- ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
+ ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \
+ YYSTACK_GAP_MAXIMUM)

# define YYCOPY_NEEDED 1
@@ -401,16 +577,16 @@
elements in the stack, and YYPTR gives the new location of the
stack. Advance YYPTR to a properly aligned location for the next
stack. */
-# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
- do \
- { \
- YYSIZE_T yynewbytes; \
- YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
- Stack = &yyptr->Stack_alloc; \
- yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
- yyptr += yynewbytes / sizeof (*yyptr); \
- } \
- while (YYID (0))
+# define YYSTACK_RELOCATE(Stack_alloc, Stack) \
+ do \
+ { \
+ YYPTRDIFF_T yynewbytes; \
+ YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
+ Stack = &yyptr->Stack_alloc; \
+ yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
+ yyptr += yynewbytes / YYSIZEOF (*yyptr); \
+ } \
+ while (0)

#endif

@@ -420,16 +596,16 @@
# ifndef YYCOPY
# if defined __GNUC__ && 1 < __GNUC__
# define YYCOPY(Dst, Src, Count) \
- __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
+ __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
# else
# define YYCOPY(Dst, Src, Count) \
do \
{ \
- YYSIZE_T yyi; \
+ YYPTRDIFF_T yyi; \
for (yyi = 0; yyi < (Count); yyi++) \
(Dst)[yyi] = (Src)[yyi]; \
} \
- while (YYID (0))
+ while (0)
# endif
# endif
#endif /* !YYCOPY_NEEDED */
@@ -445,18 +621,23 @@
#define YYNNTS 50
/* YYNRULES -- Number of rules. */
#define YYNRULES 118
-/* YYNRULES -- Number of states. */
+/* YYNSTATES -- Number of states. */
#define YYNSTATES 191

-/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
-#define YYUNDEFTOK 2
+/* YYMAXUTOK -- Last valid token kind. */
#define YYMAXUTOK 290

-#define YYTRANSLATE(YYX) \
- ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)

-/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
-static const yytype_uint8 yytranslate[] =
+/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
+ as returned by yylex, with out-of-bounds checking. */
+#define YYTRANSLATE(YYX) \
+ (0 <= (YYX) && (YYX) <= YYMAXUTOK \
+ ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \
+ : YYSYMBOL_YYUNDEF)
+
+/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
+ as returned by yylex. */
+static const yytype_int8 yytranslate[] =
{
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
@@ -491,66 +672,8 @@
};

#if YYDEBUG
-/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
- YYRHS. */
-static const yytype_uint16 yyprhs[] =
-{
- 0, 0, 3, 6, 8, 11, 13, 14, 17, 20,
- 23, 26, 31, 36, 40, 42, 44, 46, 48, 50,
- 52, 54, 56, 58, 60, 62, 64, 66, 68, 72,
- 75, 79, 82, 86, 89, 90, 93, 96, 99, 102,
- 105, 108, 112, 117, 122, 127, 133, 137, 138, 142,
- 143, 146, 150, 153, 155, 159, 160, 163, 166, 169,
- 172, 175, 180, 184, 187, 192, 193, 196, 200, 202,
- 206, 207, 210, 213, 216, 220, 224, 228, 230, 234,
- 235, 238, 241, 244, 248, 252, 255, 258, 261, 262,
- 265, 268, 271, 276, 277, 280, 283, 286, 287, 290,
- 292, 294, 297, 300, 303, 305, 308, 309, 312, 314,
- 318, 322, 326, 329, 333, 337, 339, 341, 342
-};
-
-/* YYRHS -- A `-1'-separated list of the rules' RHS. */
-static const yytype_int8 yyrhs[] =
-{
- 37, 0, -1, 81, 38, -1, 38, -1, 63, 39,
- -1, 39, -1, -1, 39, 41, -1, 39, 55, -1,
- 39, 67, -1, 39, 80, -1, 39, 26, 1, 31,
- -1, 39, 40, 1, 31, -1, 39, 1, 31, -1,
- 16, -1, 18, -1, 19, -1, 21, -1, 17, -1,
- 22, -1, 20, -1, 23, -1, 31, -1, 61, -1,
- 71, -1, 44, -1, 46, -1, 69, -1, 26, 1,
- 31, -1, 1, 31, -1, 10, 26, 31, -1, 43,
- 47, -1, 11, 26, 31, -1, 45, 47, -1, -1,
- 47, 48, -1, 47, 49, -1, 47, 75, -1, 47,
- 73, -1, 47, 42, -1, 47, 31, -1, 19, 78,
- 31, -1, 18, 79, 82, 31, -1, 20, 83, 82,
- 31, -1, 21, 26, 82, 31, -1, 22, 84, 84,
- 82, 31, -1, 24, 50, 31, -1, -1, 50, 26,
- 51, -1, -1, 34, 79, -1, 7, 85, 31, -1,
- 52, 56, -1, 80, -1, 53, 58, 54, -1, -1,
- 56, 57, -1, 56, 75, -1, 56, 73, -1, 56,
- 31, -1, 56, 42, -1, 18, 79, 82, 31, -1,
- 19, 78, 31, -1, 17, 31, -1, 20, 26, 82,
- 31, -1, -1, 58, 41, -1, 14, 83, 81, -1,
- 80, -1, 59, 62, 60, -1, -1, 62, 41, -1,
- 62, 67, -1, 62, 55, -1, 3, 79, 81, -1,
- 4, 79, 31, -1, 64, 76, 74, -1, 80, -1,
- 65, 68, 66, -1, -1, 68, 41, -1, 68, 67,
- -1, 68, 55, -1, 6, 79, 31, -1, 9, 79,
- 31, -1, 70, 74, -1, 12, 31, -1, 72, 13,
- -1, -1, 74, 75, -1, 74, 31, -1, 74, 42,
- -1, 16, 25, 83, 31, -1, -1, 76, 77, -1,
- 76, 31, -1, 23, 82, -1, -1, 79, 82, -1,
- 26, -1, 27, -1, 5, 31, -1, 8, 31, -1,
- 15, 31, -1, 31, -1, 81, 31, -1, -1, 14,
- 83, -1, 84, -1, 84, 34, 84, -1, 84, 28,
- 84, -1, 30, 83, 29, -1, 35, 83, -1, 83,
- 32, 83, -1, 83, 33, 83, -1, 26, -1, 27,
- -1, -1, 26, -1
-};
-
-/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
-static const yytype_uint16 yyrline[] =
+ /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
+static const yytype_int16 yyrline[] =
{
0, 103, 103, 103, 105, 105, 107, 109, 110, 111,
112, 113, 114, 118, 122, 122, 122, 122, 122, 122,
@@ -567,117 +690,69 @@
};
#endif

-#if YYDEBUG || YYERROR_VERBOSE || 0
+/** Accessing symbol of state STATE. */
+#define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State])
+
+#if YYDEBUG || 0
+/* The user-facing name of the symbol whose (internal) number is
+ YYSYMBOL. No bounds checking. */
+static const char *yysymbol_name (yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED;
+
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
First, the terminals, then, starting at YYNTOKENS, nonterminals. */
static const char *const yytname[] =
{
- "$end", "error", "$undefined", "T_MAINMENU", "T_MENU", "T_ENDMENU",
- "T_SOURCE", "T_CHOICE", "T_ENDCHOICE", "T_COMMENT", "T_CONFIG",
- "T_MENUCONFIG", "T_HELP", "T_HELPTEXT", "T_IF", "T_ENDIF", "T_DEPENDS",
- "T_OPTIONAL", "T_PROMPT", "T_TYPE", "T_DEFAULT", "T_SELECT", "T_RANGE",
- "T_VISIBLE", "T_OPTION", "T_ON", "T_WORD", "T_WORD_QUOTE", "T_UNEQUAL",
- "T_CLOSE_PAREN", "T_OPEN_PAREN", "T_EOL", "T_OR", "T_AND", "T_EQUAL",
- "T_NOT", "$accept", "input", "start", "stmt_list", "option_name",
- "common_stmt", "option_error", "config_entry_start", "config_stmt",
- "menuconfig_entry_start", "menuconfig_stmt", "config_option_list",
- "config_option", "symbol_option", "symbol_option_list",
- "symbol_option_arg", "choice", "choice_entry", "choice_end",
- "choice_stmt", "choice_option_list", "choice_option", "choice_block",
- "if_entry", "if_end", "if_stmt", "if_block", "mainmenu_stmt", "menu",
- "menu_entry", "menu_end", "menu_stmt", "menu_block", "source_stmt",
- "comment", "comment_stmt", "help_start", "help", "depends_list",
- "depends", "visibility_list", "visible", "prompt_stmt_opt", "prompt",
- "end", "nl", "if_expr", "expr", "symbol", "word_opt", YY_NULL
+ "\"end of file\"", "error", "\"invalid token\"", "T_MAINMENU", "T_MENU",
+ "T_ENDMENU", "T_SOURCE", "T_CHOICE", "T_ENDCHOICE", "T_COMMENT",
+ "T_CONFIG", "T_MENUCONFIG", "T_HELP", "T_HELPTEXT", "T_IF", "T_ENDIF",
+ "T_DEPENDS", "T_OPTIONAL", "T_PROMPT", "T_TYPE", "T_DEFAULT", "T_SELECT",
+ "T_RANGE", "T_VISIBLE", "T_OPTION", "T_ON", "T_WORD", "T_WORD_QUOTE",
+ "T_UNEQUAL", "T_CLOSE_PAREN", "T_OPEN_PAREN", "T_EOL", "T_OR", "T_AND",
+ "T_EQUAL", "T_NOT", "$accept", "input", "start", "stmt_list",
+ "option_name", "common_stmt", "option_error", "config_entry_start",
+ "config_stmt", "menuconfig_entry_start", "menuconfig_stmt",
+ "config_option_list", "config_option", "symbol_option",
+ "symbol_option_list", "symbol_option_arg", "choice", "choice_entry",
+ "choice_end", "choice_stmt", "choice_option_list", "choice_option",
+ "choice_block", "if_entry", "if_end", "if_stmt", "if_block",
+ "mainmenu_stmt", "menu", "menu_entry", "menu_end", "menu_stmt",
+ "menu_block", "source_stmt", "comment", "comment_stmt", "help_start",
+ "help", "depends_list", "depends", "visibility_list", "visible",
+ "prompt_stmt_opt", "prompt", "end", "nl", "if_expr", "expr", "symbol",
+ "word_opt", YY_NULLPTR
};
+
+static const char *
+yysymbol_name (yysymbol_kind_t yysymbol)
+{
+ return yytname[yysymbol];
+}
#endif

-# ifdef YYPRINT
-/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
- token YYLEX-NUM. */
-static const yytype_uint16 yytoknum[] =
+#ifdef YYPRINT
+/* YYTOKNUM[NUM] -- (External) token number corresponding to the
+ (internal) symbol number NUM (which must be that of a token). */
+static const yytype_int16 yytoknum[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
285, 286, 287, 288, 289, 290
};
-# endif
+#endif

-/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const yytype_uint8 yyr1[] =
-{
- 0, 36, 37, 37, 38, 38, 39, 39, 39, 39,
- 39, 39, 39, 39, 40, 40, 40, 40, 40, 40,
- 40, 40, 41, 41, 41, 41, 41, 41, 42, 42,
- 43, 44, 45, 46, 47, 47, 47, 47, 47, 47,
- 47, 48, 48, 48, 48, 48, 49, 50, 50, 51,
- 51, 52, 53, 54, 55, 56, 56, 56, 56, 56,
- 56, 57, 57, 57, 57, 58, 58, 59, 60, 61,
- 62, 62, 62, 62, 63, 64, 65, 66, 67, 68,
- 68, 68, 68, 69, 70, 71, 72, 73, 74, 74,
- 74, 74, 75, 76, 76, 76, 77, 78, 78, 79,
- 79, 80, 80, 80, 81, 81, 82, 82, 83, 83,
- 83, 83, 83, 83, 83, 84, 84, 85, 85
-};
+#define YYPACT_NINF (-90)

-/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
-static const yytype_uint8 yyr2[] =
-{
- 0, 2, 2, 1, 2, 1, 0, 2, 2, 2,
- 2, 4, 4, 3, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 3, 2,
- 3, 2, 3, 2, 0, 2, 2, 2, 2, 2,
- 2, 3, 4, 4, 4, 5, 3, 0, 3, 0,
- 2, 3, 2, 1, 3, 0, 2, 2, 2, 2,
- 2, 4, 3, 2, 4, 0, 2, 3, 1, 3,
- 0, 2, 2, 2, 3, 3, 3, 1, 3, 0,
- 2, 2, 2, 3, 3, 2, 2, 2, 0, 2,
- 2, 2, 4, 0, 2, 2, 2, 0, 2, 1,
- 1, 2, 2, 2, 1, 2, 0, 2, 1, 3,
- 3, 3, 2, 3, 3, 1, 1, 0, 1
-};
+#define yypact_value_is_default(Yyn) \
+ ((Yyn) == YYPACT_NINF)

-/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM.
- Performed when YYTABLE doesn't specify something else to do. Zero
- means the default is an error. */
-static const yytype_uint8 yydefact[] =
-{
- 6, 0, 104, 0, 3, 0, 6, 6, 99, 100,
- 0, 1, 0, 0, 0, 0, 117, 0, 0, 0,
- 0, 0, 0, 14, 18, 15, 16, 20, 17, 19,
- 21, 0, 22, 0, 7, 34, 25, 34, 26, 55,
- 65, 8, 70, 23, 93, 79, 9, 27, 88, 24,
- 10, 0, 105, 2, 74, 13, 0, 101, 0, 118,
- 0, 102, 0, 0, 0, 115, 116, 0, 0, 0,
- 108, 103, 0, 0, 0, 0, 0, 0, 0, 88,
- 0, 0, 75, 83, 51, 84, 30, 32, 0, 112,
- 0, 0, 67, 0, 0, 11, 12, 0, 0, 0,
- 0, 97, 0, 0, 0, 47, 0, 40, 39, 35,
- 36, 0, 38, 37, 0, 0, 97, 0, 59, 60,
- 56, 58, 57, 66, 54, 53, 71, 73, 69, 72,
- 68, 106, 95, 0, 94, 80, 82, 78, 81, 77,
- 90, 91, 89, 111, 113, 114, 110, 109, 29, 86,
- 0, 106, 0, 106, 106, 106, 0, 0, 0, 87,
- 63, 106, 0, 106, 0, 96, 0, 0, 41, 98,
- 0, 0, 106, 49, 46, 28, 0, 62, 0, 107,
- 92, 42, 43, 44, 0, 0, 48, 61, 64, 45,
- 50
-};
+#define YYTABLE_NINF (-86)

-/* YYDEFGOTO[NTERM-NUM]. */
-static const yytype_int16 yydefgoto[] =
-{
- -1, 3, 4, 5, 33, 34, 108, 35, 36, 37,
- 38, 74, 109, 110, 157, 186, 39, 40, 124, 41,
- 76, 120, 77, 42, 128, 43, 78, 6, 44, 45,
- 137, 46, 80, 47, 48, 49, 111, 112, 81, 113,
- 79, 134, 152, 153, 50, 7, 165, 69, 70, 60
-};
+#define yytable_value_is_error(Yyn) \
+ 0

-/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
- STATE-NUM. */
-#define YYPACT_NINF -90
+ /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
+ STATE-NUM. */
static const yytype_int16 yypact[] =
{
4, 42, -90, 96, -90, 111, -90, 15, -90, -90,
@@ -702,7 +777,34 @@
-90
};

-/* YYPGOTO[NTERM-NUM]. */
+ /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
+ Performed when YYTABLE does not specify something else to do. Zero
+ means the default is an error. */
+static const yytype_int8 yydefact[] =
+{
+ 6, 0, 104, 0, 3, 0, 6, 6, 99, 100,
+ 0, 1, 0, 0, 0, 0, 117, 0, 0, 0,
+ 0, 0, 0, 14, 18, 15, 16, 20, 17, 19,
+ 21, 0, 22, 0, 7, 34, 25, 34, 26, 55,
+ 65, 8, 70, 23, 93, 79, 9, 27, 88, 24,
+ 10, 0, 105, 2, 74, 13, 0, 101, 0, 118,
+ 0, 102, 0, 0, 0, 115, 116, 0, 0, 0,
+ 108, 103, 0, 0, 0, 0, 0, 0, 0, 88,
+ 0, 0, 75, 83, 51, 84, 30, 32, 0, 112,
+ 0, 0, 67, 0, 0, 11, 12, 0, 0, 0,
+ 0, 97, 0, 0, 0, 47, 0, 40, 39, 35,
+ 36, 0, 38, 37, 0, 0, 97, 0, 59, 60,
+ 56, 58, 57, 66, 54, 53, 71, 73, 69, 72,
+ 68, 106, 95, 0, 94, 80, 82, 78, 81, 77,
+ 90, 91, 89, 111, 113, 114, 110, 109, 29, 86,
+ 0, 106, 0, 106, 106, 106, 0, 0, 0, 87,
+ 63, 106, 0, 106, 0, 96, 0, 0, 41, 98,
+ 0, 0, 106, 49, 46, 28, 0, 62, 0, 107,
+ 92, 42, 43, 44, 0, 0, 48, 61, 64, 45,
+ 50
+};
+
+ /* YYPGOTO[NTERM-NUM]. */
static const yytype_int16 yypgoto[] =
{
-90, -90, 269, 271, -90, 23, -70, -90, -90, -90,
@@ -712,10 +814,19 @@
-90, -90, 169, -1, 27, -7, 118, -66, -89, -90
};

-/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
- positive, shift that token. If negative, reduce the rule which
- number is the opposite. If YYTABLE_NINF, syntax error. */
-#define YYTABLE_NINF -86
+ /* YYDEFGOTO[NTERM-NUM]. */
+static const yytype_int16 yydefgoto[] =
+{
+ -1, 3, 4, 5, 33, 34, 108, 35, 36, 37,
+ 38, 74, 109, 110, 157, 186, 39, 40, 124, 41,
+ 76, 120, 77, 42, 128, 43, 78, 6, 44, 45,
+ 137, 46, 80, 47, 48, 49, 111, 112, 81, 113,
+ 79, 134, 152, 153, 50, 7, 165, 69, 70, 60
+};
+
+ /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
+ positive, shift that token. If negative, reduce the rule whose
+ number is the opposite. If YYTABLE_NINF, syntax error. */
static const yytype_int16 yytable[] =
{
10, 88, 89, 54, 146, 147, 119, 1, 122, 164,
@@ -750,12 +861,6 @@
184
};

-#define yypact_value_is_default(Yystate) \
- (!!((Yystate) == (-90)))
-
-#define yytable_value_is_error(Yytable_value) \
- YYID (0)
-
static const yytype_int16 yycheck[] =
{
1, 67, 68, 10, 93, 94, 76, 3, 76, 14,
@@ -790,9 +895,9 @@
172
};

-/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- symbol of state STATE-NUM. */
-static const yytype_uint8 yystos[] =
+ /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
+ symbol of state STATE-NUM. */
+static const yytype_int8 yystos[] =
{
0, 3, 31, 37, 38, 39, 63, 81, 26, 27,
79, 0, 1, 4, 5, 6, 7, 8, 9, 10,
@@ -816,68 +921,75 @@
79
};

-#define yyerrok (yyerrstatus = 0)
-#define yyclearin (yychar = YYEMPTY)
-#define YYEMPTY (-2)
-#define YYEOF 0
+ /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
+static const yytype_int8 yyr1[] =
+{
+ 0, 36, 37, 37, 38, 38, 39, 39, 39, 39,
+ 39, 39, 39, 39, 40, 40, 40, 40, 40, 40,
+ 40, 40, 41, 41, 41, 41, 41, 41, 42, 42,
+ 43, 44, 45, 46, 47, 47, 47, 47, 47, 47,
+ 47, 48, 48, 48, 48, 48, 49, 50, 50, 51,
+ 51, 52, 53, 54, 55, 56, 56, 56, 56, 56,
+ 56, 57, 57, 57, 57, 58, 58, 59, 60, 61,
+ 62, 62, 62, 62, 63, 64, 65, 66, 67, 68,
+ 68, 68, 68, 69, 70, 71, 72, 73, 74, 74,
+ 74, 74, 75, 76, 76, 76, 77, 78, 78, 79,
+ 79, 80, 80, 80, 81, 81, 82, 82, 83, 83,
+ 83, 83, 83, 83, 83, 84, 84, 85, 85
+};

-#define YYACCEPT goto yyacceptlab
-#define YYABORT goto yyabortlab
-#define YYERROR goto yyerrorlab
+ /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
+static const yytype_int8 yyr2[] =
+{
+ 0, 2, 2, 1, 2, 1, 0, 2, 2, 2,
+ 2, 4, 4, 3, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 3, 2,
+ 3, 2, 3, 2, 0, 2, 2, 2, 2, 2,
+ 2, 3, 4, 4, 4, 5, 3, 0, 3, 0,
+ 2, 3, 2, 1, 3, 0, 2, 2, 2, 2,
+ 2, 4, 3, 2, 4, 0, 2, 3, 1, 3,
+ 0, 2, 2, 2, 3, 3, 3, 1, 3, 0,
+ 2, 2, 2, 3, 3, 2, 2, 2, 0, 2,
+ 2, 2, 4, 0, 2, 2, 2, 0, 2, 1,
+ 1, 2, 2, 2, 1, 2, 0, 2, 1, 3,
+ 3, 3, 2, 3, 3, 1, 1, 0, 1
+};


-/* Like YYERROR except do call yyerror. This remains here temporarily
- to ease the transition to the new meaning of YYERROR, for GCC.
- Once GCC version 2 has supplanted version 1, this can go. However,
- YYFAIL appears to be in use. Nevertheless, it is formally deprecated
- in Bison 2.4.2's NEWS entry, where a plan to phase it out is
- discussed. */
+enum { YYENOMEM = -2 };

-#define YYFAIL goto yyerrlab
-#if defined YYFAIL
- /* This is here to suppress warnings from the GCC cpp's
- -Wunused-macros. Normally we don't worry about that warning, but
- some users do, and we want to make it easy for users to remove
- YYFAIL uses, which will produce warnings from Bison 2.5. */
-#endif
+#define yyerrok (yyerrstatus = 0)
+#define yyclearin (yychar = YYEMPTY)
+
+#define YYACCEPT goto yyacceptlab
+#define YYABORT goto yyabortlab
+#define YYERROR goto yyerrorlab
+

#define YYRECOVERING() (!!yyerrstatus)

-#define YYBACKUP(Token, Value) \
-do \
- if (yychar == YYEMPTY) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (yylen); \
- yystate = *yyssp; \
- goto yybackup; \
- } \
- else \
- { \
- yyerror (YY_("syntax error: cannot back up")); \
- YYERROR; \
- } \
-while (YYID (0))
+#define YYBACKUP(Token, Value) \
+ do \
+ if (yychar == YYEMPTY) \
+ { \
+ yychar = (Token); \
+ yylval = (Value); \
+ YYPOPSTACK (yylen); \
+ yystate = *yyssp; \
+ goto yybackup; \
+ } \
+ else \
+ { \
+ yyerror (YY_("syntax error: cannot back up")); \
+ YYERROR; \
+ } \
+ while (0)

-/* Error token number */
-#define YYTERROR 1
-#define YYERRCODE 256
+/* Backward compatibility with an undocumented macro.
+ Use YYerror or YYUNDEF. */
+#define YYERRCODE YYUNDEF


-/* This macro is provided for backward compatibility. */
-#ifndef YY_LOCATION_PRINT
-# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
-#endif
-
-
-/* YYLEX -- calling `yylex' with the right arguments. */
-#ifdef YYLEX_PARAM
-# define YYLEX yylex (YYLEX_PARAM)
-#else
-# define YYLEX yylex ()
-#endif
-
/* Enable debugging if requested. */
#if YYDEBUG

@@ -886,82 +998,65 @@
# define YYFPRINTF fprintf
# endif

-# define YYDPRINTF(Args) \
-do { \
- if (yydebug) \
- YYFPRINTF Args; \
-} while (YYID (0))
+# define YYDPRINTF(Args) \
+do { \
+ if (yydebug) \
+ YYFPRINTF Args; \
+} while (0)

-# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
-do { \
- if (yydebug) \
- { \
- YYFPRINTF (stderr, "%s ", Title); \
- yy_symbol_print (stderr, \
- Type, Value); \
- YYFPRINTF (stderr, "\n"); \
- } \
-} while (YYID (0))
+/* This macro is provided for backward compatibility. */
+# ifndef YY_LOCATION_PRINT
+# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
+# endif


-/*--------------------------------.
-| Print this symbol on YYOUTPUT. |
-`--------------------------------*/
+# define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \
+do { \
+ if (yydebug) \
+ { \
+ YYFPRINTF (stderr, "%s ", Title); \
+ yy_symbol_print (stderr, \
+ Kind, Value); \
+ YYFPRINTF (stderr, "\n"); \
+ } \
+} while (0)

-/*ARGSUSED*/
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
+
+/*-----------------------------------.
+| Print this symbol's value on YYO. |
+`-----------------------------------*/
+
static void
-yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
-#else
-static void
-yy_symbol_value_print (yyoutput, yytype, yyvaluep)
- FILE *yyoutput;
- int yytype;
- YYSTYPE const * const yyvaluep;
-#endif
+yy_symbol_value_print (FILE *yyo,
+ yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep)
{
- FILE *yyo = yyoutput;
- YYUSE (yyo);
+ FILE *yyoutput = yyo;
+ YYUSE (yyoutput);
if (!yyvaluep)
return;
# ifdef YYPRINT
- if (yytype < YYNTOKENS)
- YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
-# else
- YYUSE (yyoutput);
+ if (yykind < YYNTOKENS)
+ YYPRINT (yyo, yytoknum[yykind], *yyvaluep);
# endif
- switch (yytype)
- {
- default:
- break;
- }
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+ YYUSE (yykind);
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
}


-/*--------------------------------.
-| Print this symbol on YYOUTPUT. |
-`--------------------------------*/
+/*---------------------------.
+| Print this symbol on YYO. |
+`---------------------------*/

-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
static void
-yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
-#else
-static void
-yy_symbol_print (yyoutput, yytype, yyvaluep)
- FILE *yyoutput;
- int yytype;
- YYSTYPE const * const yyvaluep;
-#endif
+yy_symbol_print (FILE *yyo,
+ yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep)
{
- if (yytype < YYNTOKENS)
- YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
- else
- YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
+ YYFPRINTF (yyo, "%s %s (",
+ yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name (yykind));

- yy_symbol_value_print (yyoutput, yytype, yyvaluep);
- YYFPRINTF (yyoutput, ")");
+ yy_symbol_value_print (yyo, yykind, yyvaluep);
+ YYFPRINTF (yyo, ")");
}

/*------------------------------------------------------------------.
@@ -969,16 +1064,8 @@
| TOP (included). |
`------------------------------------------------------------------*/

-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
static void
-yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop)
-#else
-static void
-yy_stack_print (yybottom, yytop)
- yytype_int16 *yybottom;
- yytype_int16 *yytop;
-#endif
+yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop)
{
YYFPRINTF (stderr, "Stack now");
for (; yybottom <= yytop; yybottom++)
@@ -989,63 +1076,56 @@
YYFPRINTF (stderr, "\n");
}

-# define YY_STACK_PRINT(Bottom, Top) \
-do { \
- if (yydebug) \
- yy_stack_print ((Bottom), (Top)); \
-} while (YYID (0))
+# define YY_STACK_PRINT(Bottom, Top) \
+do { \
+ if (yydebug) \
+ yy_stack_print ((Bottom), (Top)); \
+} while (0)


/*------------------------------------------------.
| Report that the YYRULE is going to be reduced. |
`------------------------------------------------*/

-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
static void
-yy_reduce_print (YYSTYPE *yyvsp, int yyrule)
-#else
-static void
-yy_reduce_print (yyvsp, yyrule)
- YYSTYPE *yyvsp;
- int yyrule;
-#endif
+yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp,
+ int yyrule)
{
+ int yylno = yyrline[yyrule];
int yynrhs = yyr2[yyrule];
int yyi;
- unsigned long int yylno = yyrline[yyrule];
- YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
- yyrule - 1, yylno);
+ YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n",
+ yyrule - 1, yylno);
/* The symbols being reduced. */
for (yyi = 0; yyi < yynrhs; yyi++)
{
YYFPRINTF (stderr, " $%d = ", yyi + 1);
- yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
- &(yyvsp[(yyi + 1) - (yynrhs)])
- );
+ yy_symbol_print (stderr,
+ YY_ACCESSING_SYMBOL (+yyssp[yyi + 1 - yynrhs]),
+ &yyvsp[(yyi + 1) - (yynrhs)]);
YYFPRINTF (stderr, "\n");
}
}

-# define YY_REDUCE_PRINT(Rule) \
-do { \
- if (yydebug) \
- yy_reduce_print (yyvsp, Rule); \
-} while (YYID (0))
+# define YY_REDUCE_PRINT(Rule) \
+do { \
+ if (yydebug) \
+ yy_reduce_print (yyssp, yyvsp, Rule); \
+} while (0)

/* Nonzero means print parse trace. It is left uninitialized so that
multiple parsers can coexist. */
int yydebug;
#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
+# define YYDPRINTF(Args) ((void) 0)
+# define YY_SYMBOL_PRINT(Title, Kind, Value, Location)
# define YY_STACK_PRINT(Bottom, Top)
# define YY_REDUCE_PRINT(Rule)
#endif /* !YYDEBUG */


/* YYINITDEPTH -- initial size of the parser's stacks. */
-#ifndef YYINITDEPTH
+#ifndef YYINITDEPTH
# define YYINITDEPTH 200
#endif

@@ -1061,393 +1141,108 @@
#endif


-#if YYERROR_VERBOSE

-# ifndef yystrlen
-# if defined __GLIBC__ && defined _STRING_H
-# define yystrlen strlen
-# else
-/* Return the length of YYSTR. */
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
-static YYSIZE_T
-yystrlen (const char *yystr)
-#else
-static YYSIZE_T
-yystrlen (yystr)
- const char *yystr;
-#endif
-{
- YYSIZE_T yylen;
- for (yylen = 0; yystr[yylen]; yylen++)
- continue;
- return yylen;
-}
-# endif
-# endif

-# ifndef yystpcpy
-# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
-# define yystpcpy stpcpy
-# else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
- YYDEST. */
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
-static char *
-yystpcpy (char *yydest, const char *yysrc)
-#else
-static char *
-yystpcpy (yydest, yysrc)
- char *yydest;
- const char *yysrc;
-#endif
-{
- char *yyd = yydest;
- const char *yys = yysrc;

- while ((*yyd++ = *yys++) != '\0')
- continue;
-
- return yyd - 1;
-}
-# endif
-# endif
-
-# ifndef yytnamerr
-/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
- quotes and backslashes, so that it's suitable for yyerror. The
- heuristic is that double-quoting is unnecessary unless the string
- contains an apostrophe, a comma, or backslash (other than
- backslash-backslash). YYSTR is taken from yytname. If YYRES is
- null, do not copy; instead, return the length of what the result
- would have been. */
-static YYSIZE_T
-yytnamerr (char *yyres, const char *yystr)
-{
- if (*yystr == '"')
- {
- YYSIZE_T yyn = 0;
- char const *yyp = yystr;
-
- for (;;)
- switch (*++yyp)
- {
- case '\'':
- case ',':
- goto do_not_strip_quotes;
-
- case '\\':
- if (*++yyp != '\\')
- goto do_not_strip_quotes;
- /* Fall through. */
- default:
- if (yyres)
- yyres[yyn] = *yyp;
- yyn++;
- break;
-
- case '"':
- if (yyres)
- yyres[yyn] = '\0';
- return yyn;
- }
- do_not_strip_quotes: ;
- }
-
- if (! yyres)
- return yystrlen (yystr);
-
- return yystpcpy (yyres, yystr) - yyres;
-}
-# endif
-
-/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
- about the unexpected token YYTOKEN for the state stack whose top is
- YYSSP.
-
- Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
- not large enough to hold the message. In that case, also set
- *YYMSG_ALLOC to the required number of bytes. Return 2 if the
- required number of bytes is too large to store. */
-static int
-yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
- yytype_int16 *yyssp, int yytoken)
-{
- YYSIZE_T yysize0 = yytnamerr (YY_NULL, yytname[yytoken]);
- YYSIZE_T yysize = yysize0;
- enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
- /* Internationalized format string. */
- const char *yyformat = YY_NULL;
- /* Arguments of yyformat. */
- char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
- /* Number of reported tokens (one for the "unexpected", one per
- "expected"). */
- int yycount = 0;
-
- /* There are many possibilities here to consider:
- - Assume YYFAIL is not used. It's too flawed to consider. See
- <http://lists.gnu.org/archive/html/bison-patches/2009-12/msg00024.html>
- for details. YYERROR is fine as it does not invoke this
- function.
- - If this state is a consistent state with a default action, then
- the only way this function was invoked is if the default action
- is an error action. In that case, don't check for expected
- tokens because there are none.
- - The only way there can be no lookahead present (in yychar) is if
- this state is a consistent state with a default action. Thus,
- detecting the absence of a lookahead is sufficient to determine
- that there is no unexpected or expected token to report. In that
- case, just report a simple "syntax error".
- - Don't assume there isn't a lookahead just because this state is a
- consistent state with a default action. There might have been a
- previous inconsistent state, consistent state with a non-default
- action, or user semantic action that manipulated yychar.
- - Of course, the expected token list depends on states to have
- correct lookahead information, and it depends on the parser not
- to perform extra reductions after fetching a lookahead from the
- scanner and before detecting a syntax error. Thus, state merging
- (from LALR or IELR) and default reductions corrupt the expected
- token list. However, the list is correct for canonical LR with
- one exception: it will still contain any token that will not be
- accepted due to an error action in a later state.
- */
- if (yytoken != YYEMPTY)
- {
- int yyn = yypact[*yyssp];
- yyarg[yycount++] = yytname[yytoken];
- if (!yypact_value_is_default (yyn))
- {
- /* Start YYX at -YYN if negative to avoid negative indexes in
- YYCHECK. In other words, skip the first -YYN actions for
- this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
- /* Stay within bounds of both yycheck and yytname. */
- int yychecklim = YYLAST - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
- int yyx;
-
- for (yyx = yyxbegin; yyx < yyxend; ++yyx)
- if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
- && !yytable_value_is_error (yytable[yyx + yyn]))
- {
- if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
- {
- yycount = 1;
- yysize = yysize0;
- break;
- }
- yyarg[yycount++] = yytname[yyx];
- {
- YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULL, yytname[yyx]);
- if (! (yysize <= yysize1
- && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
- return 2;
- yysize = yysize1;
- }
- }
- }
- }
-
- switch (yycount)
- {
-# define YYCASE_(N, S) \
- case N: \
- yyformat = S; \
- break
- YYCASE_(0, YY_("syntax error"));
- YYCASE_(1, YY_("syntax error, unexpected %s"));
- YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
- YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
- YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
- YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
-# undef YYCASE_
- }
-
- {
- YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
- if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
- return 2;
- yysize = yysize1;
- }
-
- if (*yymsg_alloc < yysize)
- {
- *yymsg_alloc = 2 * yysize;
- if (! (yysize <= *yymsg_alloc
- && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
- *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
- return 1;
- }
-
- /* Avoid sprintf, as that infringes on the user's name space.
- Don't have undefined behavior even if the translation
- produced a string with the wrong number of "%s"s. */
- {
- char *yyp = *yymsg;
- int yyi = 0;
- while ((*yyp = *yyformat) != '\0')
- if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
- {
- yyp += yytnamerr (yyp, yyarg[yyi++]);
- yyformat += 2;
- }
- else
- {
- yyp++;
- yyformat++;
- }
- }
- return 0;
-}
-#endif /* YYERROR_VERBOSE */

/*-----------------------------------------------.
| Release the memory associated to this symbol. |
`-----------------------------------------------*/

-/*ARGSUSED*/
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
static void
-yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
-#else
-static void
-yydestruct (yymsg, yytype, yyvaluep)
- const char *yymsg;
- int yytype;
- YYSTYPE *yyvaluep;
-#endif
+yydestruct (const char *yymsg,
+ yysymbol_kind_t yykind, YYSTYPE *yyvaluep)
{
YYUSE (yyvaluep);
-
if (!yymsg)
yymsg = "Deleting";
- YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
+ YY_SYMBOL_PRINT (yymsg, yykind, yyvaluep, yylocationp);

- switch (yytype)
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+ switch (yykind)
{
- case 53: /* choice_entry */
-
- {
+ case YYSYMBOL_choice_entry: /* choice_entry */
+ {
fprintf(stderr, "%s:%d: missing end statement for this entry\n",
((*yyvaluep).menu)->file->name, ((*yyvaluep).menu)->lineno);
if (current_menu == ((*yyvaluep).menu))
menu_end_menu();
-};
-
+}
break;
- case 59: /* if_entry */

- {
+ case YYSYMBOL_if_entry: /* if_entry */
+ {
fprintf(stderr, "%s:%d: missing end statement for this entry\n",
((*yyvaluep).menu)->file->name, ((*yyvaluep).menu)->lineno);
if (current_menu == ((*yyvaluep).menu))
menu_end_menu();
-};
-
+}
break;
- case 65: /* menu_entry */

- {
+ case YYSYMBOL_menu_entry: /* menu_entry */
+ {
fprintf(stderr, "%s:%d: missing end statement for this entry\n",
((*yyvaluep).menu)->file->name, ((*yyvaluep).menu)->lineno);
if (current_menu == ((*yyvaluep).menu))
menu_end_menu();
-};
-
+}
break;

default:
break;
}
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
}


-
-
-/* The lookahead symbol. */
+/* Lookahead token kind. */
int yychar;

-
-#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
-# define YY_IGNORE_MAYBE_UNINITIALIZED_END
-#endif
-#ifndef YY_INITIAL_VALUE
-# define YY_INITIAL_VALUE(Value) /* Nothing. */
-#endif
-
/* The semantic value of the lookahead symbol. */
-YYSTYPE yylval YY_INITIAL_VALUE(yyval_default);
-
+YYSTYPE yylval;
/* Number of syntax errors so far. */
int yynerrs;


+
+
/*----------.
| yyparse. |
`----------*/

-#ifdef YYPARSE_PARAM
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
-int
-yyparse (void *YYPARSE_PARAM)
-#else
-int
-yyparse (YYPARSE_PARAM)
- void *YYPARSE_PARAM;
-#endif
-#else /* ! YYPARSE_PARAM */
-#if (defined __STDC__ || defined __C99__FUNC__ \
- || defined __cplusplus || defined _MSC_VER)
int
yyparse (void)
-#else
-int
-yyparse ()
-
-#endif
-#endif
{
- int yystate;
+ yy_state_fast_t yystate = 0;
/* Number of tokens to shift before error messages enabled. */
- int yyerrstatus;
+ int yyerrstatus = 0;

- /* The stacks and their tools:
- `yyss': related to states.
- `yyvs': related to semantic values.
-
- Refer to the stacks through separate pointers, to allow yyoverflow
+ /* Refer to the stacks through separate pointers, to allow yyoverflow
to reallocate them elsewhere. */

- /* The state stack. */
- yytype_int16 yyssa[YYINITDEPTH];
- yytype_int16 *yyss;
- yytype_int16 *yyssp;
+ /* Their size. */
+ YYPTRDIFF_T yystacksize = YYINITDEPTH;

- /* The semantic value stack. */
+ /* The state stack: array, bottom, top. */
+ yy_state_t yyssa[YYINITDEPTH];
+ yy_state_t *yyss = yyssa;
+ yy_state_t *yyssp = yyss;
+
+ /* The semantic value stack: array, bottom, top. */
YYSTYPE yyvsa[YYINITDEPTH];
- YYSTYPE *yyvs;
- YYSTYPE *yyvsp;
-
- YYSIZE_T yystacksize;
+ YYSTYPE *yyvs = yyvsa;
+ YYSTYPE *yyvsp = yyvs;

int yyn;
+ /* The return value of yyparse. */
int yyresult;
- /* Lookahead token as an internal (translated) token number. */
- int yytoken = 0;
+ /* Lookahead symbol kind. */
+ yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY;
/* The variables used to return semantic value and location from the
action routines. */
YYSTYPE yyval;

-#if YYERROR_VERBOSE
- /* Buffer for error messages, and its allocated size. */
- char yymsgbuf[128];
- char *yymsg = yymsgbuf;
- YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
-#endif
+

#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))

@@ -1455,102 +1250,105 @@
Keep to zero when no symbol should be popped. */
int yylen = 0;

- yyssp = yyss = yyssa;
- yyvsp = yyvs = yyvsa;
- yystacksize = YYINITDEPTH;
-
YYDPRINTF ((stderr, "Starting parse\n"));

- yystate = 0;
- yyerrstatus = 0;
- yynerrs = 0;
yychar = YYEMPTY; /* Cause a token to be read. */
goto yysetstate;

+
/*------------------------------------------------------------.
-| yynewstate -- Push a new state, which is found in yystate. |
+| yynewstate -- push a new state, which is found in yystate. |
`------------------------------------------------------------*/
- yynewstate:
+yynewstate:
/* In all cases, when you get here, the value and location stacks
have just been pushed. So pushing a state here evens the stacks. */
yyssp++;

- yysetstate:
- *yyssp = yystate;
+
+/*--------------------------------------------------------------------.
+| yysetstate -- set current state (the top of the stack) to yystate. |
+`--------------------------------------------------------------------*/
+yysetstate:
+ YYDPRINTF ((stderr, "Entering state %d\n", yystate));
+ YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
+ YY_IGNORE_USELESS_CAST_BEGIN
+ *yyssp = YY_CAST (yy_state_t, yystate);
+ YY_IGNORE_USELESS_CAST_END
+ YY_STACK_PRINT (yyss, yyssp);

if (yyss + yystacksize - 1 <= yyssp)
+#if !defined yyoverflow && !defined YYSTACK_RELOCATE
+ goto yyexhaustedlab;
+#else
{
/* Get the current used size of the three stacks, in elements. */
- YYSIZE_T yysize = yyssp - yyss + 1;
+ YYPTRDIFF_T yysize = yyssp - yyss + 1;

-#ifdef yyoverflow
+# if defined yyoverflow
{
- /* Give user a chance to reallocate the stack. Use copies of
- these so that the &'s don't force the real ones into
- memory. */
- YYSTYPE *yyvs1 = yyvs;
- yytype_int16 *yyss1 = yyss;
+ /* Give user a chance to reallocate the stack. Use copies of
+ these so that the &'s don't force the real ones into
+ memory. */
+ yy_state_t *yyss1 = yyss;
+ YYSTYPE *yyvs1 = yyvs;

- /* Each stack pointer address is followed by the size of the
- data in use in that stack, in bytes. This used to be a
- conditional around just the two extra args, but that might
- be undefined if yyoverflow is a macro. */
- yyoverflow (YY_("memory exhausted"),
- &yyss1, yysize * sizeof (*yyssp),
- &yyvs1, yysize * sizeof (*yyvsp),
- &yystacksize);
-
- yyss = yyss1;
- yyvs = yyvs1;
+ /* Each stack pointer address is followed by the size of the
+ data in use in that stack, in bytes. This used to be a
+ conditional around just the two extra args, but that might
+ be undefined if yyoverflow is a macro. */
+ yyoverflow (YY_("memory exhausted"),
+ &yyss1, yysize * YYSIZEOF (*yyssp),
+ &yyvs1, yysize * YYSIZEOF (*yyvsp),
+ &yystacksize);
+ yyss = yyss1;
+ yyvs = yyvs1;
}
-#else /* no yyoverflow */
-# ifndef YYSTACK_RELOCATE
- goto yyexhaustedlab;
-# else
+# else /* defined YYSTACK_RELOCATE */
/* Extend the stack our own way. */
if (YYMAXDEPTH <= yystacksize)
- goto yyexhaustedlab;
+ goto yyexhaustedlab;
yystacksize *= 2;
if (YYMAXDEPTH < yystacksize)
- yystacksize = YYMAXDEPTH;
+ yystacksize = YYMAXDEPTH;

{
- yytype_int16 *yyss1 = yyss;
- union yyalloc *yyptr =
- (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
- if (! yyptr)
- goto yyexhaustedlab;
- YYSTACK_RELOCATE (yyss_alloc, yyss);
- YYSTACK_RELOCATE (yyvs_alloc, yyvs);
+ yy_state_t *yyss1 = yyss;
+ union yyalloc *yyptr =
+ YY_CAST (union yyalloc *,
+ YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize))));
+ if (! yyptr)
+ goto yyexhaustedlab;
+ YYSTACK_RELOCATE (yyss_alloc, yyss);
+ YYSTACK_RELOCATE (yyvs_alloc, yyvs);
# undef YYSTACK_RELOCATE
- if (yyss1 != yyssa)
- YYSTACK_FREE (yyss1);
+ if (yyss1 != yyssa)
+ YYSTACK_FREE (yyss1);
}
# endif
-#endif /* no yyoverflow */

yyssp = yyss + yysize - 1;
yyvsp = yyvs + yysize - 1;

- YYDPRINTF ((stderr, "Stack size increased to %lu\n",
- (unsigned long int) yystacksize));
+ YY_IGNORE_USELESS_CAST_BEGIN
+ YYDPRINTF ((stderr, "Stack size increased to %ld\n",
+ YY_CAST (long, yystacksize)));
+ YY_IGNORE_USELESS_CAST_END

if (yyss + yystacksize - 1 <= yyssp)
- YYABORT;
+ YYABORT;
}
-
- YYDPRINTF ((stderr, "Entering state %d\n", yystate));
+#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */

if (yystate == YYFINAL)
YYACCEPT;

goto yybackup;

+
/*-----------.
| yybackup. |
`-----------*/
yybackup:
-
/* Do appropriate processing given the current state. Read a
lookahead token if we need one and don't already have one. */

@@ -1561,18 +1359,29 @@

/* Not known => get a lookahead token if don't already have one. */

- /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
+ /* YYCHAR is either empty, or end-of-input, or a valid lookahead. */
if (yychar == YYEMPTY)
{
- YYDPRINTF ((stderr, "Reading a token: "));
- yychar = YYLEX;
+ YYDPRINTF ((stderr, "Reading a token\n"));
+ yychar = yylex ();
}

if (yychar <= YYEOF)
{
- yychar = yytoken = YYEOF;
+ yychar = YYEOF;
+ yytoken = YYSYMBOL_YYEOF;
YYDPRINTF ((stderr, "Now at end of input.\n"));
}
+ else if (yychar == YYerror)
+ {
+ /* The scanner already issued an error message, process directly
+ to error recovery. But do not keep the error token as
+ lookahead, it is too special and may lead us to an endless
+ loop in error recovery. */
+ yychar = YYUNDEF;
+ yytoken = YYSYMBOL_YYerror;
+ goto yyerrlab1;
+ }
else
{
yytoken = YYTRANSLATE (yychar);
@@ -1600,15 +1409,13 @@

/* Shift the lookahead token. */
YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
-
- /* Discard the shifted token. */
- yychar = YYEMPTY;
-
yystate = yyn;
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
*++yyvsp = yylval;
YY_IGNORE_MAYBE_UNINITIALIZED_END

+ /* Discard the shifted token. */
+ yychar = YYEMPTY;
goto yynewstate;


@@ -1623,14 +1430,14 @@


/*-----------------------------.
-| yyreduce -- Do a reduction. |
+| yyreduce -- do a reduction. |
`-----------------------------*/
yyreduce:
/* yyn is the number of a rule to reduce with. */
yylen = yyr2[yyn];

/* If YYLEN is nonzero, implement the default value of the action:
- `$$ = $1'.
+ '$$ = $1'.

Otherwise, the following line sets YYVAL to garbage.
This behavior is undocumented and Bison
@@ -1643,69 +1450,59 @@
YY_REDUCE_PRINT (yyn);
switch (yyn)
{
- case 10:
-
- { zconf_error("unexpected end statement"); }
+ case 10: /* stmt_list: stmt_list end */
+ { zconf_error("unexpected end statement"); }
break;

- case 11:
-
- { zconf_error("unknown statement \"%s\"", (yyvsp[(2) - (4)].string)); }
+ case 11: /* stmt_list: stmt_list T_WORD error T_EOL */
+ { zconf_error("unknown statement \"%s\"", (yyvsp[-2].string)); }
break;

- case 12:
-
- {
- zconf_error("unexpected option \"%s\"", kconf_id_strings + (yyvsp[(2) - (4)].id)->name);
+ case 12: /* stmt_list: stmt_list option_name error T_EOL */
+{
+ zconf_error("unexpected option \"%s\"", kconf_id_strings + (yyvsp[-2].id)->name);
}
break;

- case 13:
-
- { zconf_error("invalid statement"); }
+ case 13: /* stmt_list: stmt_list error T_EOL */
+ { zconf_error("invalid statement"); }
break;

- case 28:
-
- { zconf_error("unknown option \"%s\"", (yyvsp[(1) - (3)].string)); }
+ case 28: /* option_error: T_WORD error T_EOL */
+ { zconf_error("unknown option \"%s\"", (yyvsp[-2].string)); }
break;

- case 29:
-
- { zconf_error("invalid option"); }
+ case 29: /* option_error: error T_EOL */
+ { zconf_error("invalid option"); }
break;

- case 30:
-
- {
- struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), 0);
+ case 30: /* config_entry_start: T_CONFIG T_WORD T_EOL */
+{
+ struct symbol *sym = sym_lookup((yyvsp[-1].string), 0);
sym->flags |= SYMBOL_OPTIONAL;
menu_add_entry(sym);
- printd(DEBUG_PARSE, "%s:%d:config %s\n", zconf_curname(), zconf_lineno(), (yyvsp[(2) - (3)].string));
+ printd(DEBUG_PARSE, "%s:%d:config %s\n", zconf_curname(), zconf_lineno(), (yyvsp[-1].string));
}
break;

- case 31:
-
- {
+ case 31: /* config_stmt: config_entry_start config_option_list */
+{
menu_end_entry();
printd(DEBUG_PARSE, "%s:%d:endconfig\n", zconf_curname(), zconf_lineno());
}
break;

- case 32:
-
- {
- struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), 0);
+ case 32: /* menuconfig_entry_start: T_MENUCONFIG T_WORD T_EOL */
+{
+ struct symbol *sym = sym_lookup((yyvsp[-1].string), 0);
sym->flags |= SYMBOL_OPTIONAL;
menu_add_entry(sym);
- printd(DEBUG_PARSE, "%s:%d:menuconfig %s\n", zconf_curname(), zconf_lineno(), (yyvsp[(2) - (3)].string));
+ printd(DEBUG_PARSE, "%s:%d:menuconfig %s\n", zconf_curname(), zconf_lineno(), (yyvsp[-1].string));
}
break;

- case 33:
-
- {
+ case 33: /* menuconfig_stmt: menuconfig_entry_start config_option_list */
+{
if (current_entry->prompt)
current_entry->prompt->type = P_MENU;
else
@@ -1715,78 +1512,69 @@
}
break;

- case 41:
-
- {
- menu_set_type((yyvsp[(1) - (3)].id)->stype);
+ case 41: /* config_option: T_TYPE prompt_stmt_opt T_EOL */
+{
+ menu_set_type((yyvsp[-2].id)->stype);
printd(DEBUG_PARSE, "%s:%d:type(%u)\n",
zconf_curname(), zconf_lineno(),
- (yyvsp[(1) - (3)].id)->stype);
+ (yyvsp[-2].id)->stype);
}
break;

- case 42:
-
- {
- menu_add_prompt(P_PROMPT, (yyvsp[(2) - (4)].string), (yyvsp[(3) - (4)].expr));
+ case 42: /* config_option: T_PROMPT prompt if_expr T_EOL */
+{
+ menu_add_prompt(P_PROMPT, (yyvsp[-2].string), (yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:prompt\n", zconf_curname(), zconf_lineno());
}
break;

- case 43:
-
- {
- menu_add_expr(P_DEFAULT, (yyvsp[(2) - (4)].expr), (yyvsp[(3) - (4)].expr));
- if ((yyvsp[(1) - (4)].id)->stype != S_UNKNOWN)
- menu_set_type((yyvsp[(1) - (4)].id)->stype);
+ case 43: /* config_option: T_DEFAULT expr if_expr T_EOL */
+{
+ menu_add_expr(P_DEFAULT, (yyvsp[-2].expr), (yyvsp[-1].expr));
+ if ((yyvsp[-3].id)->stype != S_UNKNOWN)
+ menu_set_type((yyvsp[-3].id)->stype);
printd(DEBUG_PARSE, "%s:%d:default(%u)\n",
zconf_curname(), zconf_lineno(),
- (yyvsp[(1) - (4)].id)->stype);
+ (yyvsp[-3].id)->stype);
}
break;

- case 44:
-
- {
- menu_add_symbol(P_SELECT, sym_lookup((yyvsp[(2) - (4)].string), 0), (yyvsp[(3) - (4)].expr));
+ case 44: /* config_option: T_SELECT T_WORD if_expr T_EOL */
+{
+ menu_add_symbol(P_SELECT, sym_lookup((yyvsp[-2].string), 0), (yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:select\n", zconf_curname(), zconf_lineno());
}
break;

- case 45:
-
- {
- menu_add_expr(P_RANGE, expr_alloc_comp(E_RANGE,(yyvsp[(2) - (5)].symbol), (yyvsp[(3) - (5)].symbol)), (yyvsp[(4) - (5)].expr));
+ case 45: /* config_option: T_RANGE symbol symbol if_expr T_EOL */
+{
+ menu_add_expr(P_RANGE, expr_alloc_comp(E_RANGE,(yyvsp[-3].symbol), (yyvsp[-2].symbol)), (yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:range\n", zconf_curname(), zconf_lineno());
}
break;

- case 48:
-
- {
- const struct kconf_id *id = kconf_id_lookup((yyvsp[(2) - (3)].string), strlen((yyvsp[(2) - (3)].string)));
+ case 48: /* symbol_option_list: symbol_option_list T_WORD symbol_option_arg */
+{
+ const struct kconf_id *id = kconf_id_lookup((yyvsp[-1].string), strlen((yyvsp[-1].string)));
if (id && id->flags & TF_OPTION)
- menu_add_option(id->token, (yyvsp[(3) - (3)].string));
+ menu_add_option(id->token, (yyvsp[0].string));
else
- zconfprint("warning: ignoring unknown option %s", (yyvsp[(2) - (3)].string));
- free((yyvsp[(2) - (3)].string));
+ zconfprint("warning: ignoring unknown option %s", (yyvsp[-1].string));
+ free((yyvsp[-1].string));
}
break;

- case 49:
-
- { (yyval.string) = NULL; }
+ case 49: /* symbol_option_arg: %empty */
+ { (yyval.string) = NULL; }
break;

- case 50:
-
- { (yyval.string) = (yyvsp[(2) - (2)].string); }
+ case 50: /* symbol_option_arg: T_EQUAL prompt */
+ { (yyval.string) = (yyvsp[0].string); }
break;

- case 51:
-
- {
- struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), SYMBOL_CHOICE);
+ case 51: /* choice: T_CHOICE word_opt T_EOL */
+{
+ struct symbol *sym = sym_lookup((yyvsp[-1].string), SYMBOL_CHOICE);
sym->flags |= SYMBOL_AUTO;
menu_add_entry(sym);
menu_add_expr(P_CHOICE, NULL, NULL);
@@ -1794,57 +1582,51 @@
}
break;

- case 52:
-
- {
+ case 52: /* choice_entry: choice choice_option_list */
+{
(yyval.menu) = menu_add_menu();
}
break;

- case 53:
-
- {
- if (zconf_endtoken((yyvsp[(1) - (1)].id), T_CHOICE, T_ENDCHOICE)) {
+ case 53: /* choice_end: end */
+{
+ if (zconf_endtoken((yyvsp[0].id), T_CHOICE, T_ENDCHOICE)) {
menu_end_menu();
printd(DEBUG_PARSE, "%s:%d:endchoice\n", zconf_curname(), zconf_lineno());
}
}
break;

- case 61:
-
- {
- menu_add_prompt(P_PROMPT, (yyvsp[(2) - (4)].string), (yyvsp[(3) - (4)].expr));
+ case 61: /* choice_option: T_PROMPT prompt if_expr T_EOL */
+{
+ menu_add_prompt(P_PROMPT, (yyvsp[-2].string), (yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:prompt\n", zconf_curname(), zconf_lineno());
}
break;

- case 62:
-
- {
- if ((yyvsp[(1) - (3)].id)->stype == S_BOOLEAN || (yyvsp[(1) - (3)].id)->stype == S_TRISTATE) {
- menu_set_type((yyvsp[(1) - (3)].id)->stype);
+ case 62: /* choice_option: T_TYPE prompt_stmt_opt T_EOL */
+{
+ if ((yyvsp[-2].id)->stype == S_BOOLEAN || (yyvsp[-2].id)->stype == S_TRISTATE) {
+ menu_set_type((yyvsp[-2].id)->stype);
printd(DEBUG_PARSE, "%s:%d:type(%u)\n",
zconf_curname(), zconf_lineno(),
- (yyvsp[(1) - (3)].id)->stype);
+ (yyvsp[-2].id)->stype);
} else
YYERROR;
}
break;

- case 63:
-
- {
+ case 63: /* choice_option: T_OPTIONAL T_EOL */
+{
current_entry->sym->flags |= SYMBOL_OPTIONAL;
printd(DEBUG_PARSE, "%s:%d:optional\n", zconf_curname(), zconf_lineno());
}
break;

- case 64:
-
- {
- if ((yyvsp[(1) - (4)].id)->stype == S_UNKNOWN) {
- menu_add_symbol(P_DEFAULT, sym_lookup((yyvsp[(2) - (4)].string), 0), (yyvsp[(3) - (4)].expr));
+ case 64: /* choice_option: T_DEFAULT T_WORD if_expr T_EOL */
+{
+ if ((yyvsp[-3].id)->stype == S_UNKNOWN) {
+ menu_add_symbol(P_DEFAULT, sym_lookup((yyvsp[-2].string), 0), (yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:default\n",
zconf_curname(), zconf_lineno());
} else
@@ -1852,193 +1634,164 @@
}
break;

- case 67:
-
- {
+ case 67: /* if_entry: T_IF expr nl */
+{
printd(DEBUG_PARSE, "%s:%d:if\n", zconf_curname(), zconf_lineno());
menu_add_entry(NULL);
- menu_add_dep((yyvsp[(2) - (3)].expr));
+ menu_add_dep((yyvsp[-1].expr));
(yyval.menu) = menu_add_menu();
}
break;

- case 68:
-
- {
- if (zconf_endtoken((yyvsp[(1) - (1)].id), T_IF, T_ENDIF)) {
+ case 68: /* if_end: end */
+{
+ if (zconf_endtoken((yyvsp[0].id), T_IF, T_ENDIF)) {
menu_end_menu();
printd(DEBUG_PARSE, "%s:%d:endif\n", zconf_curname(), zconf_lineno());
}
}
break;

- case 74:
-
- {
- menu_add_prompt(P_MENU, (yyvsp[(2) - (3)].string), NULL);
+ case 74: /* mainmenu_stmt: T_MAINMENU prompt nl */
+{
+ menu_add_prompt(P_MENU, (yyvsp[-1].string), NULL);
}
break;

- case 75:
-
- {
+ case 75: /* menu: T_MENU prompt T_EOL */
+{
menu_add_entry(NULL);
- menu_add_prompt(P_MENU, (yyvsp[(2) - (3)].string), NULL);
+ menu_add_prompt(P_MENU, (yyvsp[-1].string), NULL);
printd(DEBUG_PARSE, "%s:%d:menu\n", zconf_curname(), zconf_lineno());
}
break;

- case 76:
-
- {
+ case 76: /* menu_entry: menu visibility_list depends_list */
+{
(yyval.menu) = menu_add_menu();
}
break;

- case 77:
-
- {
- if (zconf_endtoken((yyvsp[(1) - (1)].id), T_MENU, T_ENDMENU)) {
+ case 77: /* menu_end: end */
+{
+ if (zconf_endtoken((yyvsp[0].id), T_MENU, T_ENDMENU)) {
menu_end_menu();
printd(DEBUG_PARSE, "%s:%d:endmenu\n", zconf_curname(), zconf_lineno());
}
}
break;

- case 83:
-
- {
- printd(DEBUG_PARSE, "%s:%d:source %s\n", zconf_curname(), zconf_lineno(), (yyvsp[(2) - (3)].string));
- zconf_nextfiles((yyvsp[(2) - (3)].string));
+ case 83: /* source_stmt: T_SOURCE prompt T_EOL */
+{
+ printd(DEBUG_PARSE, "%s:%d:source %s\n", zconf_curname(), zconf_lineno(), (yyvsp[-1].string));
+ zconf_nextfiles((yyvsp[-1].string));
}
break;

- case 84:
-
- {
+ case 84: /* comment: T_COMMENT prompt T_EOL */
+{
menu_add_entry(NULL);
- menu_add_prompt(P_COMMENT, (yyvsp[(2) - (3)].string), NULL);
+ menu_add_prompt(P_COMMENT, (yyvsp[-1].string), NULL);
printd(DEBUG_PARSE, "%s:%d:comment\n", zconf_curname(), zconf_lineno());
}
break;

- case 85:
-
- {
+ case 85: /* comment_stmt: comment depends_list */
+{
menu_end_entry();
}
break;

- case 86:
-
- {
+ case 86: /* help_start: T_HELP T_EOL */
+{
printd(DEBUG_PARSE, "%s:%d:help\n", zconf_curname(), zconf_lineno());
zconf_starthelp();
}
break;

- case 87:
-
- {
- current_entry->help = (yyvsp[(2) - (2)].string);
+ case 87: /* help: help_start T_HELPTEXT */
+{
+ current_entry->help = (yyvsp[0].string);
}
break;

- case 92:
-
- {
- menu_add_dep((yyvsp[(3) - (4)].expr));
+ case 92: /* depends: T_DEPENDS T_ON expr T_EOL */
+{
+ menu_add_dep((yyvsp[-1].expr));
printd(DEBUG_PARSE, "%s:%d:depends on\n", zconf_curname(), zconf_lineno());
}
break;

- case 96:
-
- {
- menu_add_visibility((yyvsp[(2) - (2)].expr));
+ case 96: /* visible: T_VISIBLE if_expr */
+{
+ menu_add_visibility((yyvsp[0].expr));
}
break;

- case 98:
-
- {
- menu_add_prompt(P_PROMPT, (yyvsp[(1) - (2)].string), (yyvsp[(2) - (2)].expr));
+ case 98: /* prompt_stmt_opt: prompt if_expr */
+{
+ menu_add_prompt(P_PROMPT, (yyvsp[-1].string), (yyvsp[0].expr));
}
break;

- case 101:
-
- { (yyval.id) = (yyvsp[(1) - (2)].id); }
+ case 101: /* end: T_ENDMENU T_EOL */
+ { (yyval.id) = (yyvsp[-1].id); }
break;

- case 102:
-
- { (yyval.id) = (yyvsp[(1) - (2)].id); }
+ case 102: /* end: T_ENDCHOICE T_EOL */
+ { (yyval.id) = (yyvsp[-1].id); }
break;

- case 103:
-
- { (yyval.id) = (yyvsp[(1) - (2)].id); }
+ case 103: /* end: T_ENDIF T_EOL */
+ { (yyval.id) = (yyvsp[-1].id); }
break;

- case 106:
-
- { (yyval.expr) = NULL; }
+ case 106: /* if_expr: %empty */
+ { (yyval.expr) = NULL; }
break;

- case 107:
-
- { (yyval.expr) = (yyvsp[(2) - (2)].expr); }
+ case 107: /* if_expr: T_IF expr */
+ { (yyval.expr) = (yyvsp[0].expr); }
break;

- case 108:
-
- { (yyval.expr) = expr_alloc_symbol((yyvsp[(1) - (1)].symbol)); }
+ case 108: /* expr: symbol */
+ { (yyval.expr) = expr_alloc_symbol((yyvsp[0].symbol)); }
break;

- case 109:
-
- { (yyval.expr) = expr_alloc_comp(E_EQUAL, (yyvsp[(1) - (3)].symbol), (yyvsp[(3) - (3)].symbol)); }
+ case 109: /* expr: symbol T_EQUAL symbol */
+ { (yyval.expr) = expr_alloc_comp(E_EQUAL, (yyvsp[-2].symbol), (yyvsp[0].symbol)); }
break;

- case 110:
-
- { (yyval.expr) = expr_alloc_comp(E_UNEQUAL, (yyvsp[(1) - (3)].symbol), (yyvsp[(3) - (3)].symbol)); }
+ case 110: /* expr: symbol T_UNEQUAL symbol */
+ { (yyval.expr) = expr_alloc_comp(E_UNEQUAL, (yyvsp[-2].symbol), (yyvsp[0].symbol)); }
break;

- case 111:
-
- { (yyval.expr) = (yyvsp[(2) - (3)].expr); }
+ case 111: /* expr: T_OPEN_PAREN expr T_CLOSE_PAREN */
+ { (yyval.expr) = (yyvsp[-1].expr); }
break;

- case 112:
-
- { (yyval.expr) = expr_alloc_one(E_NOT, (yyvsp[(2) - (2)].expr)); }
+ case 112: /* expr: T_NOT expr */
+ { (yyval.expr) = expr_alloc_one(E_NOT, (yyvsp[0].expr)); }
break;

- case 113:
-
- { (yyval.expr) = expr_alloc_two(E_OR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) - (3)].expr)); }
+ case 113: /* expr: expr T_OR expr */
+ { (yyval.expr) = expr_alloc_two(E_OR, (yyvsp[-2].expr), (yyvsp[0].expr)); }
break;

- case 114:
-
- { (yyval.expr) = expr_alloc_two(E_AND, (yyvsp[(1) - (3)].expr), (yyvsp[(3) - (3)].expr)); }
+ case 114: /* expr: expr T_AND expr */
+ { (yyval.expr) = expr_alloc_two(E_AND, (yyvsp[-2].expr), (yyvsp[0].expr)); }
break;

- case 115:
-
- { (yyval.symbol) = sym_lookup((yyvsp[(1) - (1)].string), 0); free((yyvsp[(1) - (1)].string)); }
+ case 115: /* symbol: T_WORD */
+ { (yyval.symbol) = sym_lookup((yyvsp[0].string), 0); free((yyvsp[0].string)); }
break;

- case 116:
-
- { (yyval.symbol) = sym_lookup((yyvsp[(1) - (1)].string), SYMBOL_CONST); free((yyvsp[(1) - (1)].string)); }
+ case 116: /* symbol: T_WORD_QUOTE */
+ { (yyval.symbol) = sym_lookup((yyvsp[0].string), SYMBOL_CONST); free((yyvsp[0].string)); }
break;

- case 117:
-
- { (yyval.string) = NULL; }
+ case 117: /* word_opt: %empty */
+ { (yyval.string) = NULL; }
break;


@@ -2056,96 +1809,58 @@
case of YYERROR or YYBACKUP, subsequent parser actions might lead
to an incorrect destructor call or verbose syntax error message
before the lookahead is translated. */
- YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
+ YY_SYMBOL_PRINT ("-> $$ =", YY_CAST (yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc);

YYPOPSTACK (yylen);
yylen = 0;
- YY_STACK_PRINT (yyss, yyssp);

*++yyvsp = yyval;

- /* Now `shift' the result of the reduction. Determine what state
+ /* Now 'shift' the result of the reduction. Determine what state
that goes to, based on the state we popped back to and the rule
number reduced by. */
-
- yyn = yyr1[yyn];
-
- yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
- if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
- yystate = yytable[yystate];
- else
- yystate = yydefgoto[yyn - YYNTOKENS];
+ {
+ const int yylhs = yyr1[yyn] - YYNTOKENS;
+ const int yyi = yypgoto[yylhs] + *yyssp;
+ yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
+ ? yytable[yyi]
+ : yydefgoto[yylhs]);
+ }

goto yynewstate;


-/*------------------------------------.
-| yyerrlab -- here on detecting error |
-`------------------------------------*/
+/*--------------------------------------.
+| yyerrlab -- here on detecting error. |
+`--------------------------------------*/
yyerrlab:
/* Make sure we have latest lookahead translation. See comments at
user semantic actions for why this is necessary. */
- yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
-
+ yytoken = yychar == YYEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar);
/* If not already recovering from an error, report this error. */
if (!yyerrstatus)
{
++yynerrs;
-#if ! YYERROR_VERBOSE
yyerror (YY_("syntax error"));
-#else
-# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
- yyssp, yytoken)
- {
- char const *yymsgp = YY_("syntax error");
- int yysyntax_error_status;
- yysyntax_error_status = YYSYNTAX_ERROR;
- if (yysyntax_error_status == 0)
- yymsgp = yymsg;
- else if (yysyntax_error_status == 1)
- {
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
- yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
- if (!yymsg)
- {
- yymsg = yymsgbuf;
- yymsg_alloc = sizeof yymsgbuf;
- yysyntax_error_status = 2;
- }
- else
- {
- yysyntax_error_status = YYSYNTAX_ERROR;
- yymsgp = yymsg;
- }
- }
- yyerror (yymsgp);
- if (yysyntax_error_status == 2)
- goto yyexhaustedlab;
- }
-# undef YYSYNTAX_ERROR
-#endif
}

-
-
if (yyerrstatus == 3)
{
/* If just tried and failed to reuse lookahead token after an
- error, discard it. */
+ error, discard it. */

if (yychar <= YYEOF)
- {
- /* Return failure if at end of input. */
- if (yychar == YYEOF)
- YYABORT;
- }
+ {
+ /* Return failure if at end of input. */
+ if (yychar == YYEOF)
+ YYABORT;
+ }
else
- {
- yydestruct ("Error: discarding",
- yytoken, &yylval);
- yychar = YYEMPTY;
- }
+ {
+ yydestruct ("Error: discarding",
+ yytoken, &yylval);
+ yychar = YYEMPTY;
+ }
}

/* Else will try to reuse lookahead token after shifting the error
@@ -2157,14 +1872,12 @@
| yyerrorlab -- error raised explicitly by YYERROR. |
`---------------------------------------------------*/
yyerrorlab:
+ /* Pacify compilers when the user code never invokes YYERROR and the
+ label yyerrorlab therefore never appears in user code. */
+ if (0)
+ YYERROR;

- /* Pacify compilers like GCC when the user code never invokes
- YYERROR and the label yyerrorlab therefore never appears in user
- code. */
- if (/*CONSTCOND*/ 0)
- goto yyerrorlab;
-
- /* Do not reclaim the symbols of the rule which action triggered
+ /* Do not reclaim the symbols of the rule whose action triggered
this YYERROR. */
YYPOPSTACK (yylen);
yylen = 0;
@@ -2177,29 +1890,30 @@
| yyerrlab1 -- common code for both syntax error and YYERROR. |
`-------------------------------------------------------------*/
yyerrlab1:
- yyerrstatus = 3; /* Each real token shifted decrements this. */
+ yyerrstatus = 3; /* Each real token shifted decrements this. */

+ /* Pop stack until we find a state that shifts the error token. */
for (;;)
{
yyn = yypact[yystate];
if (!yypact_value_is_default (yyn))
- {
- yyn += YYTERROR;
- if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
- {
- yyn = yytable[yyn];
- if (0 < yyn)
- break;
- }
- }
+ {
+ yyn += YYSYMBOL_YYerror;
+ if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror)
+ {
+ yyn = yytable[yyn];
+ if (0 < yyn)
+ break;
+ }
+ }

/* Pop the current state because it cannot handle the error token. */
if (yyssp == yyss)
- YYABORT;
+ YYABORT;


yydestruct ("Error: popping",
- yystos[yystate], yyvsp);
+ YY_ACCESSING_SYMBOL (yystate), yyvsp);
YYPOPSTACK (1);
yystate = *yyssp;
YY_STACK_PRINT (yyss, yyssp);
@@ -2211,7 +1925,7 @@


/* Shift the error token. */
- YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
+ YY_SYMBOL_PRINT ("Shifting", YY_ACCESSING_SYMBOL (yyn), yyvsp, yylsp);

yystate = yyn;
goto yynewstate;
@@ -2224,6 +1938,7 @@
yyresult = 0;
goto yyreturn;

+
/*-----------------------------------.
| yyabortlab -- YYABORT comes here. |
`-----------------------------------*/
@@ -2231,16 +1946,21 @@
yyresult = 1;
goto yyreturn;

-#if !defined yyoverflow || YYERROR_VERBOSE
+
+#if !defined yyoverflow
/*-------------------------------------------------.
| yyexhaustedlab -- memory exhaustion comes here. |
`-------------------------------------------------*/
yyexhaustedlab:
yyerror (YY_("memory exhausted"));
yyresult = 2;
- /* Fall through. */
+ goto yyreturn;
#endif

+
+/*-------------------------------------------------------.
+| yyreturn -- parsing is finished, clean up and return. |
+`-------------------------------------------------------*/
yyreturn:
if (yychar != YYEMPTY)
{
@@ -2250,32 +1970,26 @@
yydestruct ("Cleanup: discarding lookahead",
yytoken, &yylval);
}
- /* Do not reclaim the symbols of the rule which action triggered
+ /* Do not reclaim the symbols of the rule whose action triggered
this YYABORT or YYACCEPT. */
YYPOPSTACK (yylen);
YY_STACK_PRINT (yyss, yyssp);
while (yyssp != yyss)
{
yydestruct ("Cleanup: popping",
- yystos[*yyssp], yyvsp);
+ YY_ACCESSING_SYMBOL (+*yyssp), yyvsp);
YYPOPSTACK (1);
}
#ifndef yyoverflow
if (yyss != yyssa)
YYSTACK_FREE (yyss);
#endif
-#if YYERROR_VERBOSE
- if (yymsg != yymsgbuf)
- YYSTACK_FREE (yymsg);
-#endif
- /* Make sure YYID is used. */
- return YYID (yyresult);
+
+ return yyresult;
}



-
-
void conf_parse(const char *name)
{
struct symbol *sym;

To view, visit change 48677. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I71fbcfc1807e7398da250ddf1e47f6530345e0b5
Gerrit-Change-Number: 48677
Gerrit-PatchSet: 1
Gerrit-Owner: Jack Rosenthal <jrosenth@chromium.org>
Gerrit-Reviewer: Martin Roth <martinroth@google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com>
Gerrit-Reviewer: Patrick Rudolph <siro@das-labor.org>
Gerrit-MessageType: newchange