From b43f2407b8f08910d3937bf3ab3c84f37687d07b Mon Sep 17 00:00:00 2001 From: Diego Nieto Cid Date: Fri, 22 Oct 2010 00:36:51 -0300 Subject: Symbols 0..9 stand for their ascii character. * console-client/xkb/parser.y(symbolname): Shift by '0' numbers [0..9]. --- console-client/xkb/parser.y | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'console-client/xkb') diff --git a/console-client/xkb/parser.y b/console-client/xkb/parser.y index 18c14544..7ce504e5 100644 --- a/console-client/xkb/parser.y +++ b/console-client/xkb/parser.y @@ -1061,7 +1061,13 @@ symbolssect: /* Returns a keysymbols, the numberic representation. */ symbolname: IDENTIFIER { $$ = XStringToKeysym ($1); } -| NUM { $$ = $1 + '0' } +| NUM + { + if (($1 >= 0) && ($1 < 10)) + $$ = $1 + '0'; + else + $$ = $1; + } | HEX { $$ = $1; } ; -- cgit v1.2.3