Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.compilers    |    Compiler construction, theory, etc. (Mod    |    2,753 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 1,873 of 2,753    |
|    Tony Finch to Rob Warnock    |
|    Re: Is that difficult to write a Shift-R    |
|    04 May 10 15:55:30    |
      From: dot@dotat.at              rpw3@rpw3.org (Rob Warnock) wrote:       >       >The "trick" to hybridizing this with recursive descent is to assign       >*very* high operator priorities to the start tokens of control expressions       >[e.g., "keywords" such as BEGIN, IF, WHILE, etc.] and *very* low priorities       >to the ends of expressions ["stoppers" such as END, ELSE, FI, right-paren,       >right-bracket, comma, semicolon, &c]. This causes the simple operator       >precedence parser to quite naturally behave as a recursive descent parser       >when it encounters any of those constructs. ;-}              This sounds a bit like the top-down operator precedence parser       that Douglas Crockford is particularly fond of.       http://javascript.crockford.com/tdop/tdop.html              Tony.       --       f.anthony.n.finch |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca