Larry Wall wrote:
> So far we've only allowed "is parsed" on the macro itself, not on
> individual arguments.  Still, that's an interesting idea.

Forgive me if this has already been addressed, but this could have some
useful applications:

So far, everything I've read about macro parsing concentrates on parsing
the positional arguments; I haven't seen anything about how to go about
defining a custom parse rule for the list arguments.  In particular, I'm
thinking about something along the lines of: 

  macro element(name, [EMAIL PROTECTED] is parsed /\s+/) 
    is parsed / \< /? (<QName>) \s* (.*?) /? \> /
    {...}

where the "is parsed" trait of the list parameter defines a rule used to
split the string fed into it into a list of arguments.  

I could see something similar being done for named parameters, but you'd
need to define both a "split" rule and a name-vs-value parse rule, and
you'd have to address if (and if so, how) a named parameter can be
inserted between positional and/or list parameters.  

=====
Jonathan "Dataweaver" Lang

__________________________________
Do you Yahoo!?
Free Pop-Up Blocker - Get it now
http://companion.yahoo.com/

Reply via email to