On Tue, Feb 14, 2006 at 11:35:18AM -0800, David Romano wrote: > On 2/14/06, Luke Palmer <[EMAIL PROTECTED]> wrote: > > On 2/14/06, David Romano <[EMAIL PROTECTED]> wrote: > > > I don't want to just skip <B> tags wholly, because they do > > > serve a purpose, but only in a particular context. (Can <?ws> > > > be changed back to a "default" if > > > changed to include html tags?) > > > > Brackets serve as a kind of scoping for modifiers. We're also > > considering that :ws take an argument telling it what to consider to > > be whitespeace. So you could do: > > > > rule Month :w { > > [ :w(&my_ws) J a n ] # not sure about the & > > # out here we still have the default :w > > } > Ahh, okay. So am I to understand that my_ws would just return a set of > individual characters or character sequences that would be considered > whitespace? Or would my_ws do something else?
I would think that my_ws would be a rule of some sort: rule my_ws { [ \s+ | \< /? b \> ]* } Also, it wasn't noted in the previous post, but one can explicitly call the "default" ws rule by referring to it explicitly, as in <Rule::ws>. (Currently PGE has it as <PGE::Rule::ws>.) So, presumably one could do rule Month :w(&my_ws) { J a n # my_ws rule here [:w(&Rule::ws) . . . ] # "default" ws rule here [:w(0) . . . ] # no :w here PGE doesn't yet implement rule arguments to the :w modifier, but I bet we can add it without too much trouble. :-) Pm