Grossman fall 2011 that will properly expand a fall

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ssman of the grammar Dan Grossman Fall 2011 Fall 2011 –  LR(k) and subsets (SLR(k), LALR(k), …) remaining input Winter 2013 UW CSE 401 (Michael Ringenburg) 10 Basic Parsing Strategies CSE341: Programming Languages CSE341: •  Top- Down Programming Languages Lecture 1 Lecture 1 –  Begin at root with start symbol of grammar Course Course non- terminal nd expand –  Repeatedly pick a Mechanics aMechanics ML Variable Bindings ML Variable Bindings –  Success when expanded tree matches input –  LL(k) Dan Grossman Dan Grossman Fall 2011 Fall 2011 A Winter 2013 UW CSE 401 (Michael Ringenburg) 11 Top- Down Parsing CSE341: At aCSE341: ave completed (possibly 0) •  General Idea: Programming LanguagesNLanguages ny point, h Programming steps of a lePmost ecture 1 L derivaVon Lecture 1 S =>* wAα =>* wxy (w,x,y aCourseoMechanicss string of any re strings Course Mechanics f terminals, α i symbols, A is a nonterminal) ML Variable Bindings ML Variable Bindings •  Basic Step: Pick some producVon as step N+1 A ::= β1 β2 … βn Dan Grossman Dan Grossman Fall 2011 that will properly expand A Fall 2011 to match the input –  Want this to be determinisVc. Winter 2013 A UW CSE 401 (Michael Ringenburg) 12 PredicVve Parsing C located a La...
View Full Document

Ask a homework question - tutors are online