1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-12 23:00:22 +02:00

Fix Hex Constants

* module/language/ecmascript/tokenize.scm: hexadecimal constants can
    now use 'X' in addition to 'x'.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
Noah Lavine 2011-01-11 18:03:04 -05:00 committed by Ludovic Courtès
parent 110f652127
commit 326298206a

View file

@ -262,7 +262,7 @@
(c1 (peek-char port))) (c1 (peek-char port)))
(cond (cond
((eof-object? c1) (digit->number c0)) ((eof-object? c1) (digit->number c0))
((and (char=? c0 #\0) (char=? c1 #\x)) ((and (char=? c0 #\0) (or (char=? c1 #\x) (char=? c1 #\X)))
(read-char port) (read-char port)
(let ((c (peek-char port))) (let ((c (peek-char port)))
(if (not (char-hex? c)) (if (not (char-hex? c))