PR 10237
svn: r14822
This commit is contained in:
parent
34c2dfe021
commit
6551dbfaa0
|
@ -80,7 +80,7 @@
|
|||
;; expressions with test suite coverage information. Returning the
|
||||
;; first argument means no tests coverage information is collected.
|
||||
|
||||
;; test-coverage-point : syntax syntax -> syntax
|
||||
;; test-coverage-point : syntax syntax phase -> syntax
|
||||
;; sets a test coverage point for a single expression
|
||||
(define (test-coverage-point body expr phase)
|
||||
(if (and (test-coverage-enabled)
|
||||
|
@ -353,14 +353,29 @@
|
|||
[(define-values names rhs)
|
||||
top?
|
||||
;; Can't put annotation on the outside
|
||||
(let ([marked (with-mark expr
|
||||
(annotate-named
|
||||
(one-name #'names)
|
||||
(syntax rhs)
|
||||
phase))])
|
||||
(let* ([marked
|
||||
(with-mark expr
|
||||
(annotate-named
|
||||
(one-name #'names)
|
||||
(syntax rhs)
|
||||
phase))]
|
||||
[with-coverage
|
||||
(let loop ([stx #'names]
|
||||
[obj marked])
|
||||
(cond
|
||||
[(not (syntax? stx)) obj]
|
||||
[(identifier? stx)
|
||||
(test-coverage-point obj stx phase)]
|
||||
[(pair? (syntax-e stx))
|
||||
(loop (car (syntax-e stx))
|
||||
(loop (cdr (syntax-e stx))
|
||||
obj))]
|
||||
[else obj]))])
|
||||
(certify
|
||||
expr
|
||||
(rebuild expr (list (cons #'rhs marked)))))]
|
||||
(rebuild
|
||||
expr
|
||||
(list (cons #'rhs with-coverage)))))]
|
||||
[(begin . exprs)
|
||||
top?
|
||||
(certify
|
||||
|
|
Loading…
Reference in New Issue
Block a user