*** empty log message ***

original commit: 61c7b1c61b0ec9db2f840cb04f1a6e1281c21a86
tokens
Scott Owens 22 years ago
parent 877997cb5f
commit c3b300f30a

@ -17,7 +17,7 @@
;; Thus 0 <= dot-pos <= (vector-length rhs).
(define-struct item (prod dot-pos) (make-inspector))
;; gram-sym = (or/f term? non-term?)
;; gram-sym = (union term? non-term?)
;; Each term has a unique index 0 <= index < number of terms
;; Each non-term has a unique index 0 <= index < number of non-terms
(define-struct term (sym index prec) (make-inspector))
@ -27,12 +27,12 @@
(define-struct prec (num assoc) (make-inspector))
(provide/contract
(make-item (prod? (or/f false? natural-number?) . -> . item?))
(make-term (symbol? (or/f false? natural-number?) (or/f prec? false?) . -> . term?))
(make-non-term (symbol? (or/f false? natural-number?) . -> . non-term?))
(make-item (prod? (union false? natural-number?) . -> . item?))
(make-term (symbol? (union false? natural-number?) (union prec? false?) . -> . term?))
(make-non-term (symbol? (union false? natural-number?) . -> . non-term?))
(make-prec (natural-number? (symbols 'left 'right 'nonassoc) . -> . prec?))
(make-prod (non-term? (vectorof (or/f non-term? term?))
(or/f false? natural-number?) (or/f false? prec?) syntax? . -> . prod?)))
(make-prod (non-term? (vectorof (union non-term? term?))
(union false? natural-number?) (union false? prec?) syntax? . -> . prod?)))
(provide

@ -12,7 +12,7 @@
(provide/contract
(parse-input ((listof syntax?) (listof syntax?) syntax? (or/f false? syntax?) syntax? syntax? any? . -> . (is-a?/c grammar%)))
(parse-input ((listof syntax?) (listof syntax?) syntax? (union false? syntax?) syntax? syntax? any? . -> . (is-a?/c grammar%)))
(get-term-list (syntax? . -> . (listof syntax?))))
(define stx-for-original-property (read-syntax #f (open-input-string "original")))

@ -9,7 +9,7 @@
(provide/contract
(build-parser ((string? any? any? syntax? (listof syntax?) (listof syntax?)
(or/f syntax? false?) syntax? syntax?) . ->* . (any? any? any? any?))))
(union syntax? false?) syntax? syntax?) . ->* . (any? any? any? any?))))
(define (strip so)
(syntax-local-introduce

Loading…
Cancel
Save