Commit 605e9710 authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild

Pull kconfig updates from Michal Marek:
 - kconfig warns about junk characters in Kconfig files
 - merge_config.sh error handling
 - small cleanup

* 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
  merge_config.sh: exit on missing input files
  kconfig: Regenerate shipped zconf.{hash,lex}.c files
  kconfig: warn of unhandled characters in Kconfig commands
  kconfig: Delete unnecessary checks before the function call "sym_calc_value"
parents dab3c3cc 78a6854e
...@@ -268,8 +268,7 @@ int conf_read_simple(const char *name, int def) ...@@ -268,8 +268,7 @@ int conf_read_simple(const char *name, int def)
goto load; goto load;
sym_add_change_count(1); sym_add_change_count(1);
if (!sym_defconfig_list) { if (!sym_defconfig_list) {
if (modules_sym) sym_calc_value(modules_sym);
sym_calc_value(modules_sym);
return 1; return 1;
} }
...@@ -404,9 +403,7 @@ int conf_read_simple(const char *name, int def) ...@@ -404,9 +403,7 @@ int conf_read_simple(const char *name, int def)
} }
free(line); free(line);
fclose(in); fclose(in);
sym_calc_value(modules_sym);
if (modules_sym)
sym_calc_value(modules_sym);
return 0; return 0;
} }
......
...@@ -100,6 +100,10 @@ cat $INITFILE > $TMP_FILE ...@@ -100,6 +100,10 @@ cat $INITFILE > $TMP_FILE
# Merge files, printing warnings on overridden values # Merge files, printing warnings on overridden values
for MERGE_FILE in $MERGE_LIST ; do for MERGE_FILE in $MERGE_LIST ; do
echo "Merging $MERGE_FILE" echo "Merging $MERGE_FILE"
if [ ! -r "$MERGE_FILE" ]; then
echo "The merge file '$MERGE_FILE' does not exist. Exit." >&2
exit 1
fi
CFG_LIST=$(sed -n "$SED_CONFIG_EXP" $MERGE_FILE) CFG_LIST=$(sed -n "$SED_CONFIG_EXP" $MERGE_FILE)
for CFG in $CFG_LIST ; do for CFG in $CFG_LIST ; do
......
...@@ -467,8 +467,7 @@ void sym_clear_all_valid(void) ...@@ -467,8 +467,7 @@ void sym_clear_all_valid(void)
for_all_symbols(i, sym) for_all_symbols(i, sym)
sym->flags &= ~SYMBOL_VALID; sym->flags &= ~SYMBOL_VALID;
sym_add_change_count(1); sym_add_change_count(1);
if (modules_sym) sym_calc_value(modules_sym);
sym_calc_value(modules_sym);
} }
bool sym_tristate_within_range(struct symbol *sym, tristate val) bool sym_tristate_within_range(struct symbol *sym, tristate val)
......
...@@ -22,6 +22,7 @@ comment, T_COMMENT, TF_COMMAND ...@@ -22,6 +22,7 @@ comment, T_COMMENT, TF_COMMAND
config, T_CONFIG, TF_COMMAND config, T_CONFIG, TF_COMMAND
menuconfig, T_MENUCONFIG, TF_COMMAND menuconfig, T_MENUCONFIG, TF_COMMAND
help, T_HELP, TF_COMMAND help, T_HELP, TF_COMMAND
---help---, T_HELP, TF_COMMAND
if, T_IF, TF_COMMAND|TF_PARAM if, T_IF, TF_COMMAND|TF_PARAM
endif, T_ENDIF, TF_COMMAND endif, T_ENDIF, TF_COMMAND
depends, T_DEPENDS, TF_COMMAND depends, T_DEPENDS, TF_COMMAND
......
...@@ -50,7 +50,7 @@ kconf_id_hash (register const char *str, register unsigned int len) ...@@ -50,7 +50,7 @@ kconf_id_hash (register const char *str, register unsigned int len)
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, 0, 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,
...@@ -96,6 +96,7 @@ struct kconf_id_strings_t ...@@ -96,6 +96,7 @@ struct kconf_id_strings_t
char kconf_id_strings_str7[sizeof("default")]; char kconf_id_strings_str7[sizeof("default")];
char kconf_id_strings_str8[sizeof("tristate")]; char kconf_id_strings_str8[sizeof("tristate")];
char kconf_id_strings_str9[sizeof("endchoice")]; char kconf_id_strings_str9[sizeof("endchoice")];
char kconf_id_strings_str10[sizeof("---help---")];
char kconf_id_strings_str12[sizeof("def_tristate")]; char kconf_id_strings_str12[sizeof("def_tristate")];
char kconf_id_strings_str13[sizeof("def_bool")]; char kconf_id_strings_str13[sizeof("def_bool")];
char kconf_id_strings_str14[sizeof("defconfig_list")]; char kconf_id_strings_str14[sizeof("defconfig_list")];
...@@ -132,6 +133,7 @@ static const struct kconf_id_strings_t kconf_id_strings_contents = ...@@ -132,6 +133,7 @@ static const struct kconf_id_strings_t kconf_id_strings_contents =
"default", "default",
"tristate", "tristate",
"endchoice", "endchoice",
"---help---",
"def_tristate", "def_tristate",
"def_bool", "def_bool",
"defconfig_list", "defconfig_list",
...@@ -172,7 +174,7 @@ kconf_id_lookup (register const char *str, register unsigned int len) ...@@ -172,7 +174,7 @@ kconf_id_lookup (register const char *str, register unsigned int len)
{ {
enum enum
{ {
TOTAL_KEYWORDS = 33, TOTAL_KEYWORDS = 34,
MIN_WORD_LENGTH = 2, MIN_WORD_LENGTH = 2,
MAX_WORD_LENGTH = 14, MAX_WORD_LENGTH = 14,
MIN_HASH_VALUE = 2, MIN_HASH_VALUE = 2,
...@@ -182,34 +184,36 @@ kconf_id_lookup (register const char *str, register unsigned int len) ...@@ -182,34 +184,36 @@ kconf_id_lookup (register const char *str, register unsigned int len)
static const struct kconf_id wordlist[] = static const struct kconf_id wordlist[] =
{ {
{-1}, {-1}, {-1}, {-1},
#line 25 "scripts/kconfig/zconf.gperf" #line 26 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str2, T_IF, TF_COMMAND|TF_PARAM}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str2, T_IF, TF_COMMAND|TF_PARAM},
#line 36 "scripts/kconfig/zconf.gperf" #line 37 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str3, T_TYPE, TF_COMMAND, S_INT}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str3, T_TYPE, TF_COMMAND, S_INT},
{-1}, {-1},
#line 26 "scripts/kconfig/zconf.gperf" #line 27 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str5, T_ENDIF, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str5, T_ENDIF, TF_COMMAND},
{-1}, {-1},
#line 29 "scripts/kconfig/zconf.gperf" #line 30 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str7, T_DEFAULT, TF_COMMAND, S_UNKNOWN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str7, T_DEFAULT, TF_COMMAND, S_UNKNOWN},
#line 31 "scripts/kconfig/zconf.gperf" #line 32 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str8, T_TYPE, TF_COMMAND, S_TRISTATE}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str8, T_TYPE, TF_COMMAND, S_TRISTATE},
#line 20 "scripts/kconfig/zconf.gperf" #line 20 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str9, T_ENDCHOICE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str9, T_ENDCHOICE, TF_COMMAND},
{-1}, {-1}, #line 25 "scripts/kconfig/zconf.gperf"
#line 32 "scripts/kconfig/zconf.gperf" {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str10, T_HELP, TF_COMMAND},
{-1},
#line 33 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str12, T_DEFAULT, TF_COMMAND, S_TRISTATE}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str12, T_DEFAULT, TF_COMMAND, S_TRISTATE},
#line 35 "scripts/kconfig/zconf.gperf" #line 36 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str13, T_DEFAULT, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str13, T_DEFAULT, TF_COMMAND, S_BOOLEAN},
#line 45 "scripts/kconfig/zconf.gperf" #line 46 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str14, T_OPT_DEFCONFIG_LIST,TF_OPTION}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str14, T_OPT_DEFCONFIG_LIST,TF_OPTION},
{-1}, {-1}, {-1}, {-1},
#line 43 "scripts/kconfig/zconf.gperf" #line 44 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str17, T_ON, TF_PARAM}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str17, T_ON, TF_PARAM},
#line 28 "scripts/kconfig/zconf.gperf" #line 29 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_OPTIONAL, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_OPTIONAL, TF_COMMAND},
{-1}, {-1}, {-1}, {-1},
#line 42 "scripts/kconfig/zconf.gperf" #line 43 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str21, T_OPTION, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str21, T_OPTION, TF_COMMAND},
#line 17 "scripts/kconfig/zconf.gperf" #line 17 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str22, T_ENDMENU, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str22, T_ENDMENU, TF_COMMAND},
...@@ -219,51 +223,51 @@ kconf_id_lookup (register const char *str, register unsigned int len) ...@@ -219,51 +223,51 @@ kconf_id_lookup (register const char *str, register unsigned int len)
#line 23 "scripts/kconfig/zconf.gperf" #line 23 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str25, T_MENUCONFIG, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str25, T_MENUCONFIG, TF_COMMAND},
{-1}, {-1},
#line 44 "scripts/kconfig/zconf.gperf" #line 45 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str27, T_OPT_MODULES, TF_OPTION}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str27, T_OPT_MODULES, TF_OPTION},
#line 47 "scripts/kconfig/zconf.gperf" #line 48 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str28, T_OPT_ALLNOCONFIG_Y,TF_OPTION}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str28, T_OPT_ALLNOCONFIG_Y,TF_OPTION},
#line 16 "scripts/kconfig/zconf.gperf" #line 16 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str29, T_MENU, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str29, T_MENU, TF_COMMAND},
{-1}, {-1},
#line 39 "scripts/kconfig/zconf.gperf" #line 40 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str31, T_SELECT, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str31, T_SELECT, TF_COMMAND},
#line 21 "scripts/kconfig/zconf.gperf" #line 21 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str32, T_COMMENT, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str32, T_COMMENT, TF_COMMAND},
#line 46 "scripts/kconfig/zconf.gperf" #line 47 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str33, T_OPT_ENV, TF_OPTION}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str33, T_OPT_ENV, TF_OPTION},
{-1}, {-1},
#line 40 "scripts/kconfig/zconf.gperf" #line 41 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str35, T_RANGE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str35, T_RANGE, TF_COMMAND},
#line 19 "scripts/kconfig/zconf.gperf" #line 19 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_CHOICE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_CHOICE, TF_COMMAND},
{-1}, {-1}, {-1}, {-1},
#line 33 "scripts/kconfig/zconf.gperf" #line 34 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str39, T_TYPE, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str39, T_TYPE, TF_COMMAND, S_BOOLEAN},
{-1}, {-1},
#line 18 "scripts/kconfig/zconf.gperf" #line 18 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str41, T_SOURCE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str41, T_SOURCE, TF_COMMAND},
#line 41 "scripts/kconfig/zconf.gperf" #line 42 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str42, T_VISIBLE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str42, T_VISIBLE, TF_COMMAND},
#line 37 "scripts/kconfig/zconf.gperf" #line 38 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str43, T_TYPE, TF_COMMAND, S_HEX}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str43, T_TYPE, TF_COMMAND, S_HEX},
{-1}, {-1}, {-1}, {-1},
#line 22 "scripts/kconfig/zconf.gperf" #line 22 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str46, T_CONFIG, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str46, T_CONFIG, TF_COMMAND},
#line 34 "scripts/kconfig/zconf.gperf" #line 35 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str47, T_TYPE, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str47, T_TYPE, TF_COMMAND, S_BOOLEAN},
{-1}, {-1}, {-1}, {-1}, {-1}, {-1},
#line 38 "scripts/kconfig/zconf.gperf" #line 39 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str51, T_TYPE, TF_COMMAND, S_STRING}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str51, T_TYPE, TF_COMMAND, S_STRING},
{-1}, {-1}, {-1}, {-1},
#line 24 "scripts/kconfig/zconf.gperf" #line 24 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str54, T_HELP, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str54, T_HELP, TF_COMMAND},
{-1}, {-1},
#line 30 "scripts/kconfig/zconf.gperf" #line 31 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str56, T_PROMPT, TF_COMMAND}, {(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}, {-1}, {-1}, {-1},
{-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1},
#line 27 "scripts/kconfig/zconf.gperf" #line 28 "scripts/kconfig/zconf.gperf"
{(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str72, T_DEPENDS, TF_COMMAND} {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str72, T_DEPENDS, TF_COMMAND}
}; };
...@@ -285,5 +289,5 @@ kconf_id_lookup (register const char *str, register unsigned int len) ...@@ -285,5 +289,5 @@ kconf_id_lookup (register const char *str, register unsigned int len)
} }
return 0; return 0;
} }
#line 48 "scripts/kconfig/zconf.gperf" #line 49 "scripts/kconfig/zconf.gperf"
...@@ -66,9 +66,16 @@ static void alloc_string(const char *str, int size) ...@@ -66,9 +66,16 @@ static void alloc_string(const char *str, int size)
memcpy(text, str, size); memcpy(text, str, size);
text[size] = 0; text[size] = 0;
} }
static void warn_ignored_character(char chr)
{
fprintf(stderr,
"%s:%d:warning: ignoring unsupported character '%c'\n",
zconf_curname(), zconf_lineno(), chr);
}
%} %}
n [A-Za-z0-9_] n [A-Za-z0-9_-]
%% %%
int str = 0; int str = 0;
...@@ -106,7 +113,7 @@ n [A-Za-z0-9_] ...@@ -106,7 +113,7 @@ n [A-Za-z0-9_]
zconflval.string = text; zconflval.string = text;
return T_WORD; return T_WORD;
} }
. . warn_ignored_character(*yytext);
\n { \n {
BEGIN(INITIAL); BEGIN(INITIAL);
current_file->lineno++; current_file->lineno++;
...@@ -132,8 +139,7 @@ n [A-Za-z0-9_] ...@@ -132,8 +139,7 @@ n [A-Za-z0-9_]
BEGIN(STRING); BEGIN(STRING);
} }
\n BEGIN(INITIAL); current_file->lineno++; return T_EOL; \n BEGIN(INITIAL); current_file->lineno++; return T_EOL;
--- /* ignore */ ({n}|[/.])+ {
({n}|[-/.])+ {
const struct kconf_id *id = kconf_id_lookup(yytext, yyleng); const struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
if (id && id->flags & TF_PARAM) { if (id && id->flags & TF_PARAM) {
zconflval.id = id; zconflval.id = id;
...@@ -146,11 +152,7 @@ n [A-Za-z0-9_] ...@@ -146,11 +152,7 @@ n [A-Za-z0-9_]
#.* /* comment */ #.* /* comment */
\\\n current_file->lineno++; \\\n current_file->lineno++;
[[:blank:]]+ [[:blank:]]+
. { . warn_ignored_character(*yytext);
fprintf(stderr,
"%s:%d:warning: ignoring unsupported character '%c'\n",
zconf_curname(), zconf_lineno(), *yytext);
}
<<EOF>> { <<EOF>> {
BEGIN(INITIAL); BEGIN(INITIAL);
} }
......
...@@ -72,7 +72,6 @@ typedef int flex_int32_t; ...@@ -72,7 +72,6 @@ typedef int flex_int32_t;
typedef unsigned char flex_uint8_t; typedef unsigned char flex_uint8_t;
typedef unsigned short int flex_uint16_t; typedef unsigned short int flex_uint16_t;
typedef unsigned int flex_uint32_t; typedef unsigned int flex_uint32_t;
#endif /* ! C99 */
/* Limits of integral types. */ /* Limits of integral types. */
#ifndef INT8_MIN #ifndef INT8_MIN
...@@ -103,6 +102,8 @@ typedef unsigned int flex_uint32_t; ...@@ -103,6 +102,8 @@ typedef unsigned int flex_uint32_t;
#define UINT32_MAX (4294967295U) #define UINT32_MAX (4294967295U)
#endif #endif
#endif /* ! C99 */
#endif /* ! FLEXINT_H */ #endif /* ! FLEXINT_H */
#ifdef __cplusplus #ifdef __cplusplus
...@@ -159,7 +160,15 @@ typedef unsigned int flex_uint32_t; ...@@ -159,7 +160,15 @@ typedef unsigned int flex_uint32_t;
/* Size of default input buffer. */ /* Size of default input buffer. */
#ifndef YY_BUF_SIZE #ifndef YY_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k.
* Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
* Ditto for the __ia64__ case accordingly.
*/
#define YY_BUF_SIZE 32768
#else
#define YY_BUF_SIZE 16384 #define YY_BUF_SIZE 16384
#endif /* __ia64__ */
#endif #endif
/* The state buf must be large enough to hold one state per character in the main buffer. /* The state buf must be large enough to hold one state per character in the main buffer.
...@@ -365,354 +374,338 @@ int zconflineno = 1; ...@@ -365,354 +374,338 @@ int zconflineno = 1;
extern char *zconftext; extern char *zconftext;
#define yytext_ptr zconftext #define yytext_ptr zconftext
static yyconst flex_int16_t yy_nxt[][19] = static yyconst flex_int16_t yy_nxt[][18] =
{ {
{ {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0 0, 0, 0, 0, 0, 0, 0, 0
}, },
{ {
11, 12, 13, 14, 12, 12, 15, 12, 12, 12, 11, 12, 13, 14, 12, 12, 15, 12, 12, 12,
12, 12, 12, 12, 12, 12, 12, 12, 12 12, 12, 12, 12, 12, 12, 12, 12
}, },
{ {
11, 12, 13, 14, 12, 12, 15, 12, 12, 12, 11, 12, 13, 14, 12, 12, 15, 12, 12, 12,
12, 12, 12, 12, 12, 12, 12, 12, 12 12, 12, 12, 12, 12, 12, 12, 12
}, },
{ {
11, 16, 16, 17, 16, 16, 16, 16, 16, 16, 11, 16, 16, 17, 16, 16, 16, 16, 16, 16,
16, 16, 16, 18, 16, 16, 16, 16, 16 16, 18, 16, 16, 16, 16, 16, 16
}, },
{ {
11, 16, 16, 17, 16, 16, 16, 16, 16, 16, 11, 16, 16, 17, 16, 16, 16, 16, 16, 16,
16, 16, 16, 18, 16, 16, 16, 16, 16 16, 18, 16, 16, 16, 16, 16, 16
}, },
{ {
11, 19, 20, 21, 19, 19, 19, 19, 19, 19, 11, 19, 20, 21, 19, 19, 19, 19, 19, 19,
19, 19, 19, 19, 19, 19, 19, 19, 19 19, 19, 19, 19, 19, 19, 19, 19
}, },
{ {
11, 19, 20, 21, 19, 19, 19, 19, 19, 19, 11, 19, 20, 21, 19, 19, 19, 19, 19, 19,
19, 19, 19, 19, 19, 19, 19, 19, 19 19, 19, 19, 19, 19, 19, 19, 19
}, },
{ {
11, 22, 22, 23, 22, 24, 22, 22, 24, 22, 11, 22, 22, 23, 22, 24, 22, 22, 24, 22,
22, 22, 22, 22, 22, 22, 22, 25, 22 22, 22, 22, 22, 22, 22, 25, 22
}, },
{ {
11, 22, 22, 23, 22, 24, 22, 22, 24, 22, 11, 22, 22, 23, 22, 24, 22, 22, 24, 22,
22, 22, 22, 22, 22, 22, 22, 25, 22 22, 22, 22, 22, 22, 22, 25, 22
}, },
{ {
11, 26, 27, 28, 29, 30, 31, 32, 30, 33, 11, 26, 27, 28, 29, 30, 31, 32, 30, 33,
34, 35, 36, 36, 37, 38, 39, 40, 41 34, 35, 35, 36, 37, 38, 39, 40
}, },
{ {
11, 26, 27, 28, 29, 30, 31, 32, 30, 33, 11, 26, 27, 28, 29, 30, 31, 32, 30, 33,
34, 35, 36, 36, 37, 38, 39, 40, 41 34, 35, 35, 36, 37, 38, 39, 40
}, },
{ {
-11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11, -11,
-11, -11, -11, -11, -11, -11, -11, -11, -11 -11, -11, -11, -11, -11, -11, -11, -11
}, },
{ {
11, -12, -12, -12, -12, -12, -12, -12, -12, -12, 11, -12, -12, -12, -12, -12, -12, -12, -12, -12,
-12, -12, -12, -12, -12, -12, -12, -12, -12 -12, -12, -12, -12, -12, -12, -12, -12
}, },
{ {
11, -13, 42, 43, -13, -13, 44, -13, -13, -13, 11, -13, 41, 42, -13, -13, 43, -13, -13, -13,
-13, -13, -13, -13, -13, -13, -13, -13, -13 -13, -13, -13, -13, -13, -13, -13, -13
}, },
{ {
11, -14, -14, -14, -14, -14, -14, -14, -14, -14, 11, -14, -14, -14, -14, -14, -14, -14, -14, -14,
-14, -14, -14, -14, -14, -14, -14, -14, -14 -14, -14, -14, -14, -14, -14, -14, -14
}, },
{ {
11, 45, 45, 46, 45, 45, 45, 45, 45, 45, 11, 44, 44, 45, 44, 44, 44, 44, 44, 44,
45, 45, 45, 45, 45, 45, 45, 45, 45 44, 44, 44, 44, 44, 44, 44, 44
}, },
{ {
11, -16, -16, -16, -16, -16, -16, -16, -16, -16, 11, -16, -16, -16, -16, -16, -16, -16, -16, -16,
-16, -16, -16, -16, -16, -16, -16, -16, -16 -16, -16, -16, -16, -16, -16, -16, -16
}, },
{ {
11, -17, -17, -17, -17, -17, -17, -17, -17, -17, 11, -17, -17, -17, -17, -17, -17, -17, -17, -17,
-17, -17, -17, -17, -17, -17, -17, -17, -17 -17, -17, -17, -17, -17, -17, -17, -17
}, },
{ {
11, -18, -18, -18, -18, -18, -18, -18, -18, -18, 11, -18, -18, -18, -18, -18, -18, -18, -18, -18,
-18, -18, -18, 47, -18, -18, -18, -18, -18 -18, 46, -18, -18, -18, -18, -18, -18
}, },
{ {
11, 48, 48, -19, 48, 48, 48, 48, 48, 48, 11, 47, 47, -19, 47, 47, 47, 47, 47, 47,
48, 48, 48, 48, 48, 48, 48, 48, 48 47, 47, 47, 47, 47, 47, 47, 47
}, },
{ {
11, -20, 49, 50, -20, -20, -20, -20, -20, -20, 11, -20, 48, 49, -20, -20, -20, -20, -20, -20,
-20, -20, -20, -20, -20, -20, -20, -20, -20 -20, -20, -20, -20, -20, -20, -20, -20
}, },
{ {
11, 51, -21, -21, 51, 51, 51, 51, 51, 51, 11, 50, -21, -21, 50, 50, 50, 50, 50, 50,
51, 51, 51, 51, 51, 51, 51, 51, 51 50, 50, 50, 50, 50, 50, 50, 50
}, },
{ {
11, 52, 52, 53, 52, -22, 52, 52, -22, 52, 11, 51, 51, 52, 51, -22, 51, 51, -22, 51,
52, 52, 52, 52, 52, 52, 52, -22, 52 51, 51, 51, 51, 51, 51, -22, 51
}, },
{ {
11, -23, -23, -23, -23, -23, -23, -23, -23, -23, 11, -23, -23, -23, -23, -23, -23, -23, -23, -23,
-23, -23, -23, -23, -23, -23, -23, -23, -23 -23, -23, -23, -23, -23, -23, -23, -23
}, },
{ {
11, -24, -24, -24, -24, -24, -24, -24, -24, -24, 11, -24, -24, -24, -24, -24, -24, -24, -24, -24,
-24, -24, -24, -24, -24, -24, -24, -24, -24 -24, -24, -24, -24, -24, -24, -24, -24
}, },
{ {
11, 54, 54, 55, 54, 54, 54, 54, 54, 54, 11, 53, 53, 54, 53, 53, 53, 53, 53, 53,
54, 54, 54, 54, 54, 54, 54, 54, 54 53, 53, 53, 53, 53, 53, 53, 53
}, },
{ {
11, -26, -26, -26, -26, -26, -26, -26, -26, -26, 11, -26, -26, -26, -26, -26, -26, -26, -26, -26,
-26, -26, -26, -26, -26, -26, -26, -26, -26 -26, -26, -26, -26, -26, -26, -26, -26
}, },
{ {
11, -27, 56, -27, -27, -27, -27, -27, -27, -27, 11, -27, 55, -27, -27, -27, -27, -27, -27, -27,
-27, -27, -27, -27, -27, -27, -27, -27, -27 -27, -27, -27, -27, -27, -27, -27, -27
}, },
{ {
11, -28, -28, -28, -28, -28, -28, -28, -28, -28, 11, -28, -28, -28, -28, -28, -28, -28, -28, -28,
-28, -28, -28, -28, -28, -28, -28, -28, -28 -28, -28, -28, -28, -28, -28, -28, -28
}, },
{ {
11, -29, -29, -29, -29, -29, -29, -29, -29, -29, 11, -29, -29, -29, -29, -29, -29, -29, -29, -29,
-29, -29, -29, -29, -29, 57, -29, -29, -29 -29, -29, -29, -29, 56, -29, -29, -29
}, },
{ {
11, -30, -30, -30, -30, -30, -30, -30, -30, -30, 11, -30, -30, -30, -30, -30, -30, -30, -30, -30,
-30, -30, -30, -30, -30, -30, -30, -30, -30 -30, -30, -30, -30, -30, -30, -30, -30
}, },
{ {
11, 58, 58, -31, 58, 58, 58, 58, 58, 58, 11, 57, 57, -31, 57, 57, 57, 57, 57, 57,
58, 58, 58, 58, 58, 58, 58, 58, 58 57, 57, 57, 57, 57, 57, 57, 57
}, },
{ {
11, -32, -32, -32, -32, -32, -32, 59, -32, -32, 11, -32, -32, -32, -32, -32, -32, 58, -32, -32,
-32, -32, -32, -32, -32, -32, -32, -32, -32 -32, -32, -32, -32, -32, -32, -32, -32
}, },
{ {
11, -33, -33, -33, -33, -33, -33, -33, -33, -33, 11, -33, -33, -33, -33, -33, -33, -33, -33, -33,
-33, -33, -33, -33, -33, -33, -33, -33, -33 -33, -33, -33, -33, -33, -33, -33, -33
}, },
{ {
11, -34, -34, -34, -34, -34, -34, -34, -34, -34, 11, -34, -34, -34, -34, -34, -34, -34, -34, -34,
-34, -34, -34, -34, -34, -34, -34, -34, -34 -34, -34, -34, -34, -34, -34, -34, -34
}, },
{ {
11, -35, -35, -35, -35, -35, -35, -35, -35, -35, 11, -35, -35, -35, -35, -35, -35, -35, -35, -35,
-35, 60, 61, 61, -35, -35, -35, -35, -35 -35, 59, 59, -35, -35, -35, -35, -35
}, },
{ {
11, -36, -36, -36, -36, -36, -36, -36, -36, -36, 11, -36, -36, -36, -36, -36, -36, -36, -36, -36,
-36, 61, 61, 61, -36, -36, -36, -36, -36 -36, -36, -36, -36, 60, -36, -36, -36
}, },
{ {
11, -37, -37, -37, -37, -37, -37, -37, -37, -37, 11, -37, -37, -37, -37, -37, -37, -37, -37, -37,
-37, -37, -37, -37, -37, 62, -37, -37, -37 -37, -37, -37, -37, -37, -37, -37, -37
}, },
{ {
11, -38, -38, -38, -38, -38, -38, -38, -38, -38, 11, -38, -38, -38, -38, -38, -38, -38, -38, -38,
-38, -38, -38, -38, -38, -38, -38, -38, -38 -38, -38, -38, -38, 61, -38, -38, -38
}, },
{ {
11, -39, -39, -39, -39, -39, -39, -39, -39, -39, 11, -39, -39, 62, -39, -39, -39, -39, -39, -39,
-39, -39, -39, -39, -39, 63, -39, -39, -39 -39, -39, -39, -39, -39, -39, -39, -39
}, },
{ {
11, -40, -40, 64, -40, -40, -40, -40, -40, -40, 11, -40, -40, -40, -40, -40, -40, -40, -40, -40,
-40, -40, -40, -40, -40, -40, -40, -40, -40 -40, -40, -40, -40, -40, -40, -40, 63
}, },
{ {
11, -41, -41, -41, -41, -41, -41, -41, -41, -41, 11, -41, 41, 42, -41, -41, 43, -41, -41, -41,
-41, -41, -41, -41, -41, -41, -41, -41, 65 -41, -41, -41, -41, -41, -41, -41, -41
}, },
{ {
11, -42, 42, 43, -42, -42, 44, -42, -42, -42, 11, -42, -42, -42, -42, -42, -42, -42, -42, -42,
-42, -42, -42, -42, -42, -42, -42, -42, -42 -42, -42, -42, -42, -42, -42, -42, -42
}, },
{ {
11, -43, -43, -43, -43, -43, -43, -43, -43, -43, 11, 44, 44, 45, 44, 44, 44, 44, 44, 44,
-43, -43, -43, -43, -43, -43, -43, -43, -43 44, 44, 44, 44, 44, 44, 44, 44
}, },
{ {
11, 45, 45, 46, 45, 45, 45, 45, 45, 45, 11, 44, 44, 45, 44, 44, 44, 44, 44, 44,
45, 45, 45, 45, 45, 45, 45, 45, 45 44, 44, 44, 44, 44, 44, 44, 44
}, },
{ {
11, 45, 45, 46, 45, 45, 45, 45, 45, 45, 11, -45, -45, -45, -45, -45, -45, -45, -45, -45,
45, 45, 45, 45, 45, 45, 45, 45, 45 -45, -45, -45, -45, -45, -45, -45, -45
}, },
{ {
11, -46, -46, -46, -46, -46, -46, -46, -46, -46, 11, -46, -46, -46, -46, -46, -46, -46, -46, -46,
-46, -46, -46, -46, -46, -46, -46, -46, -46 -46, 46, -46, -46, -46, -46, -46, -46
}, },
{ {
11, -47, -47, -47, -47, -47, -47, -47, -47, -47, 11, 47, 47, -47, 47, 47, 47, 47, 47, 47,
-47, -47, -47, 47, -47, -47, -47, -47, -47 47, 47, 47, 47, 47, 47, 47, 47
}, },
{ {
11, 48, 48, -48, 48, 48, 48, 48, 48, 48, 11, -48, 48, 49, -48, -48, -48, -48, -48, -48,
48, 48, 48, 48, 48, 48, 48, 48, 48 -48, -48, -48, -48, -48, -48, -48, -48
}, },
{ {
11, -49, 49, 50, -49, -49, -49, -49, -49, -49, 11, 50, -49, -49, 50, 50, 50, 50, 50, 50,
-49, -49, -49, -49, -49, -49, -49, -49, -49 50, 50, 50, 50, 50, 50, 50, 50
}, },
{ {
11, 51, -50, -50, 51, 51, 51, 51, 51, 51, 11, -50, -50, -50, -50, -50, -50, -50, -50, -50,
51, 51, 51, 51, 51, 51, 51, 51, 51 -50, -50, -50, -50, -50, -50, -50, -50
}, },
{ {
11, -51, -51, -51, -51, -51, -51, -51, -51, -51, 11, 51, 51, 52, 51, -51, 51, 51, -51, 51,
-51, -51, -51, -51, -51, -51, -51, -51, -51 51, 51, 51, 51, 51, 51, -51, 51
}, },
{ {
11, 52, 52, 53, 52, -52, 52, 52, -52, 52, 11, -52, -52, -52, -52, -52, -52, -52, -52, -52,
52, 52, 52, 52, 52, 52, 52, -52, 52 -52, -52, -52, -52, -52, -52, -52, -52
}, },
{ {
11, -53, -53, -53, -53, -53, -53, -53, -53, -53, 11, -53, -53, 54, -53, -53, -53, -53, -53, -53,
-53, -53, -53, -53, -53, -53, -53, -53, -53 -53, -53, -53, -53, -53, -53, -53, -53
}, },
{ {
11, -54, -54, 55, -54, -54, -54, -54, -54, -54, 11, -54, -54, -54, -54, -54, -54, -54, -54, -54,
-54, -54, -54, -54, -54, -54, -54, -54, -54 -54, -54, -54, -54, -54, -54, -54, -54
}, },
{ {
11, -55, -55, -55, -55, -55, -55, -55, -55, -55, 11, -55, 55, -55, -55, -55, -55, -55, -55, -55,
-55, -55, -55, -55, -55, -55, -55, -55, -55 -55, -55, -55, -55, -55, -55, -55, -55
}, },
{ {
11, -56, 56, -56, -56, -56, -56, -56, -56, -56, 11, -56, -56, -56, -56, -56, -56, -56, -56, -56,
-56, -56, -56, -56, -56, -56, -56, -56, -56 -56, -56, -56, -56, -56, -56, -56, -56
}, },
{ {
11, -57, -57, -57, -57, -57, -57, -57, -57, -57, 11, 57, 57, -57, 57, 57, 57, 57, 57, 57,
-57, -57, -57, -57, -57, -57, -57, -57, -57 57, 57, 57, 57, 57, 57, 57, 57
}, },
{ {
11, 58, 58, -58, 58, 58, 58, 58, 58, 58, 11, -58, -58, -58, -58, -58, -58, -58, -58, -58,
58, 58, 58, 58, 58, 58, 58, 58, 58 -58, -58, -58, -58, -58, -58, -58, -58
}, },
{ {
11, -59, -59, -59, -59, -59, -59, -59, -59, -59, 11, -59, -59, -59, -59, -59, -59, -59, -59, -59,
-59, -59, -59, -59, -59, -59, -59, -59, -59 -59, 59, 59, -59, -59, -59, -59, -59
}, },
{ {
11, -60, -60, -60, -60, -60, -60, -60, -60, -60, 11, -60, -60, -60, -60, -60, -60, -60, -60, -60,
-60, 66, 61, 61, -60, -60, -60, -60, -60 -60, -60, -60, -60, -60, -60, -60, -60
}, },
{ {
11, -61, -61, -61, -61, -61, -61, -61, -61, -61, 11, -61, -61, -61, -61, -61, -61, -61, -61, -61,
-61, 61, 61, 61, -61, -61, -61, -61, -61 -61, -61, -61, -61, -61, -61, -61, -61
}, },
{ {
11, -62, -62, -62, -62, -62, -62, -62, -62, -62, 11, -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
}, },
{ {
11, -63, -63, -63, -63, -63, -63, -63, -63, -63, 11, -63, -63, -63, -63, -63, -63, -63, -63, -63,
-63, -63, -63, -63, -63, -63, -63, -63, -63 -63, -63, -63, -63, -63, -63, -63, -63
},
{
11, -64, -64, -64, -64, -64, -64, -64, -64, -64,
-64, -64, -64, -64, -64, -64, -64, -64, -64
},
{
11, -65, -65, -65, -65, -65, -65, -65, -65, -65,
-65, -65, -65, -65, -65, -65, -65, -65, -65
},
{
11, -66, -66, -66, -66, -66, -66, -66, -66, -66,
-66, 61, 61, 61, -66, -66, -66, -66, -66
}, },
} ; } ;
...@@ -732,8 +725,8 @@ static void yy_fatal_error (yyconst char msg[] ); ...@@ -732,8 +725,8 @@ static void yy_fatal_error (yyconst char msg[] );
*yy_cp = '\0'; \ *yy_cp = '\0'; \
(yy_c_buf_p) = yy_cp; (yy_c_buf_p) = yy_cp;
#define YY_NUM_RULES 38 #define YY_NUM_RULES 37
#define YY_END_OF_BUFFER 39 #define YY_END_OF_BUFFER 38
/* This struct is not used in this scanner, /* This struct is not used in this scanner,
but its presence is necessary. */ but its presence is necessary. */
struct yy_trans_info struct yy_trans_info
...@@ -741,15 +734,15 @@ struct yy_trans_info ...@@ -741,15 +734,15 @@ struct yy_trans_info
flex_int32_t yy_verify; flex_int32_t yy_verify;
flex_int32_t yy_nxt; flex_int32_t yy_nxt;
}; };
static yyconst flex_int16_t yy_accept[67] = static yyconst flex_int16_t yy_accept[64] =
{ 0, { 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
39, 5, 4, 2, 3, 7, 8, 6, 37, 34, 38, 5, 4, 2, 3, 7, 8, 6, 36, 33,
36, 29, 33, 32, 31, 27, 26, 21, 13, 20, 35, 28, 32, 31, 30, 26, 25, 21, 13, 20,
24, 27, 11, 12, 23, 23, 18, 14, 19, 27, 23, 26, 11, 12, 22, 18, 14, 19, 26, 26,
27, 4, 2, 3, 3, 1, 6, 37, 34, 36, 4, 2, 3, 3, 1, 6, 36, 33, 35, 34,
35, 29, 28, 31, 30, 26, 15, 24, 9, 23, 28, 27, 30, 29, 25, 15, 23, 9, 22, 16,
23, 16, 17, 25, 10, 22 17, 24, 10
} ; } ;
static yyconst flex_int32_t yy_ec[256] = static yyconst flex_int32_t yy_ec[256] =
...@@ -758,16 +751,16 @@ static yyconst flex_int32_t yy_ec[256] = ...@@ -758,16 +751,16 @@ static yyconst flex_int32_t yy_ec[256] =
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 2, 4, 5, 6, 1, 1, 7, 8, 9, 1, 2, 4, 5, 6, 1, 1, 7, 8, 9,
10, 1, 1, 1, 11, 12, 12, 13, 13, 13, 10, 1, 1, 1, 11, 12, 12, 11, 11, 11,
13, 13, 13, 13, 13, 13, 13, 1, 1, 14, 11, 11, 11, 11, 11, 11, 11, 1, 1, 13,
15, 16, 1, 1, 13, 13, 13, 13, 13, 13, 14, 15, 1, 1, 11, 11, 11, 11, 11, 11,
13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
1, 17, 1, 1, 13, 1, 13, 13, 13, 13, 1, 16, 1, 1, 11, 1, 11, 11, 11, 11,
13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
13, 13, 1, 18, 1, 1, 1, 1, 1, 1, 11, 11, 1, 17, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
...@@ -861,6 +854,13 @@ static void alloc_string(const char *str, int size) ...@@ -861,6 +854,13 @@ static void alloc_string(const char *str, int size)
text[size] = 0; text[size] = 0;
} }
static void warn_ignored_character(char chr)
{
fprintf(stderr,
"%s:%d:warning: ignoring unsupported character '%c'\n",
zconf_curname(), zconf_lineno(), chr);
}
#define INITIAL 0 #define INITIAL 0
#define COMMAND 1 #define COMMAND 1
#define HELP 2 #define HELP 2
...@@ -944,7 +944,12 @@ static int input (void ); ...@@ -944,7 +944,12 @@ static int input (void );
/* Amount of stuff to slurp up with each read. */ /* Amount of stuff to slurp up with each read. */
#ifndef YY_READ_BUF_SIZE #ifndef YY_READ_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k */
#define YY_READ_BUF_SIZE 16384
#else
#define YY_READ_BUF_SIZE 8192 #define YY_READ_BUF_SIZE 8192
#endif /* __ia64__ */
#endif #endif
/* Copy whatever the last rule matched to the standard output. */ /* Copy whatever the last rule matched to the standard output. */
...@@ -952,7 +957,7 @@ static int input (void ); ...@@ -952,7 +957,7 @@ static int input (void );
/* This used to be an fputs(), but since the string might contain NUL's, /* This used to be an fputs(), but since the string might contain NUL's,
* we now use fwrite(). * we now use fwrite().
*/ */
#define ECHO fwrite( zconftext, zconfleng, 1, zconfout ) #define ECHO do { if (fwrite( zconftext, zconfleng, 1, zconfout )) {} } while (0)
#endif #endif
/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
...@@ -1132,7 +1137,7 @@ YY_RULE_SETUP ...@@ -1132,7 +1137,7 @@ YY_RULE_SETUP
YY_BREAK YY_BREAK
case 7: case 7:
YY_RULE_SETUP YY_RULE_SETUP
warn_ignored_character(*zconftext);
YY_BREAK YY_BREAK
case 8: case 8:
/* rule 8 can match eol */ /* rule 8 can match eol */
...@@ -1203,10 +1208,6 @@ BEGIN(INITIAL); current_file->lineno++; return T_EOL; ...@@ -1203,10 +1208,6 @@ BEGIN(INITIAL); current_file->lineno++; return T_EOL;
YY_BREAK YY_BREAK
case 22: case 22:
YY_RULE_SETUP YY_RULE_SETUP
/* ignore */
YY_BREAK
case 23:
YY_RULE_SETUP
{ {
const struct kconf_id *id = kconf_id_lookup(zconftext, zconfleng); const struct kconf_id *id = kconf_id_lookup(zconftext, zconfleng);
if (id && id->flags & TF_PARAM) { if (id && id->flags & TF_PARAM) {
...@@ -1218,26 +1219,22 @@ YY_RULE_SETUP ...@@ -1218,26 +1219,22 @@ YY_RULE_SETUP
return T_WORD; return T_WORD;
} }
YY_BREAK YY_BREAK
case 24: case 23:
YY_RULE_SETUP YY_RULE_SETUP
/* comment */ /* comment */
YY_BREAK YY_BREAK
case 25: case 24:
/* rule 25 can match eol */ /* rule 24 can match eol */
YY_RULE_SETUP YY_RULE_SETUP
current_file->lineno++; current_file->lineno++;
YY_BREAK YY_BREAK
case 26: case 25:
YY_RULE_SETUP YY_RULE_SETUP
YY_BREAK YY_BREAK
case 27: case 26:
YY_RULE_SETUP YY_RULE_SETUP
{ warn_ignored_character(*zconftext);
fprintf(stderr,
"%s:%d:warning: ignoring unsupported character '%c'\n",
zconf_curname(), zconf_lineno(), *zconftext);
}
YY_BREAK YY_BREAK
case YY_STATE_EOF(PARAM): case YY_STATE_EOF(PARAM):
{ {
...@@ -1245,8 +1242,8 @@ case YY_STATE_EOF(PARAM): ...@@ -1245,8 +1242,8 @@ case YY_STATE_EOF(PARAM):
} }
YY_BREAK YY_BREAK
case 28: case 27:
/* rule 28 can match eol */ /* rule 27 can match eol */
*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */ *yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
(yy_c_buf_p) = yy_cp -= 1; (yy_c_buf_p) = yy_cp -= 1;
YY_DO_BEFORE_ACTION; /* set up zconftext again */ YY_DO_BEFORE_ACTION; /* set up zconftext again */
...@@ -1257,14 +1254,14 @@ YY_RULE_SETUP ...@@ -1257,14 +1254,14 @@ YY_RULE_SETUP
return T_WORD_QUOTE; return T_WORD_QUOTE;
} }
YY_BREAK YY_BREAK
case 29: case 28:
YY_RULE_SETUP YY_RULE_SETUP
{ {
append_string(zconftext, zconfleng); append_string(zconftext, zconfleng);
} }
YY_BREAK YY_BREAK
case 30: case 29:
/* rule 30 can match eol */ /* rule 29 can match eol */
*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */ *yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
(yy_c_buf_p) = yy_cp -= 1; (yy_c_buf_p) = yy_cp -= 1;
YY_DO_BEFORE_ACTION; /* set up zconftext again */ YY_DO_BEFORE_ACTION; /* set up zconftext again */
...@@ -1275,13 +1272,13 @@ YY_RULE_SETUP ...@@ -1275,13 +1272,13 @@ YY_RULE_SETUP
return T_WORD_QUOTE; return T_WORD_QUOTE;
} }
YY_BREAK YY_BREAK
case 31: case 30:
YY_RULE_SETUP YY_RULE_SETUP
{ {
append_string(zconftext + 1, zconfleng - 1); append_string(zconftext + 1, zconfleng - 1);
} }
YY_BREAK YY_BREAK
case 32: case 31:
YY_RULE_SETUP YY_RULE_SETUP
{ {
if (str == zconftext[0]) { if (str == zconftext[0]) {
...@@ -1292,8 +1289,8 @@ YY_RULE_SETUP ...@@ -1292,8 +1289,8 @@ YY_RULE_SETUP
append_string(zconftext, 1); append_string(zconftext, 1);
} }
YY_BREAK YY_BREAK
case 33: case 32:
/* rule 33 can match eol */ /* rule 32 can match eol */
YY_RULE_SETUP YY_RULE_SETUP
{ {
printf("%s:%d:warning: multi-line strings not supported\n", zconf_curname(), zconf_lineno()); printf("%s:%d:warning: multi-line strings not supported\n", zconf_curname(), zconf_lineno());
...@@ -1308,7 +1305,7 @@ case YY_STATE_EOF(STRING): ...@@ -1308,7 +1305,7 @@ case YY_STATE_EOF(STRING):
} }
YY_BREAK YY_BREAK
case 34: case 33:
YY_RULE_SETUP YY_RULE_SETUP
{ {
ts = 0; ts = 0;
...@@ -1333,8 +1330,8 @@ YY_RULE_SETUP ...@@ -1333,8 +1330,8 @@ YY_RULE_SETUP
} }
} }
YY_BREAK YY_BREAK
case 35: case 34:
/* rule 35 can match eol */ /* rule 34 can match eol */
*yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */ *yy_cp = (yy_hold_char); /* undo effects of setting up zconftext */
(yy_c_buf_p) = yy_cp -= 1; (yy_c_buf_p) = yy_cp -= 1;
YY_DO_BEFORE_ACTION; /* set up zconftext again */ YY_DO_BEFORE_ACTION; /* set up zconftext again */
...@@ -1345,15 +1342,15 @@ YY_RULE_SETUP ...@@ -1345,15 +1342,15 @@ YY_RULE_SETUP
return T_HELPTEXT; return T_HELPTEXT;
} }
YY_BREAK YY_BREAK
case 36: case 35:
/* rule 36 can match eol */ /* rule 35 can match eol */
YY_RULE_SETUP YY_RULE_SETUP
{ {
current_file->lineno++; current_file->lineno++;
append_string("\n", 1); append_string("\n", 1);
} }
YY_BREAK YY_BREAK
case 37: case 36:
YY_RULE_SETUP YY_RULE_SETUP
{ {
while (zconfleng) { while (zconfleng) {
...@@ -1384,7 +1381,7 @@ case YY_STATE_EOF(COMMAND): ...@@ -1384,7 +1381,7 @@ case YY_STATE_EOF(COMMAND):
yyterminate(); yyterminate();
} }
YY_BREAK YY_BREAK
case 38: case 37:
YY_RULE_SETUP YY_RULE_SETUP
YY_FATAL_ERROR( "flex scanner jammed" ); YY_FATAL_ERROR( "flex scanner jammed" );
YY_BREAK YY_BREAK
...@@ -2114,8 +2111,8 @@ YY_BUFFER_STATE zconf_scan_string (yyconst char * yystr ) ...@@ -2114,8 +2111,8 @@ YY_BUFFER_STATE zconf_scan_string (yyconst char * 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 zconflex() will
* scan from a @e copy of @a bytes. * scan from a @e copy of @a bytes.
* @param bytes the byte buffer to scan * @param yybytes the byte buffer to scan
* @param len the number of bytes in the buffer pointed to by @a bytes. * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
* *
* @return the newly allocated buffer state object. * @return the newly allocated buffer state object.
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment