routine isa
1 | class Mu |
1.1 | (Mu) routine isa |
Documentation for routine isa
assembled from the following types:
class Mu
From Mu
(Mu) routine isa
multi method isa(Mu --> Bool)multi method isa(Str --> Bool)
Returns True
if the invocant is an instance of class $type
, a subset type or a derived class (through inheritance) of $type
. does
is similar, but includes roles.
my = 17;say .isa("Int"); # OUTPUT: «True»say .isa(Any); # OUTPUT: «True»;my = 0 but Truish;say .^name; # OUTPUT: «Int+{Truish}»say .does(Truish); # OUTPUT: «True»say .isa(Truish); # OUTPUT: «False»