Skip to content

Commit

Permalink
Correction on the sig test support code to work on Unix: strip out th…
Browse files Browse the repository at this point in the history
…e carriage returns.
  • Loading branch information
Danny Yoo committed Nov 9, 2011
1 parent e437fb9 commit 2d63ff8
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/sigs-support.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,11 @@

(define (get-text-at-srcloc a-srcloc-vector)
(define a-srcloc (apply srcloc (vector->list a-srcloc-vector)))
(substring (call-with-input-file* #:mode 'text
(srcloc-source a-srcloc)
port->string)
(substring (regexp-replace* "\r"
(call-with-input-file* #:mode 'text
(srcloc-source a-srcloc)
port->string)
"")
(sub1 (srcloc-position a-srcloc))
(+ (sub1 (srcloc-position a-srcloc))
(srcloc-span a-srcloc))))
Expand Down

0 comments on commit 2d63ff8

Please sign in to comment.