[racket] Help with exception raising and testing

From: Tobias Hammer (tobias.hammer at dlr.de)
Date: Wed Aug 28 03:59:20 EDT 2013

On Tue, 27 Aug 2013 22:35:06 +0200, Asumu Takikawa <asumu at ccs.neu.edu>  
wrote:
> In addition, the test predicate should take an exception value so
> `negative?` won't work. You probably want a predicate like
> `(λ (e) (regexp-match #rx"negative?" (exn-message e)))` instead.

Slightly OT:
check-exn can directly take a regexp instead of pred but the docs for  
test-exn say it only takes a pred.
Is this an inconsistency in the implementation or the docs?

Tobias



Posted on the users mailing list.