LGA-08: Parsing¶
This can either be completed individually, or as a group outside of class.
Read the docstring for the
lex
function in SlytherLisp (underslyther/parser.py
. Write the tokens for this string:(print (eval ''(1 2 (3 4))) 5)
Design a set of production rules which could be used to parse SlytherLisp. Ask on Piazza if you’re stuck and need help!
Use your production rules to parse the string in Part 1 using the shift-reduce method and create a parse table.