On 4/28/20, shane c <[email protected]> wrote:
> I think require/typed/provide in typed/rackunit is affecting the location
> grabbing feature. Hoping someone can provide a suggested path forward. When
>
> I run this program,
>
> #lang typed/racket/base
>
> (require typed/rackunit)
> (check-true (string<? "aaaa" "bbbb"))
> (check-true (string<? "aaaa" "aabb"))
> (check-true (string<? "aaaa" "aa"))
>
> The last expression turns out to be (check-true #f) so an error is printed.
>
> However the error location points to rackunit source.
>
> --------------------
> string<?
> FAILURE
> name:       check-true
> location:
>   /Applications/Racket
> v7.6/share/pkgs/rackunit-typed/rackunit/main.rkt:33:2
> params:     '(#f)
> --------------------
>
> I can switch to (require rackunit) in #lang racket/base and the location
> points to the source file as expected.
>
> P.S. thanks for all your hard work. -shane

Right, require/typed/provide is turning off the location tracking.

Possible fix: add a `check-true` macro to typed/rackunit that calls
the require/typed `check-true` inside of a `(with-check-info ....)`
The macro should also set the check expression.

Can you open an issue for this in the rackunit repo?

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/CAFUu9R5TOR_YRES5NjV6VB1v8ywHnQgQqrm38s0DjPSb67vo9w%40mail.gmail.com.

Reply via email to