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

CSE 401 Autumn 2001 (Henry)

[Home] [Admin] [Details] [Help] [Other]

Assignment #3 (Lexical Theory and Practice)

($Revision: 1.5 $)

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

Due Monday, October 22, 2001

  1. Read Chapter 1 of the text book (ASU). Skim chapter 2. Read sections 3.1, 3.3-3.7.

  2. ASU 3.7abch. (You may not use the not operator for h.)

  3. ASU 3.16cd

  4. ASU 3.17 (for 3.16cd only). Be sure to use Algorithm 3.2.

  5. Extend the description of the PL/0 lexical structure to include these new language features, and hand in your revised description. See also the PL/0 Project Description.

    • Extend the PL/0 lexical specification to accomodate comments, per the lexical specification described in the project description.

    • Extend the PL/0 lexical specification to accomodate the new reserved words needed for all extensions to the base PL/0 language.

  6. Extend the implementation of PL/0 scanner to scan the extended language. Use the -T option to stop compiling after scanning. You will also likely be interested in the -t option that prints tokens as they are read, and perhaps the -c (print characters) and -l (print lines) options.

    Follow the instructions on Printing Code in the Help section of the web page. Be sure to highlight your differences so that we can easily find them when we dig through your source code.

    For all implementation projects, you will be graded on correctness of your implementation, on clarity and good design of your implementation.

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

401admin at cs.washington.edu