Re: Teaching compilers backwards?

Joachim Durchholz <joachim.durchholz@web.de>
12 Oct 2003 19:03:01 -0400

          From comp.compilers

Related articles
Teaching compilers backwards? andy@galois.com (Andy Gill) (2003-09-23)
Re: Teaching compilers backwards? Trevor.Jenkins@suneidesis.com (2003-09-27)
Re: Teaching compilers backwards? rbates@southwind.net (Rodney M. Bates) (2003-10-04)
Re: Teaching compilers backwards? hat@se-126.se.wtb.tue.nl (Albert Hofkamp) (2003-10-08)
Re: Teaching compilers backwards? rmatthewk@hotmail.com (2003-10-08)
Re: Teaching compilers backwards? joachim.durchholz@web.de (Joachim Durchholz) (2003-10-12)
Re: Teaching compilers backwards? peter_flass@yahoo.com (Peter Flass) (2003-10-13)
Re: Teaching compilers backwards? Brian.Inglis@SystematicSw.ab.ca (Brian Inglis) (2003-10-13)
Re: Teaching compilers backwards? michael.l.ross@intel.com (Michael Ross) (2004-03-11)
Re: Teaching compilers backwards? rand@rice.edu (Randy Crawford) (2004-03-15)
Re: Teaching compilers backwards? zork_666@nospammail.net (Johnathan) (2004-03-15)
Re: Teaching compilers backwards? romesamo@earthlink.net (Rome Samo) (2004-03-19)
[9 later articles]
| List of all articles for this month |
From: Joachim Durchholz <joachim.durchholz@web.de>
Newsgroups: comp.compilers
Date: 12 Oct 2003 19:03:01 -0400
Organization: Oberberg Online Infosysteme
References: 03-09-073 03-10-014 03-10-041
Keywords: courses
Posted-Date: 12 Oct 2003 19:03:01 EDT

Matthew K. wrote:
> It seems like it would be a good idea to me. I recently just started
> learning about compilers, and I did not see a connection between
> lexical scanning and code generation. If you teach the students to
> read in input and translate it in the same pass, then they might
> better see this connection.


I have learned compiler construction the traditional way (first
lexing, then parsing, then tree decoration and code generation). I
saw this as a way to gradually increase the computer's "knowledge"
about a text, and found each step a delightful insight of its
own. This might be a case of personal preference.


Note that teaching compilers in a forward manner can also be presented
in the "spread-the-gap" manner suggested by Albert in his post above,
as follows:


Lexical scanning: searching for words, stemming, simple prettyprinting,
syntax highlighting.
Parsing: searching for structures (declarations), various code
transformations, structure-based prettyprinting.
Decorating: Source-to-source transformations such as refactoring, code
analysis.
Code generation: full compiler.


Regards,
Jo


Post a followup to this message

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