Types, Programming, etc.

Blogging my Brain

Archive for February, 2007

How to write programs in two easy steps

Posted by edwinb on February 19, 2007

I’m bored, so I’m browsing the blog-o-tubes, and noticing the occasional comment wondering why functional languages like Haskell and Lisp are typically used for no more than implementing other programming languages. I won’t comment on the truth or otherwise of this claim, because I don’t think it’s a bad thing in any case. Here’s why — this is a technique I learned from Conor McBride (who learned it from his father Fred McBride), explaining how to write any computer program in two easy stages:

Read the rest of this entry »

Posted in Drunken rambling, Haskell | 10 Comments »

Stack machines

Posted by edwinb on February 11, 2007

Back in the time before at Durham, we had a snazzy whiteboard on which you could press a button and get a hard copy of your scribblings. We don’t have such a thing at St Andrews, but there are two other options. One is the smart board software, where you write onto a screen then the computer then renders it illegible for you (at least it does when I try it). My preferred way, though, is one I’ve borrowed from the Epigram gang. Just take a digital photo of the whiteboard…

At the minute, we’re trying to find a typed intermediate code for representing functional programs with explicit stack bounds. Here’s what James and I came up with on Friday:


Whiteboard scribblings

Posted in Dependent Types, Resource Aware Programming | 2 Comments »