File tree Expand file tree Collapse file tree 2 files changed +3
-12
lines changed
Expand file tree Collapse file tree 2 files changed +3
-12
lines changed Original file line number Diff line number Diff line change 4949
5050(struct splice-replacement (start-path replaced-children-count new-children)
5151 #:transparent
52- #:guard (struct-guard/c proper- syntax-path? exact-nonnegative-integer? (treelist/c added-syntax?))
52+ #:guard (struct-guard/c syntax-path? exact-nonnegative-integer? (treelist/c added-syntax?))
5353 #:sealed )
5454
5555
Original file line number Diff line number Diff line change 1010 [syntax-path<=> (comparator/c syntax-path?)]
1111 [empty-syntax-path? (-> any/c boolean?)]
1212 [nonempty-syntax-path? (-> any/c boolean?)]
13- [proper-syntax-path? (-> any/c boolean?)]
1413 [empty-syntax-path syntax-path?]
1514 [syntax-path (-> (sequence/c exact-nonnegative-integer?) syntax-path?)]
1615 [syntax-path-elements (-> syntax-path? (treelist/c exact-nonnegative-integer?))]
2524 [syntax-ref (-> syntax? syntax-path? syntax?)]
2625 [syntax-contains-path? (-> syntax? syntax-path? boolean?)]
2726 [syntax-set (-> syntax? syntax-path? syntax? syntax?)]
28- [syntax-remove-splice
29- (-> syntax? (and/c proper-syntax-path? nonempty-syntax-path?) exact-nonnegative-integer? syntax?)]
30- [syntax-insert-splice
31- (-> syntax? (and/c proper-syntax-path? nonempty-syntax-path?) (sequence/c syntax?) syntax?)]
27+ [syntax-remove-splice (-> syntax? nonempty-syntax-path? exact-nonnegative-integer? syntax?)]
28+ [syntax-insert-splice (-> syntax? nonempty-syntax-path? (sequence/c syntax?) syntax?)]
3229 [syntax-label-paths (-> syntax? symbol? syntax?)]))
3330
3431
9289 (check-false (nonempty-syntax-path? 42 ))))
9390
9491
95- (define (proper-syntax-path? v)
96- (and (syntax-path? v)
97- (for/and ([elem (in-treelist (syntax-path-elements v))])
98- (exact-nonnegative-integer? elem))))
9992
10093
101- ; TODO: add tests for proper-syntax-path?
102-
10394
10495(define (syntax-path-add path element)
10596 (syntax-path (treelist-add (syntax-path-elements path) element)))
You can’t perform that action at this time.
0 commit comments