On Mon, Jan 20, 2020 at 22:16 ToddAndMargo via perl6-users <
[email protected]> wrote:
> On 2020-01-20 20:09, ToddAndMargo via perl6-users wrote:
> > On 2020-01-20 19:55, ToddAndMargo via perl6-users wrote:
...
> > I think this is it:
> >
> > > sub x() returns Associative { my %h= A=>"a"; return %h}
> > &x
> > > x
> > {A => a}
> ...
> Yup, too high up the food chain:
>
> > sub x() returns Hash { my %h= A=>"a"; return %h}
The preferred syntax is:
sub x(--> Hash) {...}
See that in the docs.
Larry Wall once warned that the "return..." syntax may be removed at some
point.
-Tom