[plt-scheme] to define, or to let

From: Bradd W. Szonye (bradd+plt at szonye.com)
Date: Sat Mar 20 23:30:58 EST 2004

Bradd wrote:
>> Some of those are comparable; some aren't. PLT's letrec behavior is
>> what C/C++ standards gurus call a "quiet change." If you switch to a
>> Scheme that doesn't support threads, it's obvious pretty quickly; you
>> immediately know that you need to find some kind of replacement
>> behavior. Quiet changes are different; you don't realize that there's
>> a problem until your program starts acting goofy in ways that are
>> difficult to track down.

Eli Barzilay wrote:
> I don't know (and certainly don't care) about C/C++ standards, their
> gurus, and their quiet or noisy changes.

What's up with the parochial tone? Quiet changes are a major risk factor
for language implementors and users. While you may reasonably not care
about C/C++ stuff, and you may not have heard about "quiet changes"
before, it's quite foolish to ignore wisdom from another community just
because it's another community.

> In MzScheme there are lots of extensions to what is specified in R5RS,
> and more than that -- R5RS is slim enough that any implementation that
> does not add its own extensions is an unrealistic one.

Adding extensions is fine, but quiet changes are dangerous.

> Having said that, I don't see any quitness problem -- open up the
> MzScheme manual, and all places that have some extensions are clearly
> specified.

Just because it's documented doesn't mean that it isn't quiet. Indeed,
quiet changes normally *are* documented. A feature is "quiet" when you
can't tell whether it exists at compile time. If you don't notice it in
the docs, you won't know about the problem until it breaks at runtime.

If you port to a Scheme without threads, most good compilers will at
least warn you before running. If you port to a Scheme without the
letrec extension, you won't know until your program breaks.

> It's easy -- search the help-desk for `foo', and if it is found in the
> R5RS and in the MzScheme manual, then this is probably an instance of
> standard behavior in R5RS and an extension discussed in MzScheme.
> `letrec' will get you to where the extensions are defined.

That's missing the point. How will a user even know to look for the
extension? Consider what happens when you port a large project to a new
compiler. "Quiet" changes require intimate knowledge of both
implementations and a careful code review. If you miss any of the
changes, the compiler can't help you. "Noisy" changes are preferable
because they break early and visibly in testing.

> Is there anything "less quiet" that is needed? Is there any
> implementation that doesn't change things in a well-advertised way?

First, I wouldn't call the letrec extension "well-advertised." The
compiler doesn't report it at all, and the docs don't make any special
note of it. Second, the only thing that counts as "well-advertised" for
a change is a compiler diagnostic.

> Is there any implementation that does *exactly* R5RS, nothing more,
> nothing less? And the most important question: Is there any point in
> continuing this thread?

Definitely not, if you're only going to contribute this kind of rant.
You obviously did not understand what "quiet change" means, yet you went
on for a screenful spewing bile at the idea, apparently just because it
came from the C/C++ community.
Bradd W. Szonye

Posted on the users mailing list.