[racket-dev] A Const type constructor

From: Vincent St-Amour (stamourv at ccs.neu.edu)
Date: Tue Jul 31 14:57:16 EDT 2012

At Tue, 31 Jul 2012 14:36:06 -0400,
Matthias Felleisen wrote:
> On Jul 31, 2012, at 1:31 PM, Neil Toronto wrote:
> > To reiterate after my absence: I won't write a typed math/vector
> > until using its exports in Typed Racket wouldn't be a huge friggin'
> > PITA.
> Let me rephrase this ever so gently. Typed Racket has failed at least
> one real test for now, namely, writing a highly usable math library.

Agreed. The invariance of vectors is a pretty big usability problem here.

> I think this is a fair judgment, and you are posing the obvious, not so
> implied problem to the TR maintainers to fix this problem. They should
> thank you on their knees, especially Vincent.

Yes, Sam and I should fix this.

Neil: I'll study your proposal in detail, and see how we could add it
(or something similar) to TR. Thanks for taking the time to write it out.

I'll have a look at what Scala does, too. AFAIK, they also have
invariant vectors and more than one numeric type, so they probably have
similar problems.

> > To offer a carrot instead of a stick: There could be a short paper
> > in this, titled "The Case for a Clean, Correct, Covariant Const".
> That is what I was thinking as I was reading your message. I have not
> encountered such a proposal/language before, and I think it could be a
> really neat extension of Vincent's PADL work.


> Perhaps the two of you
> should work out the details together and submit follow-up to PADL
> n+1. Oh never mind, D stands for declarative. So ship it to ICFP next
> year, functional languages do include mutation.

Sounds good to me.

Neil: let's continue this discussion off-list.


Posted on the dev mailing list.