On 2020-01-08 23:06, WFB wrote:
Hi Todd,
dd or .WHAT will give you that information.
dd $i;
say $i.WHAT;
Greetings
On Thu, 9 Jan 2020 at 03:58, ToddAndMargo via perl6-users
<perl6-us...@perl.org <mailto:perl6-us...@perl.org>> wrote:
Hi All,
Is there a way to ask a variable what "type" it is?
Many thanks,
-T
Hi W,
Sweet. Thank you!
> my $i="abcd"; say $i.WHAT
(Str)
> my $i="abcd"; if $i.WHAT.gist eq Q[(Str)] {say "String";}
String
Any way to get WHAT to tell me specifically that it
is an int32?
> my int32 $j=0x45; say $j.WHAT
(Int)
-T