You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
527 B
Racket
20 lines
527 B
Racket
#lang racket/base
|
|
|
|
(module+ test
|
|
|
|
(require yaragg/examples/whitespace
|
|
yaragg/support
|
|
rackunit)
|
|
|
|
(check-equal?
|
|
(parse-to-datum "\ty\n x\tz\r")
|
|
'(start (tab "\t") (letter "y") (newline "\n") (space " ") (letter "x") (tab "\t") (letter "z") (return "\r")))
|
|
|
|
(check-equal?
|
|
(parse-to-datum "\t\n \t\r")
|
|
'(start (tab "\t") (newline "\n") (space " ") (tab "\t") (return "\r")))
|
|
|
|
(check-equal?
|
|
(parse-to-datum "\a\b\t\n\v\f\r\e")
|
|
'(start (all "\a" "\b" "\t" "\n" "\v" "\f" "\r" "\e"))))
|