Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: A Macro System for Perl?

by mdillon (Priest)
on May 03, 2002 at 21:49 UTC ( #163931=note: print w/ replies, xml ) Need Help??


in reply to A Macro System for Perl?

I direct you to a thread entitled "Perl6 Macros" on perl6-language, from about a month ago: Perl6 Macros (Thread Index). You may find it worthwhile to read through the discussion.


Comment on Re: A Macro System for Perl?
Re: Re: A Macro System for Perl?
by samtregar (Abbot) on May 04, 2002 at 06:45 UTC
    The thread started interesting, but it died out well before getting to a useful design. It didn't sound to me like any of the key architects (Dan Sugaliki, for example) are taking building a macro system particularily serriously.

    -sam

      Good grief--you can do a full text transform on the source before the parser gets it, and we're giving you access to the AST to do a full symbolic transform on before it's passed on to the compiler. You can add new tokens to the parser, change the meaning of existing tokens, add new code generation for new tokens to the compiler, and change the output from the compiler for existing tokens. How much more do you want?
        None of these nice things (straight text transform, AST manipulation, adding tokens to the parser) add up to a full macro system. They will be useful tools in building a macro system but without a design we just won't get there. That's what this meditation is about, and frankly I have to mark it a failure. I guess no one out there has any clearer ideas than I do about what a macro system for Perl should look like!

        -sam

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://163931]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (14)
As of 2014-07-22 08:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (109 votes), past polls