Re: extending <% | %>
BenRifkah Bergsten-Buret <[email protected]> Fri, 15 Feb 2008 15:21:24 -0800
| Newsgroups | gmane.comp.web.mason.devel |
|---|---|
| Message-ID | <[email protected]> |
Hans Dieter Pearcey wrote: > On Fri, Feb 15, 2008 at 12:37:55PM -0800, BenRifkah Bergsten-Buret wrote: > >> However, I'm not sold that using the pipe to chain escapes is really >> necessary. I agree that the pipe symbol is great because it already >> carries the desired meaning because its used in numerous other >> contexts. However, implementing it seems to me to be more trouble than >> its worth especially since the comma is already implemented (and used in >> the wild) for chaining escapes. >> > > The problem is not having multiple pipes -- the problem is extending the syntax > of the pipe RHS. As soon as you allow '| foo(<arbitrary perl>)', the pipe is > a problem, without any chaining entering the picture. Ah. Now I see the dilemma. I was stuck on vertical bars on the LHS of the pipe. It's not a huge problem if you only have to account for pipes on the LHS, but if you allow arbitrary perl (including vertical bars) on the RHS then parsing can become a lot more difficult. If you only have to account for '| foo(<arbitrary perl>)' then you might be able to get some help from Text::Balanced. Allowing for '| foo(<arbitrary perl>) | bar(<arbitrary perl>)' would be more difficult but doable. (Not that you implied it but if you have to allow '| <arbitrary perl>' I think you're going to be SOL.) While I agree that it would be nice to allow for this arbitrary perl I think that tackling it iteratively would be a good idea. -- Ben ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/