Re: Compiler Construction in Ada (Michael Feldman)
Sun, 10 Jan 1993 17:58:23 GMT

          From comp.compilers

Related articles
Compiler Construction in Ada (1993-01-07)
Compiler Construction in Ada (1993-01-07)
Re: Compiler Construction in Ada (1993-01-07)
Re: Compiler Construction in Ada (1993-01-07)
Re: Compiler Construction in Ada (1993-01-08)
Re: Compiler Construction in Ada (1993-01-08)
Re: Compiler Construction in Ada (1993-01-08)
Re: Compiler Construction in Ada (1993-01-10)
Re: Compiler Construction in Ada (1993-01-11)
teaching compiler design: languages and texts (Saumya K. Debray) (1993-01-11)
Re: Compiler Construction in Ada (1993-01-12)
Re: Compiler Construction in Ada (1993-01-13)
Re: Compiler Construction in Ada dtl8v@holmes.acc.Virginia.EDU (1993-01-15)
Re: Compiler Construction in Ada (1993-01-15)
[2 later articles]
| List of all articles for this month |

Newsgroups: comp.lang.ada,comp.compilers
From: (Michael Feldman)
Organization: George Washington University
Date: Sun, 10 Jan 1993 17:58:23 GMT
References: 93-01-028 93-01-048 93-01-050
Keywords: courses, Ada, books (Michael Feldman) writes:
>Others are commenting on the Sun compilers. I just hope you are using the
>Fischer/LeBlanc book, "Crafting a Compiler" (the Ada version). ... writes:
>Here's a vote _for_ Fischer/LeBlanc. It's the text for the undergrad
>compiler course at Georgia Tech, and the class project usually revolves
>around building a compiler, using a Pascal-ized lex/yacc suite for the
>parser and Pascal for the remainder.
>IMHO the discussion and description in the Ada version of LeBlanc is more
>clear and more appropriate for undergrad courses than the dragon book.

I assume that LeBlanc either taught the course or had something to do with
its structure. Undoubtedly the course and the book were better coordinated
than the one described in a previous post. It's easy when the book author
and the teacher (or course designer, anyway) are the same person :-)

But I agree with you about the clarity of the book, especially if one is
using Ada for the course, which is what Prof. Jipping had in mind.
Fischer/LeBlanc is the only compiler book acknowledging Ada as a suitable
language in which to write a compiler.

As an aside, Rational, TeleSoft, Alsys, and RR (Janus and relatives) have
all written their compilers in Ada. People I have spoken to in all these
companies confirm their satisfying experiences in using Ada for this kind
of software project. Naturally (no surprise!) I agree :-) (James Crigler) writes:
>If you can stand the book. When I took the compiler course here, we used
>the book Prof. Mike mentions and I didn't like it. Caveat: We were using
>lex/yacc to create a compiler, which is, of course (:-) the opposite
>approach to parsing. (Since I had the class they've gone back to using
>the Dragon book :-) but I can't afford a copy :-(

Well, since you did not say what you didn't like about Fischer/LeBlanc, I
can only assume that the poor fit between the book and the tools you were
using had something to do with it. Fischer/LeBlanc provides a lot of very
useful code segments, procedures, packages, etc., for "Crafting a
Compiler" in Ada. The C version of their book does the same with C, though
the language being compiled is _still_ an Ada subset.

In my opinion, your professor did you a disservice by requiring a book
that (1) used Ada as the language of discourse and (b) focused on
hand-coding a compiler, then gave you a project in which you used
lex/yacc/C to do the actual work. That caused too much "dissonance" and,
naturally, you had an unpleasant experience. Probably soured you on Ada,

Different books are written with different viewpoints and biases; books
should be selected carefully to match the intent of the course. The
original poster, Prof. Jipping, prefers the hand-coding approach, on the
grounds (I suppose) that using tools is great once you have some
understanding of how they work. Students who have hand-coded parts of
parsers and lexers really come to appreciate what yex/yacc/aflex/ayacc buy
you, and that's just the right education for undergraduates (IMHO).

Michael B. Feldman, co-chair, SIGAda Education Committee

Professor, Dept. of Electrical Engineering and Computer Science
School of Engineering and Applied Science
The George Washington University
Washington, DC 20052 USA
(202) 994-5253 (voice) (202) 994-5296 (fax) (Internet)

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.