develooper Front page | perl.perl6.users | Postings from October 2018

need doc help with []

Thread Next
October 3, 2018 00:14
need doc help with []
Message ID:
Hi All,

I use postcircumfix [] all the time.  But I don't
understand the documentation.[%20]#language_documentation_Operators

would someone please explain what the crypto line means:

sub postcircumfix:<[ ]>(@container, **@index,
                         :$k, :$v, :$kv, :$p, :$exists, :$delete)

1  Why the <[]>?  I have always used [] with out the <>.
    Why would I want to use one over the other?

2)  Where does it state that the <> is optional?

3)  What is a **@?  *@ is a slurp all remaining.   A
     super duper slurp?

4)  What is :$k, :$v, :$kv, :$p, :$exists, :$delete
     and where are they defined?

5)  Why does :$k, :$v, :$kv, :$p, :$exists, :$delete
     have colons in front of them?

6)  Where is the --> return described?

Yours in confusion,

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About