kconfig: don't silently ignore unhandled characters
authorJan Beulich <JBeulich@suse.com>
Tue, 20 Jan 2015 12:52:48 +0000 (12:52 +0000)
committerChristian Lamparter <chunkeey@googlemail.com>
Wed, 27 Apr 2016 14:17:14 +0000 (16:17 +0200)
At the very least we should tell people that what they wrote is not
what the utility understands.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
config/zconf.l

index 54058e07a375e4796054b6e90f2b58638ca055ff..960b1e693ed748a88d20f9c57bb3f7f410084a2e 100644 (file)
@@ -141,7 +141,12 @@ n  [A-Za-z0-9_]
        }
        #.*     /* comment */
        \\\n    current_file->lineno++;
-       .
+       [[:blank:]]+
+       .       {
+               fprintf(stderr,
+                       "%s:%d:warning: ignoring unsupported character '%c'\n",
+                       zconf_curname(), zconf_lineno(), *yytext);
+       }
        <<EOF>> {
                BEGIN(INITIAL);
        }