You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"is default(Mu)" works fine on a variable, but runs into syntax issues on attributes...
weirdly... only for Mu.
$ perl6 -e 'my $a is default(Mu);'
$ perl6 -e 'class A { has $.a is default(Mu); }'
===SORRY!=== Error while compiling -e
Can't use unknown trait 'is default' in an attribute declaration.
at -e:1
expecting any of:
rw
readonly
box_target
leading_docs
trailing_docs
$ perl6 -e 'class A { has $.a is default(Nil); }'
$
I will be adding fudged tests to S02-names/is_default.t for this.
On Wed, 13 Sep 2017 18:27:37 -0700, bri@abrij.org wrote:
"is default(Mu)" works fine on a variable, but runs into syntax issues
on attributes...
weirdly... only for Mu.
$ perl6 -e 'my $a is default(Mu);'
$ perl6 -e 'class A { has $.a is default(Mu); }'
===SORRY!=== Error while compiling -e
Can't use unknown trait 'is default' in an attribute declaration.
at -e:1
expecting any of:
rw
readonly
box_target
leading_docs
trailing_docs
$ perl6 -e 'class A { has $.a is default(Nil); }'
$
I will be adding fudged tests to S02-names/is_default.t for this.
Migrated from rt.perl.org#132082 (status was 'resolved')
Searchable as RT132082$
The text was updated successfully, but these errors were encountered: