Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

more about identifier terms

  • Loading branch information...
1 parent 0321dd8 commit 0bfe5ecd7adfc7cbe9344576dfd5fb80b389be34 @moritz moritz committed
Showing with 28 additions and 0 deletions.
  1. +28 −0 lib/terms.pod
28 lib/terms.pod
@@ -95,6 +95,17 @@ TODO
=head1 Identifier terms
+There are built-in identifier terms in Perl 6, which are listed below.
+In addition one can add new identifier terms with the syntax
+ sub term:<fourty-two> { 42 };
+ say fourty-two
+or as constants
+ constant forty-two = 42;
+ say fourty-two
=head2 self
Inside a method, C<self> refers to the invocant (i.e. the object the method
@@ -109,4 +120,21 @@ Returns an L<Instant> object representing the current time.
Returns a pseudo-random L<Num> in the range C<0..^1>.
+=head2 pi
+Returns the number C<pi>, i.e. the ratio between circumference and diameter of
+a circle.
+=head2 e
+Returns Euler's number
+=head2 i
+Returns the imaginary unit (for L<Complex> numbers).
+=head1 Variables
+Variables are discussed in L<variable language docs |/language/variables>.
=end pod

0 comments on commit 0bfe5ec

Please sign in to comment.
Something went wrong with that request. Please try again.