[racket] thank you for typed racket

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Tue Feb 22 09:15:54 EST 2011

On Feb 22, 2011, at 7:43 AM, Matthias Felleisen wrote:

> 
> You should have written the compiler in ML. -- Matthias
> 

Since not even some of my oldest students understand this remark, 
let me explain this answer in gory detail. 

1. The idea that changing data definitions demand a typed language
is the oldest argument in favor of statically (soundly) typed languages 
such as ML and Haskell. It was used in the 1980s, especially by the NJ
faction. I was inundated with the argument during my CMU sabbatical in 
the mid 1990s. 

2. The idea that this is especially true for the development of a compiler
is a tad older. All the people who wanted to automatically translate some
semantic spec (usually denotation) into compilers discovered two things: 
 -- the semantics changes, especially the domains 
 -- the manual translation for exploring automatic translations suffer 
See Mitch's SPS from 1983 and Peter Mosses's dissertation in the late 70s
and many more. 

I believe that ML -- especially SML -- accumulated its local following
because all these people were writing compilers and teaching interpreters. 

3. Typed Scheme/Racket was conceived as a way to move from untyped code
to typed code so that we could eventually enjoy the same advantages as
ML and Haskell during maintenance (1). But it is definitely a language
that compromises with this idea. The compromise is visible in many 
usage aspects. The only way to defend these compromising weaknesses 
is to point to its true role in our tool chain. 

So for someone to say "I wrote a compiler and TR was good for it" 
seems to completely miss the point. It would be a true and deserved
compliment if the post read like this 

 -- I wrote a compiler 
 -- I benefited from TR because ... 
 -- And I need X Y and Z from R because pedestrian languages 
	such as ML and Haskell don't support it 

As is, it is almost a two-edged compliment. A mean-spirited MLer 
or Haskeller -- not that there are any -- would and should reply 
with "told you so. You should have used ML or Haskell and you 
would have been even more productive." 

-- Matthias



Posted on the users mailing list.