Author: Stan Eisenstat
Subject: Re: [Cs323] grammar function
Date: Friday, 25 Sep 2020, 09:00:50
> Message Posted By: Unknown > > In simple, how does "[suffix] TEXT" work? Does this mean that we keep > calling looking for TEXT until it errors and then text? The rule [suffix] = TEXT / [redirect] / [suffix] TEXT / [suffix] [redirect] matches a maximal sequence of TEXT tokens and [redirect]'s. That is, it eats tokens until it finds one that cannot be part of a TEXT or [redirect]. ===== > So if we see "t1 t2 t3 t4" as input, would simple see a TEXT at t1, and > then do TEXT SUFFIX starting at t2? And then would it be in SUFFIX that > parsley finds t3 and t4 as argv[2] and argv[3]? No. It would see the TEXT t1, which is a [suffix]. Then it would see the TEXT t2, which means that it should treat "t1 t2" as a [suffix]. Then it would see the TEXT t3, ... . --Stan-PREV INDEX NEXT