Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
show how to check for type objects
  • Loading branch information
gfldex committed Jul 9, 2016
1 parent 1b96a0d commit 2ffe382
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion doc/Language/typesystem.pod6
Expand Up @@ -6,7 +6,15 @@
=head1 Definition of a Perl 6 Type
TODO
=head2 Type objects
To test if an object is a type object, test for definedness and check for
identity between the object and it's C<.WHAT> pseudo-method. Note that the
method C<.defined> can be overloaded and may provide false information.
my $a = Int;
say so $a // $a === $a.WHAT;
# OUTPUT«True␤»
=head1 Type Declarators
Expand Down

0 comments on commit 2ffe382

Please sign in to comment.