perl6/doc/lib/X/Syntax/Variable/Twigil

doc src
(title) class X::Syntax::Variable::Twigil
    class X::Syntax::Variable::Twigil does X::Syntax { }

 
Syntax error thrown when a variable with a twigil is used in an incompatible declaration. For example
    my $!foo

 
dies with
    ===SORRY!===
    Cannot use ! twigil on my variable

 

Methods

(head2) twigil
    method twigil() returns Str:D

 
Returns the twigil that was illegally used
(head2) scope
    method scope() returns Str:D

 
Returns the scope that did not harmonize with the twigil.

Perl 6 Tricks and Treats newsletter

Register to the free newsletter now, and get updates and news.
Email:
Name: