Proposal3: Make $_ a valid identifier character

Bijan Parsia bparsia at email.unc.edu
Mon May 29 23:31:47 UTC 2000


On Tue, 30 May 2000, Richard A. O'Keefe wrote:

[snip]
> I suppose one key difference is whether you intend a multi-word identifier
> to be percieved as multiple words (as I do) or as a single `word'.

Yes, this *is* key. I intend, and I do read them as a single word. That
proper nouns (classes) are capitalized reinforces this.

It's clearly not ideal in every case. But I think consistency in this
matter, and pressure it brings toward shorter, coherent indentifiers, is a
good thing. Having two sorts of word separator (for "inside" and
"between" identifiers) has also been proven, by extensive studies which I
have completely invented on the spot, to cause type declarations in lab
rats.

And we know what *that* leads to.

> Let us not lose sight of the fact that Smalltalk (like Pascal) originally
> didn't include low lines because it simply _couldn't_; the first version
> of ASCII just plain didn't include them.

Really? This is historically correct? With all the wierd glyphs, I'm
surprised. Can you give a source (or would someone form SqCentral care to
comment)?

[snip]
> Clinging to BaStudlyCaps because "that's the way it has always been done
> in Smalltalk" (as another person suggested)

I really presume you mean me as the "another person" and that wasn't quite
my argument. It couldn't be since ANSI and VisualWorks and other
Smalltalks *do* use the underscore in identifiers. I fact I *clearly*
lamented. So, unless you were referring to someone else, I'd appreciate
not having *moronic* arguments attributed to me.

I've worked with Smalltalk with $_s in indentifiers and without. I very
much prefer the latter.

(I even pointed to a preference, if one must bend, for $-s rather
than $'_s

> would be like insisting that
> Fortran stick with 6-letter identifiers forever.  Thank goodness the F90
> committee didn't swallow that kind of argument.

Thank goodness no one is *making* such an argument. Although, if 6-letter
identifiers had a, to some peoples eye, a good effect on style and
readability, then it would be a reasonable argument.

Sheesh.

FWIW, some means of transparently dealing with underscore scarred code
would be welcome. And certainly, in non-code browsers in Squeak, having
arrows where there should be underscores is annoying. I grant that there
are problems to be solved. But I'd still rather deal with them then deal
with loads of underscore infected identifiers.

(Getting the capitalization wrong annoys me as well, I'll add. Period
delimited namespaces would annoy.)

So, let's agree that we differ, and that I exist to  make your reading
life a living hell ;)

What's next? Braces?

Cheers,
Bijan Parsia,
WhiningGrunt, firstClass,
Society for the Preservation of the Smalltalk Assignment.





More information about the Squeak-dev mailing list