Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env -S guile -e entrée -s
- !#
- (use-modules (ice-9 peg)
- (ice-9 textual-ports))
- (define test-pattern
- "as <- 'a'+
- bs <- 'b'+
- as-or-bs <- as/bs")
- (define (entrée args)
- (let ((peg-pattern (peg-string-compile test-pattern 'body)))
- (display (match-pattern peg-pattern "aabbcc")) (newline)))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement