[Haskell-cafe] Re: Type-level arithmetic

Steve Schafer steve at fenestra.com
Fri Oct 12 13:52:36 EDT 2007


On Fri, 12 Oct 2007 18:24:38 +0100, you wrote:

>I was actually thinking more along the lines of a programming language 
>where you can just write
>
>  head :: (n > 1) => List n x -> x
>
>  tail :: List n x -> List (n-1) x
>
>  (++) :: List n x -> List m x -> List (n+m) x
>
>and so forth.

How, then, is that any different from a general-purpose programming
language? You're just drawing the "line in the sand" in a different
place. You end up with a programming system where compilation is a "side
effect" of executing the "real" program.

Steve Schafer
Fenestra Technologies Corp.
http://www.fenestra.com/


More information about the Haskell-Cafe mailing list