[functional-tests/regex] fix bug in the star combinator
This commit is contained in:
parent
df09bf2cc6
commit
9202e31725
@ -72,12 +72,14 @@
|
|||||||
|
|
||||||
(define (star rx)
|
(define (star rx)
|
||||||
(let ((head (gensym))
|
(let ((head (gensym))
|
||||||
|
(body (gensym))
|
||||||
(tail (gensym)))
|
(tail (gensym)))
|
||||||
(cons (split-instr head tail)
|
(label-code head
|
||||||
(label-code head
|
(cons (split-instr body tail)
|
||||||
(append-instr rx
|
(label-code body
|
||||||
(jmp-instr head)
|
(append-instr rx
|
||||||
(label-instr tail))))))
|
(jmp-instr head)
|
||||||
|
(label-instr tail)))))))
|
||||||
|
|
||||||
(define (plus rx)
|
(define (plus rx)
|
||||||
(let ((head (gensym))
|
(let ((head (gensym))
|
||||||
|
Loading…
Reference in New Issue
Block a user