Copy Link
Add to Bookmark
Report

AIList Digest Volume 3 Issue 089

eZine's profile picture
Published in 
AIList Digest
 · 11 months ago

AIList Digest             Monday, 8 Jul 1985       Volume 3 : Issue 89 

Today's Topics:
AI Tools - Lisp vs. C & Interlisp Comments

----------------------------------------------------------------------

Date: Wed, 3 Jul 1985 15:30 EDT
From: "Scott E. Fahlman" <Fahlman@CMU-CS-C.ARPA>
Subject: Lisp vs. C


I won't try to take issue with Richard Jennings's views on Lisp vs. C,
except to note that he is only in a position to compare one dialect of
Lisp (XLISP) to one dialect of C on some sort of MS-DOS machine --
presumably a tiny one -- for one particular kind of task with one
particular virgin programmer who had been trained in in a different way
on the two languages. His observations are probably valid for this
case, but I wouldn't draw any sweeping generalizations from this.

Lisp really requires a full-fledged environment in order to be an
attractive language. A lot of people got turned off very badly back in
the bad old days when the Lisp environment was primitive and the address
space of most machines was too small to hold the kinds of features that
we see today on the various Lisp machines. Now we are seeing the same
"turn off" among people whose exposure to Lisp consists only of using
very small Lisps on machines with only, say, 512K bytes of memory. On
such a machine, a language like C (which evolved to fit the PDP-11, a
machine whose address space is even smaller) probably is superior for
getting real work done. This phase will pass just as soon as machines
with adequate virtual memory systems become as common as PC's are today.

-- Scott Fahlman

------------------------------

Date: Wed 3 Jul 85 13:55:02-PDT
From: Christopher Schmidt <SCHMIDT@SUMEX-AIM.ARPA>
Subject: ~= re: Interlisp comments

[Forwarded from the Stanford bboard by Laws@SRI-AI.]


[...] Unfortunately at least once programming system I know of
(Interlisp) actively discourages this by making it painful to put
comments in programs. For this reason alone Interlisp disqualifies
itself as a serious programming environment.

Isn't that a little like saying that Boeing, by having tiny restrooms
disqualifies itself as a serious airplane manufacturer?

I didn't say that comments are impossible in Interlisp -- merely that
it's painful to put them in.

Pain is subjective. For my money, tracking down bogus indentation, missing
semicolons or unbalanced parentheses or misspelled symbols in a
text-editor-oriented language is ever so much more painful than commenting
Interlisp.

All of these problems associated with the syntactic sugar of most
programming languages are non-issues in Interlisp, where the interned
form is edited. For the non-Interlisper it should be explained that
in DEdit (the Interlisp-D display structure editor) the programmer
selects S-expressions with the mouse and operates on them through a menu.
Note that the user selects S-expressions; not the textual representation
of an S-expression. Eg., a user can't select a parenthesis because it
is only an artifact of the pretty-printer. Since parentheses are generated
only by the pretty-printer on redisplaying a transformed S-expression,
they can never be unbalanced. Since atoms are typically "typed" into a
program by buttoning an existing instance and using a menu command which
copies the interned pointer (not the characters of the PNAME) spelling
errors can't occur. Similarly, indenting is the job of the pretty printer--
not the programmer--and is done per-window, so editing windows may be of
different sizes. I am amused to see CADR-sized editor windows on 3600's.

For the edification of those who have not had the privilege of being
subjected to Interlisp's slavish adherence to the principle that it
should constitute an entire programming environment (as opposed to
being just another programming language living on a general purpose
computer system), one of the concomitant requirements of this philosophy
is that all operations, including editing, be done on Lisp objects.

Some of us are willing slaves.

This means that comments (which are handled by a function called *
that does not evaluate its arguments) are a part of the running program.
Thus, extreme care is required in the placement of comments. [...]

Extreme care must be taken when spelling identifiers in C programs and placing
semicolons and parentheses. Nobody said programming would be safe! <:-)

[...] In fact, because Lisp is largely a functional language, there
are relatively few safe places to put comments.

I don't think that it is unfair to ask a programmer to learn the semantics
of the programming language he is using. Given an understanding of PROGN,
COND, AND, OR, and the interpreter, I don't think it is difficult to comment
Interlisp programs at all. Anyway, the compiler catches instances where
the programmer has used a comment for its value and warns him with a message
like "Warning: value of comment used". Actually, I haven't seen this message
in a year or two. When was the last time cc barfed on a semicolon you forgot?

[...] Similarly, in the display editor on Interlisp-D, comments are
kept as far away from the executable code as possible (on the same
line) and displayed in a font which is considerably less readable than
that used for non-comments.

You have only to rebind COMMENTFONT to a larger/bolder fontclass if you
don't like the default. What font does EMACS use for comments in C programs?

This is the basis on which I justify my earlier claim that Interlisp
"discourages" comments, which I consider an undesirable goal.

As I've said too many ways above, I don't think Interlisp discourages
misplaced comments any more than C discourages misplaced semicolons.

--Christopher Schmidt

------------------------------

Date: Sat 6 Jul 85 00:01:40-PDT
From: Peter Karp <KARP@SUMEX-AIM.ARPA>
Subject: Interlisp comments

