Tuesday, August 02, 2005

Stupid keywords

I spent like 20 minutes trying to figure out what I was doing wrong with the syntax of pattern matching in Ocaml, only to discover the problem wasn't with pattern matching at all: I was trying to bind the name val, which is a keyword in ML:
let (key, val) = List.find( ... )
Learning a new language is such a pain. I thought I'd grown out of stupid problems like this. You almost can't blame developers for resisting learning new technologies.

6 comments:

  1. Anonymous10:53 PM

    Hey Dave,

    Usually a decent syntax highlighter helps with that problem. If it turns blue, it's a bad variable name =)

    (How come you're learning OCaml?)

    ReplyDelete
  2. That's a good point. In my case, I'm forced to work with a minimal emacs installation over SSH on someone else's Linux box, because I'm playing with alphaCaml and that was the only place I could get it installed. So I don't even have an Ocaml mode.

    How come you're learning Ocaml?

    I'm working with alphaCaml, because I'm interested in languages that deal with binders.

    ReplyDelete
  3. Anonymous4:15 AM

    Awesome. Funny enough, I've been interested in the same topic lately. In particular, higher order abstract syntax. alphaCaml is on my list.

    ReplyDelete
  4. All right, you convinced me. I got X-forwarding set up and I have my precious syntax highlighting. So much better.

    ReplyDelete
  5. Thanks for sharing this amazing post. Keep check this: https://packagessite.pk/ufone-whatsapp-packages/

    ReplyDelete
  6. I am not positive where you are getting your info, however great topic. I must spend a while learning much more or figuring out more. Thank you for fantastic information I was on the lookout for this info for my mission. 경마

    ReplyDelete