RosettaCodeData/Task/Compiler-lexical-analyzer/Ol/compiler-lexical-analyzer-2.ol

6 lines
201 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
(define (translate source)
(let ((stream (try-parse token-parser (str-iter source) #t)))
(for-each print (car stream))
(if (null? (force (cdr stream)))
(print 'End_of_input))))