[racket-dev] Falling through cond clauses

From: Carl Eastlund (cce at ccs.neu.edu)
Date: Wed Oct 3 08:42:37 EDT 2012

Unless, of course, the cond is in a void-typed context.  And the error
message one gets if it isn't is about a Void type that never actually got
written down, and exists only because of cond's idiosyncratic default.  It
would be better if the type of cond's default in TR were Nothing.  Or even
better, if there were some expression in the default clause that caused TR
to raise an intelligent error message if that clause were anything but dead
code.  (For instance, if TR knew to say something special about raised
exceptions of the hypothetical struct exn:fail:cond.)

Carl Eastlund

On Wed, Oct 3, 2012 at 8:16 AM, Sam Tobin-Hochstadt <samth at ccs.neu.edu>wrote:

> On Tue, Oct 2, 2012 at 10:26 PM, Matthias Felleisen
> <matthias at ccs.neu.edu> wrote:
> >
> > The cond issue also shows up in TR. We should and will have to tackle it.
> In TR, this is less of an issue, because you get a type error when you
> unexpectedly fall off the end of a `cond`.  So I think this is in some
> ways better in TR the way it currently is.
> --
> sam th
> samth at ccs.neu.edu
> _________________________
>   Racket Developers list:
>   http://lists.racket-lang.org/dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/dev/archive/attachments/20121003/175c3f57/attachment.html>

Posted on the dev mailing list.