Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Thoughts on the magicality of @_ and $_

by erikharrison (Deacon)
on Jun 28, 2002 at 19:21 UTC ( [id://178111]=note: print w/replies, xml ) Need Help??


in reply to Thoughts on the magicality of @_ and $_

In answer to your first question, yes, named intermediate variables are in fact alises to the list elements (which means you need to watch for modifying constants).

Second question. Yes, Perl 6 gets named parameters, and the ability to truly parse subs as builtins (except perhaps the current print FILEHANDLE LIST semantics). Check out the Apocylypses.

Cheers,
Erik

Light a man a fire, he's warm for a day. Catch a man on fire, and he's warm for the rest of his life. - Terry Pratchet

Update: Alright, my question doesn't quite answer your second question. I'm sorry, I got confused on what you meant by "pass by name". :-( I just sent a message asking for clarification to the Perl 6 language group.

Replies are listed 'Best First'.
Re: Re: Thoughts on the magicality of @_ and $_
by Juerd (Abbot) on Jun 28, 2002 at 19:39 UTC

    Yes, Perl 6 gets named parameters, and the ability to truly parse subs as builtins (except perhaps the current print FILEHANDLE LIST semantics).

    print FILEHANDLE LIST will be gone. FILEHANDLE.print(LIST) (or print FILEHANDLE : LIST) is the new syntax, as filehandles are objects.

    IFF I understand correctly.

    - Yes, I reinvent wheels.
    - Spam: Visit eurotraQ.
    

      We use a space where a comma is expected to disambiguate between several (slightly obscure) constructs. For example, indirect object notation. Of course, this is totally supportable with the lexical parsing rules changes (yum). However, the language doesn't seem to directly support user defined methods using this trick themselves.

      Cheers,
      Erik

      Light a man a fire, he's warm for a day. Catch a man on fire, and he's warm for the rest of his life. - Terry Pratchet

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2024-04-24 13:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found