[Forwarded from the Stanford bboard by Laws@SRI-AI.]

The Interlisp manual contains roughly 25 chapters which average
approximately 25 pages each. These are big pages with closely
packed type. The Interlisp environment has been evolving for
almost 20 years. This should suggest to you that it is a rich
and complex entity.

Are we really expected to take seriously the proposition that
we shouldn't use this language because it doesn't let you put
comments anywhere you please? [...]

------------------------------

Date: Fri 5 Jul 85 16:24:29-PDT
From: Christopher Schmidt <SCHMIDT@SUMEX-AIM.ARPA>
Subject: ~= re: Interlisp comments

[Forwarded from the Stanford bboard by Laws@SRI-AI.]

[...]


We're not talking about syntactic sugar or ease of use. We're talking
about a limitation on the functionality of the programming environment.

My mistake then. I think that C comments are the epitome of syntactic sugar;
discarded by the cc parser as if they never existed. And rather than
Interlisp's being a programming environment that "holds comments in contempt"
I would go so far as to claim that it gives them MORE respect than
unix/EMACS/C. In the unix/EMACS/C environment let's say that we have an
error. unix gives us one of the many helpful error messages from the set
{bus error core dumped | segmentation error core dumped}. The user invokes
the break package (cdb) (by hand). Where are the comments now? Where is
the symbol table? The hacker only gets that if he is lucky! In Interlisp,
by contrast, one of >50 error messages is printed, a break package window
opens up, a stack trace opens up (any frame can be selected and inspected
symbolically in its own window), and a menu of break package commands is
available (in addition to the entire programming language). If one invokes
the editor from the break package (picking the function from the stack trace
with the mouse), the source code is right there; the variables can be
evaluated in the stack context of the break; and the comments are still
there! I call that esteem, not contempt. Now an Interlisp break is not
a post mortem. Within the break package one can change the variable; rewrite
a function if desired and continue the program with the new definition,
which is now THE definition. Do fixes made in cdb get incorporated into
the original source automatically?

[...]

--Christopher

------------------------------

Date: Fri 5 Jul 85 18:01:35-PDT
From: Wade Hennessey <WADE@SU-SUSHI.ARPA>
Subject: interlisp comments

[Forwarded from the Stanford bboard by Laws@SRI-AI.]

Chris' comments about the ease of debugging in INTERLISP are true of any
lisp system. They are not really relevant to greep's dislike of INTERLISP
or liking of UNIX. For example, ZETALISP uses a commenting style
similar to C, and yet it provides the same debugging functionality
of INTERLISP. There are several useful functions in ZETALISP which get
the system to find the source file where a function is defined, and then let
you start editing/examining the definition, comments and all. Thus, you
needn't make comments part of the code to make them easily accessible at
all times.

Wade

------------------------------

End of AIList Digest
********************

← previous
next →
loading
sending ...
New to Neperos ? Sign Up for free
download Neperos App from Google Play
install Neperos as PWA

Let's discover also

Recent Articles

Recent Comments

Francesco's profile picture
Francesco Arca (@Francesco)
14 Nov 2024
Congratulations :)

guest's profile picture
@guest
12 Nov 2024
It is very remarkable that the period of Atlantis’s destruction, which occurred due to earthquakes and cataclysms, coincides with what is co ...

guest's profile picture
@guest
12 Nov 2024
Plato learned the legend through his older cousin named Critias, who, in turn, had acquired information about the mythical lost continent fr ...

guest's profile picture
@guest
10 Nov 2024
الاسم : جابر حسين الناصح - السن :٤٢سنه - الموقف من التجنيد : ادي الخدمه - خبره عشرين سنه منهم عشر سنوات في كبرى الشركات بالسعوديه وعشر سنوات ...

lostcivilizations's profile picture
Lost Civilizations (@lostcivilizations)
6 Nov 2024
Thank you! I've corrected the date in the article. However, some websites list January 1980 as the date of death.

guest's profile picture
@guest
5 Nov 2024
Crespi died i april 1982, not january 1980.

guest's profile picture
@guest
4 Nov 2024
In 1955, the explorer Thor Heyerdahl managed to erect a Moai in eighteen days, with the help of twelve natives and using only logs and stone ...

guest's profile picture
@guest
4 Nov 2024
For what unknown reason did our distant ancestors dot much of the surface of the then-known lands with those large stones? Why are such cons ...

guest's profile picture
@guest
4 Nov 2024
The real pyramid mania exploded in 1830. A certain John Taylor, who had never visited them but relied on some measurements made by Colonel H ...

guest's profile picture
@guest
4 Nov 2024
Even with all the modern technologies available to us, structures like the Great Pyramid of Cheops could only be built today with immense di ...
Neperos cookies
This website uses cookies to store your preferences and improve the service. Cookies authorization will allow me and / or my partners to process personal data such as browsing behaviour.

By pressing OK you agree to the Terms of Service and acknowledge the Privacy Policy

By pressing REJECT you will be able to continue to use Neperos (like read articles or write comments) but some important cookies will not be set. This may affect certain features and functions of the platform.
OK
REJECT