[racket] Getting started with R6RS

From: Stephen Bloch (sbloch at adelphi.edu)
Date: Sat May 14 18:42:45 EDT 2011

On May 14, 2011, at 5:20 PM, Elliott Cable wrote:

> 1) First off, and most importantly, the obsession with DrScheme is
> *really* off-putting for any serious developer. I know *piles* of
> programming languages, I’ve written hundreds of distinct open-source
> libraries, I know more toolsets than I can even remember; coming from
> a background like that, seeing references to an integrated IDE
> scattered through the *language documentation* itself (as if the IDE
> is a part of the language), is … alienating.

This is something that hadn't occurred to me, but I guess it makes sense: if I'm trying to learn a new language, I don't usually want to learn a new editor and a complex user interface like Eclipse at the same time.  (Of course, DrRacket is NOT a complex user interface; it was designed for beginning programmers , but I use it for most of my own Racket programming too, despite -- if not because of -- its lack of Eclipse-like bells, whistles, and sub-sub-menus.)

On the other hand, it's become fairly common for a language compiler to come with at least an interactive REPL, because it's SO much easier to experiment in that setting than with an explicit edit/compile/run loop.  So user interface issues aren't entirely irrelevant to learning a language.  In particular, having the REPL embedded in a GUI app actually makes the REPL more useful -- you can type in and see values of types that don't have nice text representations, like images, sounds, or even fractions.

On the third hand, it ought to be possible to exclude most mentions of DrRacket from the language documentation, if we think it's important to take the time to do that.

> 2) The whole “languages” thing is nearly as off-putting as the
> DrScheme obsession, but in a different way. When I come across an
> instruction saying to add `#lang racket` or `#!r6rs` at the top of the
> file, with no explanation of what that does, it feels more than a
> little bit too much like “magic.” It feels like the language trying to
> pussyfoot around inexperienced developers, hide from me operation that
> is considered ‘too complex’ for me to understand.

#lang has annoyed me for years -- not only because it's a completely different syntax from the rest of the language, but because it's a magic incantation you need to use by rote before anything you actually understand will work.

> 3) After the issues described above, I realized that the
> ‘documentation path’ I’d been following just wasn’t *for* me.

I've had problems with the organization of the documentation for years too.  Some things are in the Guide, some things are in the Reference, some things are in per-library documentation, all written in different styles.  Some parts are "written for children," as Elliott puts it, because of PLT/Racket's history of use in beginning programming courses; other parts are written for professional software developers; and still other parts seem to be reminders from one member of the Racket development team to another, incomprehensible to anybody not involved in that effort.

The history of use for beginning programming courses is also why a lot of the stuff you see on the first page of racket-lang.org is about graphics.  In the world of CS education, any language other than Java, C++, or perhaps Python has an uphill marketing battle to fight before people will even show up to the first day of class.

When one designs a Web site (or anything else with a user interface), one has to design for particular kinds of users.  User-experience books like _About Face_ go into considerable detail on how to construct "user personas", each with his/her own background and goals, and then make design decisions in light of how each of the user personas will react to them.  The racket-lang Web site needs to be accessible to several different kinds of users (in no particular order):
1) beginning programming students who have never heard of Scheme, and are baffled that anyone would want to use anything other than a "real" language like Java;
2) the parents of said students, ditto (with the difference that they won't actually be programming in it)
3) intermediate or advanced students, who know how to program (possibly in a simple subset of Scheme) and need to find out what's different about this language and what they can do with it
4) professional programmers, who want to solve problems, and need to learn quickly what they can do with this language that they couldn't do in another language
5) language geeks, who want to learn all about the language, and for whom solving problems is how you learn the language rather than an end in itself
6) current users, who want quick access to reference materials and updates, without being bothered by language stuff they already know

Elliott is presumably somewhere between #4 and #5.  Since many of the people involved are college professors, there's probably been a bit of a bias towards users #1-3.

Stephen Bloch
sbloch at adelphi.edu

Posted on the users mailing list.