=begin pod :kind("Language") :subkind("Language") :category("reference")

=TITLE Glossary

=SUBTITLE Glossary of Raku terminology

X<|Abstract Class>
=head1 Abstract class

The generic Computer Science term "abstract class" defines the
L<interface|#Interface> or L<API|#API> of a class. In Raku, this is
implemented using L<roles|#Roles> with L<stubbed|#Stub> methods.

    role Canine {
        method bark { ... }          # the ... indicates a stub
    }

    class Dog does Canine {
        method bark { say "woof" }   # *MUST* be implemented by class
    }

X<|Advent Calendar>
=head1 Advent calendar

In the context of Raku, a yearly set of blog posts for each day from
the 1st until the 25th of December, to be found at
L<https://raku-advent.blog>.

X<|Adverb>
=head1 Adverb

Generically, an adverb is a named argument to a function. There are
also some specific syntax forms that allow adverbs to be tucked into
some convenient places:

=for code :preamble<my @h>
q:w"foo bar";   # ":w" is a Quotelike form modifier adverb
m:g/a|b|c/;     # ":g" is too
@h{3}:exists;   # ":exists" is too, but is known as a subscript adverb

Adverbs are usually expressed with colon pair notation, and for this
reason colon pair notation is also known as the adverbial pair form:

    :a(4)          # Same as "a" => 4

Some other forms that use a colon in ways that have adverb-like
semantics are called adverbial forms. One special form starts with an
integer value, followed by a name (for the key):

    :20seconds     # same as seconds => 20

Also see L<#Colon pair and colon list>.

X<|Adverbial Pair>
=head1 Adverbial pair

A generalized form of C<pair notation>. They all start with the colon,
as shown in the following examples:

=begin table
  adverbial pair  | pair notation
  ================|==============
    :foo<bar>     | foo => 'bar'
    :foo(42)      | foo => 42
    :42foo        | foo => 42
    :$foo         | foo => $foo
    :foo          | foo => True
    :!foo         | foo => False
=end table

Also see L<#Adverb> and L<#Colon pair and colon list>.

X<|Allomorph>
=head1 Allomorph

A type that has two related values which may be used depending on the
context. For example L<IntStr|/type/IntStr> allomorph C<is> both
an L<Int|/type/Int> and a L<Str|/type/Str>, so it will be accepted by
anything that expects an C<Int>, a C<Str>, or an C<IntStr>. Keep in mind
that certain constructs, such as L<sets, bags, and mixes|/language/setbagmix>
care about object identity, and so will not accept an allomorph as equivalent
of its components alone.

The I<allomorph> types L<IntStr|/type/IntStr>, L<NumStr|/type/NumStr>,
L<RatStr|/type/RatStr> and L<ComplexStr|/type/ComplexStr> may be created
as a result of parsing a string quoted with angle brackets:

    say <42>.^name;     # OUTPUT: «IntStr␤»
    say <42.1e0>.^name; # OUTPUT: «NumStr␤»
    say <42.1>.^name;   # OUTPUT: «RatStr␤»

B<Note>: angle brackets can also be used to create literals for which you'd
normally need to use some operator (e.g. C</> for L<Rat|/type/Rat> or C<+> for
L<Complex|/type/Complex>). This allows you to use such literals in places where
expressions are not allowed, for example, as literals in signatures:

=for code :skip-test<syntax error>
# Wrong, can't use an operator there:
multi foo (1/3) { say "It's one third!" }
=for code
# Right, a Rat literal:
multi foo (<1/3>) { say "It's one third!" }

If you I<do> want an allomorph and not a literal L<Numeric|/type/Numeric>, then
include whitespace around angle brackets:

    say <42/1>.^name;    # OUTPUT: «Rat␤»
    say <42+0i>.^name;   # OUTPUT: «Complex␤»
    say < 42+0i >.^name; # OUTPUT: «ComplexStr␤»
    say < 42/1 >.^name;  # OUTPUT: «RatStr␤»

Please see L<the Numerics page|/language/numerics#Allomorphs> for a more
complete description on how to work with these allomorphs.

X<|Anonymous>
=head1 Anonymous

A subroutine, method or submethod is called I<anonymous> if it can't be
called by name.

    # named subroutine
    sub double($x) { 2 * $x };

    # anonymous subroutine, stored in a named scalar
    my $double = sub ($x) { 2 * $x };

Note that it is still allowed to have a name, but you cannot call it by
that name:

=for code
# anonymous, but knows its own name
my $s = anon sub triple($x) { 3 * $x }
say $s.name;        # OUTPUT: «triple␤»
=for code :skip-test<illustrates error>
say triple(42);     # OUTPUT: «Undeclared routine: triple␤»

X<|API>
=head1 API

Application Programming Interface. Ideally, someone using your system or
library should be able to do so with knowledge only of the API, but not
necessarily knowing anything about the internals or the implementation details.

See also L<#Abstract class>.

X<|Apocalypse>
=head1 Apocalypse

A document originally written by L<#TimToady>, in which he processed the
initial barrage of RFCs that came out of the Perl community. Now only kept
as a historical document for reference. See also L<#Exegesis> and
L<#Synopsis>.

X<|Arity>
=head1 Arity

The number of L<positional|/type/Positional> operands expected by an
L<operator|#Operator>, subroutine, method or callable block.

=begin code :preamble<class Foo {}>
sub infix:<+>(Foo $a, Foo $b) { $a.Int + $b.Int }  # arity of "+" is 2
sub frobnicate($x) { ... }                         # arity of 1
sub the-answer() { 42 }                            # arity of 0
-> $key, $value { ... }                            # arity of 2
=end code

The arity of a C<Callable> is one of the main selectors in
L<multi-dispatch|#Multi-dispatch>.

X<|ASCII operator>
=head1 ASCII operator
X<|Texas operator>
=begin comment
“Texas” was used in the past but is now discouraged.
Remove the link when “Texas” goes completely out of use.
=end comment

The ASCII variant of a non-ASCII Unicode L<operator|#Operator> or
L<symbol|#Symbol>.
For instance, C<(elem)> corresponds to the C<∈> ("Is this an element of
that set?") operator that comes from set theory. ASCII operators are a
workaround to the problem that people don't know how to type Unicode yet.
Culturally, while we encourage people to use the Unicode symbols in a
vague sort of way, we do not disparage the use of the
L<ASCII variants|/language/unicode_ascii>.
Well, maybe just a little...

X<|Autothreading>
=head1 Autothreading

Autothreading is what happens if you pass a L<Junction|/type/Junction> to
a subroutine that expects a parameter of type L<Any|/type/Any> or a subtype
thereof (such as anything L<Cool|/type/Cool>). The call is then executed for
each value of the junction. The result of these calls is assembled in a new
junction of the same type as the original junction.

    sub f($x) { 2 * $x };
    say f(1|2|3) == 4;    # OUTPUT: «any(False, True, False)␤»

Here C<f()> is a sub with one parameter, and since it has no explicit type,
it is implicitly typed as C<Any>. The C<Junction> argument causes the
C<f(1|2|3)> call to be internally executed as C<f(1)|f(2)|f(3)>, and the
resulting junction is C<2|4|6>. These are then all compared to C<4>,
resulting in a junction C<False|True|False>. This process of separating
junction arguments into multiple calls to a function is called
I<autothreading>.

If you use the resulting junction in a Boolean context, such as with an
C<if>, it collapses into a single Boolean which is C<True> if any of the
values in the junction are True.

=for code :preamble<sub f {};>
if f(1|2|3) == 4 {    # fires because f(2) == 4 is true
    say 'success';
}


X<|Backtracking>
=head1 Backtracking

Backtracking is the default way a regexp is matched. The engine
is allowed to explore several ways moving backward in the string
characters in order to allow every piece of a regexp
to match something.
For more information, see
L<Regexp Backtracking section|/language/regexes#Backtracking>.

X<|binder>
=head1 binder

When you pass an argument list to a function (or any other callable,
like a method or a block), the argument list gets bound to the
parameters in the signature. The code that does this is called the
I<binder>.

X<|block>
=head1 block

L<Blocks|/type/Block> are code object with its own lexical scope, which
allows them to define variables without interfering with other in the
containing block.

X<|bytecode>
=head1 bytecode

Although Raku looks like an interpreted language, since it uses the
C<#!> form to run its scripts (and they are called I<scripts>), it is
actually
L<compiled to run in a virtual machine|https://www.reddit.com/r/perl6/comments/42dkme/perl6_not_being_an_interpreted_language/>
so the compiler (currently Rakudo) generates
L<bytecode|https://en.wikipedia.org/wiki/Bytecode> that runs either in
MoarVM or the Java Virtual Machine, the two VMs currently supported.

X<|Camelia>
=head1 Camelia

A butterfly image intended primarily to represent Raku, The Language.

X<|Colon Pair>
X<|Colon List>
=head1 Colon pair and colon list

A colon pair is a shorthand syntax used to create or visually present
a L<Pair|/type/Pair> object. The two most common forms are:

    :a(4)          # Same as "a" => 4,   same as Pair.new("a", 4)
    :a<4>          # Same as "a" => "4", same as Pair.new("a", val("4"))

This is also known as the adverbial pair form.

B<Note>: when the part after the colon and before the balanced delimiters is
not a legal identifier, other semantics apply, not all of which produce
C<Pair> objects.

Two other common forms are:

    :a             # Same as :a(True)
    :!a            # Same as :a(False)

A colon list just means that a list that contains only colon pairs,
does not need commas, or even spaces:

    :a(4):c:!d:c   # Same as a => 4, c => True, d => False, c => True

Finally, if there is a variable with the same name as an intended adverbial
pair, you don't have to specify the name twice, but just specify the adverb
with the appropriate sigil:

=begin table
    variable only | same as
  ================|==============
    :$foo         | foo => $foo
    :@bar         | bar => @bar
    :%mapper      | mapper => %mapper
    :&test        | test => &test
=end table

See also L<#Adverb>.

X<|Community>
=head1 Community

See L<https://raku.org/community/> for information about how to participate
in the friendly Raku community.

X<|Damian Conway>
=head1 Damian Conway

Original author of the L<#Exegesis> (among many other things).
See also L<https://en.wikipedia.org/wiki/Damian_Conway>.

X<|decont>
=head1 decont

Short for "decontainerize", meaning to remove an item
L<from its C«Scalar» container|/language/containers>, often to obtain
L<a different behavior|https://perl6advent.wordpress.com/2017/12/02/#theoneandonly>
for items that have it.

X<|diffy>
=head1 diffy

See L<operator|#Operator>. It means the type of the operator result is
sufficiently different from its arguments that op= makes little sense.

X<|Exegesis>
=head1 Exegesis

A document originally written by L<#TheDamian>, in which he tried to explain
the L<Apocalypses|#Apocalypse> to the common (wo)man. Now only kept as an
historical document for reference. See also L<#Synopsis>.

X<|fiddly>
=head1 fiddly

Too complicated to apply a metaop to. See L<operator|#Operator>.

X<|Handle>
=head1 Handle

A handle is a data structure used to store information about some
input/output operation such as file or socket reading or writing. Raku
uses L<IO::Handle|/type/IO::Handle> as a base class for filehandles,
and L<IO::Socket|/type/IO::Socket> for sockets.

X<|Huffmanize>
=head1 Huffmanize

With reference to L<Huffman coding|https://en.wikipedia.org/wiki/Huffman_coding>,
"huffmanizing" is making things that are commonly used easier, and often shorter,
to type. With things that are used less frequently it's both less of a bother
to type longer pieces of code and often longer, more descriptive naming
is necessary to easily be reminded of what the rarely-used feature does.

For example, printing output is a common task, while performing
thread-safe atomic addition on native atomicity-safe integers is much less so.
There's a need to "huffmanize" the task printing and that's why you can do it
by just typing three letters L<put|/routine/put>. But there's no need to
"huffmanize" the rarely-needed atomic operators, which is why you type the
lengthier names, such as L<atomic-inc-fetch|/routine/atomic-inc-fetch>. The
name L<put|/routine/put> is a bit vague, but because
it's commonly used, it's easy to learn what it does. On the other hand,
the name L<atomic-inc-fetch|/routine/atomic-inc-fetch> is rarer,
and the more descriptive name helps recall its purpose better.

X<|iffy>
=head1 iffy

Often used as a Boolean value. See L<operator|#Operator>. Made via
the L<C<use> keyword|/language/modules#index-entry-use>.

X<|import>
=head1 import

Include functions from a module in the current namespace.

X<|instance>
=head1 Instance

An I<instance> of a class is also called an I<object> in some other
programming languages. It has storage for attributes and is often the return
value of a call to a method called C<new>, or a literal.

Instances of most types are defined to be C<True> e.g.,
C<defined($instance)> is C<True>.

    my Str $str = "hello";  ## this is with built-in types, e.g. Str
    if defined($str) {
        say "Oh, yeah. I'm defined.";
    }
    else {
        say "No. Something off? ";
    }

    ## if you wanted objects...
    class A {
        # nothing here for now.
    }

    my $an_instance = A.new;
    say $an_instance.defined.raku;# defined($an_instance) works too.

To put things another way, a class contains the blueprints of methods
and attributes, and an instance carries it into the real world.

X<|Interface>
=head1 Interface

An interface is an L<abstract class|#Abstract class>.

X<|Invocant>
=head1 Invocant

Caller, I<the one who calls or invokes>. The invocant of a method would
be the object on which that method is being called, or, in some cases,
the class itself. I<Invocant> is used instead of caller because the
latter refers to the I<scope>.

X<|IRC>
=head1 IRC

Internet Relay Chat. Raku developers and users usually hang out on
the C<#raku> channel of C<irc.freenode.org>. This channel is also
populated by a host of friendly bots that allow you to interact with
Raku and its codebase, as well as send delayed messages and other
goodies. Check the full list in
L<the community page of raku.org|https://raku.org/community/irc>.

X<|IRC lingo>
=head1 IRC lingo

The following terms are often used on the Raku related L<#IRC>
channels:

X<|ALAP>
=head2 ALAP

As Late As Possible

X<|autopun>
=head2 autopun

A self-referencing pun, e.g. "Are you ignorant or apathetic?" - "I don't
know, and I don't care."

X<|backlog>
=head2 backlog

That part of a discussion on an L<#IRC> channel that you've missed. If it is
not or no longer available in your IRC client, you can go to sites such as
L<http://colabti.org/irclogger/irclogger_logs/raku> to see what has been logged
for you.

X<|Bot>
=head2 Bot

A program that does automatic tasks on one or more L<#IRC> channels by
acting like a regular user (as far as the IRC server is concerned) and
performing some tasks that may involve answering to users requests.
Examples are L<#camelia>, L<#dalek> and L<#yoleaux>.

X<|compunit (glossary)>
X<|compilation unit>
=head2 Compilation unit or I<compunit>

A L<compunit|https://github.com/rakudo/rakudo/blob/master/docs/module_management.md>>
is a piece of Raku code that is analyzed and compiled as a single unit.
Typically, this piece of code will be contained in a single file, but code
inside an L<EVAL|/routine/EVAL> is also considered a compunit.

X<|DWIM>
=head2 DWIM

I<Do What I Mean>. A programming language designer motto.
The opposite of a DWIM is a L<#WAT>.

X<|flap>
=head2 flap

Sometimes a test will fail under some conditions, but not others; when this
test passes in some test runs and fails in others, it's called flapping.

X<|fossil>
=head2 fossil

Something in a generally current document that is no longer true but which
has not yet been fixed by correcting or removing it.

X<|FSVO>
=head2 FSVO

For Some Value Of...

X<|FTFY>
=head2 FTFY

Fixed That For You

X<|gradual typing>
=head2 gradual typing

You don't have to specify types of variables and parameters, but if you do,
it helps in early determination of impossible dispatches and better
optimization. See also L<https://en.wikipedia.org/wiki/Gradual_typing>.

X<|IIRC>
=head2 IIRC

If I Read (or Remember) Correctly.

X<|IMHO>
=head2 IMHO

In My Humble Opinion.

X<|IWBN>
=head2 IWBN

It Would Be Nice

X<|LHF>
=head2 LHF

Low Hanging Fruit. Usually used in the context of a (relatively) simple
task to be performed by a (relative) newbie.

X<|LGTM>
=head2 LGTM

Looks Good To Me

X<|LTA>
=head2 LTA

Less Than Awesome. Usually used in the context of an error message that
is rather non-descriptive or unrelated to the actual error.

X<|NST>
=head2 NST

No Such Thing

X<|Opt>
=head2 Opt

Short for "optimization", usually in either the context of
L<spesh|#Spesh> or JIT.

X<|PB>
=head2 PB

Short for "problem". As in "that's not the pb".

X<|PR>
=head2 PR

See L<#Pull Request>.

X<|P5>
=head2 P5

Perl 5

X<|P6>
=head2 P6

Raku (née Perl 6)

X<|RSN>
=head2 RSN

Real Soon Now.

X<|RT>
=head2 RT

Request Tracker (L<https://rt.perl.org/>). The place where all the bugs
related to L<#Rakudo> used to live. Nowadays, the Github issue tracker of
the rakudo/rakudo repository is used for that.

X<|TIMTOWTDI>
=head2 TIMTOWTDI

An alternative form of L<#TMTOWTDI>, explicitly including the "is" from
the contraction "There's".

X<|TMI>
=head2 TMI

Too Much Information.

X<|TMTOWTDI>
=head2 TMTOWTDI

"There's More Than One Way To Do It", the Perl motto.

X<|UGT>
=head2 UGT

"Universal Greeting Time" - i.e., it's always "morning".

X<|WFM>
=head2 WFM

Works For Me

X<|WIP>
=head2 WIP

Work In Progress

X<|WP>
=head2 WP

Wikipedia

X<|WW>
=head2 WW

Short for C<wrong window>. When on L<#IRC>, someone types something in
a channel that was intended for another channel, or for a private
message.

X<|Larry Wall>
=head1 Larry Wall

L<Perl's|#Perl> benevolent dictator for life, among many other things.
See also L<https://en.wikipedia.org/wiki/Larry_Wall>.

X<|Lexing>
=head1 Lexing

Performing L<lexical analysis|https://en.wikipedia.org/wiki/Lexical_analysis>,
a step which usually precedes parsing.

X<|Literal>
=head1 Literal

A I<literal> is a piece of code that directly stands for an (often built-in)
object and also refers to the object itself.

    my $x = 2;      # the 2 is a literal
    say $x;         # $x is not a literal, but a variable
    my $s = "Foo";  # the "Foo" is a literal, the $s is a variable

Different types of literals are described in
L<the syntax document|/language/syntax#Literals>.

X<|LHS>
=head1 LHS

As an acronym left-hand side, it usually refers to the left hand side of
an expression, and more specifically to the left-hand side of
expressions such as C<$lhs = "this would be the right-hand side">. Since
the left hand side of these expressions modify their value, when
something behaves as a LHS it means that it can be read and written to.

X<|lvalue>
=head1 lvalue

An I<lvalue>, or a I<left value>, is anything that can appear on the
left-hand side of the assignment operator C<=>. It is anything you
can assign to.

Typical lvalues are variables, private and C<is rw> attributes, lists of
variables and lvalue subroutines.

Examples of lvalues:

=begin table
    Declaration             lvalue          Comments

    my $x;                  $x
    my ($a, $b);            ($a, $b)
    has $!attribute;        $!attribute     Only inside classes
    has $.attrib is rw;     $.attrib
    sub a is rw { $x };     a()
=end table

Examples of things that are not lvalues:

=begin table
    3                        literals
    constant x = 3;          constants
    has $.attrib;            attributes; you can only assign to $!attrib
    sub f { }; f();          "normal" subs are not writable
    sub f($x) { $x = 3 };    error - parameters are read-only by default
=end table

These are typically called L<rvalues|#rvalue>.

X<|Mainline>
=head1 Mainline

The C<mainline> is the program text that is not part of any kind of block.

=for code :solo
use v6.c;     # mainline
sub f {
              # not in mainline, in sub f
}
f();          # in mainline again

You can also have the mainline of any package-like declarator, such as
class, L<module|/language/modules>, L<grammar|/language/grammars>, etc.
These are typically run just after the class/module/grammar have been compiled
(or when loaded from a precompiled file).

X<|Mayspec>
=head1 Mayspec

Stands for "Maybe Specification". Usually refers to existing tests in the
L<language specification|https://github.com/Raku/roast/>. The speaker
is indicating they did not check whether the test is a spectest or a propspec
test; i.e., whether the test is included in a released language specification
or is a new test, proposed for the next version of the spec.

X<|MoarVM>
=head1 MoarVM

MoarVM is short for Metamodel On A Runtime Virtual Machine.
It's a virtual machine designed specifically for L<#NQP> and
its L<MOP|/language/mop>: L<#6model>. A document about
L<the purpose of MoarVM|https://github.com/MoarVM/MoarVM/blob/master/docs/reveal.md>.
MoarVM has some similarities with the Hotspot VM so you may peruse its
L<glossary|http://openjdk.java.net/groups/hotspot/docs/HotSpotGlossary.html>
for entries missing from the present one.

X<|Multi-Dispatch>
X<|MMD>
=head1 Multi-dispatch

The process of picking a candidate for calling of a set
of L<methods|/type/Method> or L<subs|/type/Sub> that
come by the same name but with different arguments. The most narrow
candidate wins. In case of an ambiguity, a routine with C<is default> trait
will be chosen if one exists, otherwise an exception is thrown.

X<|multi-method>
=head1 multi-method

A L<method|/type/Method> that has multiple candidates going by the same name
and are subject to L<Multi-Dispatch|#Multi-dispatch>.

X<|Née>
=head1 Née

"Formerly known as".

X<|NFG>
=head1 NFG

Normal Form Grapheme is the way Raku implements graphemes, using a normal form
in which strings with the same graphemes can be easily compared in constant
time. More on that on L<this article in 6guts|https://6guts.wordpress.com/2015/04/12/this-week-unicode-normalization-many-rts/>
and an explanation of how NFG works in L<this IRC log|https://colabti.org/irclogger/irclogger_log/perl6?date=2018-04-29#l465>.

X<|Niecza>
=head1 Niecza

An implementation of Raku targeting the .NET platform. No longer actively
maintained.

X<|NQP>
=head1 Not Quite Perl

See L<#NQP>.

X<|Not Quite Perl>
=head1 NQP

NQP is a primitive language for writing subroutines and methods using a
subset of the Raku syntax. It's not intended to be a full-fledged
programming language, nor does it provide a runtime environment beyond
the basic VM primitives. Compilers (such as L<#Rakudo>) typically use
NQP to compile action methods that convert a parse tree
into its equivalent abstract syntax tree representation.

X<|NYI>
=head1 NYI

Not Yet Implemented

X<|opcode>
=head1 opcode

An opcode, or operation code, is a bytecode operation, that is, a command of
the language actually used on the virtual machine. They are not usually
intended for human consumption, but they are usually specified somewhere,
like L<this document for MoarVM|https://github.com/MoarVM/MoarVM/blob/master/docs/bytecode.markdown>.

X<|Operator>
=head1 Operator

An expression is made of operators and operands. More precisely it is made
of an operator and operands that can be subexpressions or L<#value>s.
Operators are an alternative syntax for a L<#multi-method>. With that
syntax, what would be the arguments of the function are named
operands instead. Operators are classified into
L<categories|https://design.raku.org/S02.html#Grammatical_Categories> of
categories. A category has a precedence, an arity, and can be L<#fiddly>,
L<#iffy>, L<#diffy>. Raku is very creative as to what is an operator, so
there are many categories. Operators are made of many tokens, possibly with
a subexpression. For example, C<@a[0]> belongs to the postcircumfix
category, is broken into the operand C<@a> and the postcircumfix operator
C<[0]> where C<0> is the postcircumfixed subexpression.

The C<< <O(I<...>)>  >> construction gives information about an operator
that completes the information provided by its category. Below
C<%conditional> is the category, C<< :reducecheck<ternary> >>, which
specifies calling C<.ternary> to post-process the L<parse subtree|#Parse_tree>
and C<< :pasttype<if> >> specifies the NQP L<#opcode> generated in the
AST from the parse subtree.

        <O('%conditional, :reducecheck<ternary>, :pasttype<if>')>


X<|Parse Tree>
=head1 Parse tree

A L<parse tree|https://en.wikipedia.org/wiki/Parse_tree> represents the
structure of a string or sentence according to a grammar.
L<Grammar|/type/Grammar>s in Raku output parse trees when they successfully
match a string.

X<|Parameter>
=head1 Parameter

L<Parameter|/type/Parameter> is a class to define parameters to
subroutines, method and a L<callable blocks|/type/Callable>.
As opposed to the arguments you specify when calling a
subroutine/method/callable block.

    sub foo($bar) { say $bar }     # $bar is a parameter
    foo(42);                       # 42 is an argument

X<|Parrot>
=head1 Parrot

A L<virtual machine|#Virtual_machine> designed to run Raku and other
dynamic languages. No longer actively maintained.

X<|PAST>
=head1 PAST

L<#Parrot> AST.

X<|Perl>
=head1 Perl

The Perl programming language in its many forms.

X<|Perl 6>
=head1 Perl 6

The name used for Raku before October 2019.

X<|PERL>
=head1 PERL

A way to describe L<Perl|#Perl> as a language, considered to be improper
by many in the L<Perl Community|/language/community>.

X<|POD>
=head1 POD

B<P>lain B<O>l' B<D>ocumentation, a documentation format understood by
Raku. See L<here|/language/pod> for further information.

X<|POV>
=head1 POV

Stands for "Proof Of Viability". To be included in the language specification,
a "proof of viability" implementation of the feature must exist in at least one
mostly-compliant Raku compiler.

X<|Propspec>
=head1 Propspec

Stands for "Proposed Specification". Usually refers to existing tests in the
L<language specification|https://github.com/Raku/roast/> that are proposed
for inclusion in the next release.

X<|Pull request>
=head1 Pull request

A feature of L<GitHub|https://github.com> and other git hosts like
L<GitLab|https://gitlab.com> that allows you to make patches to be
easily applied using the GitHub web user interface. It means you request
someone to do a git pull from your L<repository|#Repository> to hers. PR
is its usual acronym.

X<|property>
=head1 property

In this context, it either refers to an
L<object property|/language/objects#index-entry-Property>,
which is the value of an instance variable, or an
L<Unicode property|/language/regexes#Unicode_properties>
which are codepoint features that
allow programs to identify what kind of entity they represent, that is, if they
are a letter, or a number, or something completely different like a control
character.

X<|pugs>
=head1 pugs

L<pugs|https://en.wikipedia.org/wiki/Pugs> was one of the first
interpreters/compilers written for Raku. It was written in Haskell
by Audrey Tang.

X<|QAST>
=head1 QAST

Successor to L<#PAST> ('Q' being the next letter after 'P').

X<|Rakudo>
=head1 Rakudo

Rakudo is the name of a Raku implementation that runs on L<#MoarVM> and
the JVM. It is an abbreviation of C<Rakuda-do>, which, when translated
from Japanese, means "The Way of the Camel". Also, in Japanese, "Rakudo"
means "Paradise."

X<|Reify>
=head1 Reify

In the English language, L<reify means|https://www.dictionary.com/browse/reify>
"to convert into or regard as a concrete thing." Its meaning in Raku is very
similar, in that conceptual things, like "elements of an infinite list", get
I<reified> when you try to operate on some of them. In general, reification
means turning a potential element (be it an element in a lazy list that has not
been computed yet or a element in a container that has not been extracted) into
its actual value.

X<|Repository>
=head1 Repository

A filesystem under control of a source control management application,
usually git, that holds the sources for a project, library or
application. This file, for instance, is in
L<a GitHub repository|https://github.com/Raku/doc>. Repositories store not only
files, but also history of changes and can be used by the developing or
writing team for interaction through issues or comments to code.

In Raku context, however, a repository is also a short name for
I<compilation unit repository> and constitutes a system that locates and
loads modules, managing their installation and precompilation. They are
structured as linked lists, including chain of repositories ending in
the default C<Compunit::Repository::Installation>.

X<|RHS>
=head1 RHS

Acronym for Right-Hand Side, usually refers to the right-hand side of
assignment expressions such as C<my $bound := $rhs>.

X<|roast>
=head1 roast

The Raku L<specification tests|#test suite>, which live here:
L<https://github.com/Raku/roast/>. Originally developed for L<#pugs>,
it now serves all Raku implementations. Why roast? It's the
B<r>epository B<o>f B<a>ll B<s>pec B<t>ests.

X<|role>
=head1 Roles

Roles, mix-ins or traits define interfaces and/or implementation of
those interfaces as well as instance variables using them, and are
mixed-in when declaring classes that follow that interface. L<Abstract
classes|#Abstract_class> are particular examples of Roles where the
actual implementation is deferred to the class that uses that Role.

Roles are part of Raku's L<object system|/language/objects>, and are
declared using the
L<role|/language/objects#index-entry-declarator_role-Roles> keyword and
used in class declaration via L<does|/routine/does>.

X<|rule>
=head1 rule

(Used in regular expressions)

X<|rvalue>
=head1 rvalue

A value that can be used on the right-hand side of an assignment. See also
L<#lvalue>.

X<|SAP>
=head1 SAP

Stands for "Specification APpendices". The
L<SAP|https://github.com/Raku/roast/tree/master/APPENDICES> includes
optional tests that implementations may choose to follow, but don't
necessarily have to.

Can be used as a verb. To I<SAP> something is to place it into Specification
Appendices.

X<|Semilist>
=head1 Semilist

A semilist is a I<semicolon-separated> list like this one: C<1;3;5>, and
is actually a list of lists, with each component of the semilist being a
slice of a particular dimension. C<@array[1;3;5]> would be equivalent to
C<@array[1][3][5]>.

X<|Sigil>
=head1 Sigil

In Perl, the sigil is the first character of a variable name. It must
be either $, @, %, or & respectively for a L<scalar|/type/Scalar>,
L<array|/type/Array>, L<hash|/type/Hash>, or L<code|/type/Code>
variable. See also Twigil and role. Also sigiled variables allow short
conventions for L<variable interpolation|#Variable_interpolation> in a
double quoted string, or even postcircumfix expressions starting with
such a variable.

X<|Sigilless Variable>
=head1 Sigilless variable

L<Sigilless variables|/language/variables#index-entry-\_(sigilless_variables)>
are actually aliases to the value it is assigned to them, since they are not
containers. Once you assign a sigilless variable (using the escape
C<\>), its value cannot be changed.

X<|Spesh>
=head1 Spesh

A functionality of the L<#MoarVM> platform that uses runtime gathered
data to improve commonly used pieces of L<#bytecode>. It is much like a
JIT compiler, except that those usually output machine code rather than
bytecode.

X<|STD>
=head1 STD

C<STD.pm> is the "standard" Raku grammar definition (see
L<https://github.com/perl6/std/>) that was used to implement Raku.
STD.pm is no longer really a "specification" in a proscriptive sense:
it's more of a guideline or model for Raku implementations to follow.

X<|Stub>
=head1 Stub

Stubs define name and signature of methods whose implementation is
deferred to other classes.

    role Canine {
        method bark { ... }          # the ... indicates a stub
    }

Classes with stubs are L<Abstract classes|#Abstract class>.

X<|Symbol>
=head1 Symbol

Fancy alternative way to denote a name. Generally used in the context of
L<module|/language/modules>s linking, be it in the OS level, or at the
Raku L<#Virtual_machine> level for modules generated from languages
targeting these VMs. The set of imported or exported symbols is called
the symbol table.

X<|Synopsis>
=head1 Synopsis

The current human-readable description of the Raku language. Still in
development. Much more a community effort than the
L<Apocalypses|#Apocalypse> and L<Exegeses|#Exegesis> were. The current
state of the language is reflected by L<#roast>, its L<#test suite>, not
the synopses where speculative material is not always so flagged or more
recent additions have not been documented. This is even more true of
material that has not been yet implemented.

X<|Syntax Analysis>
=head1 Syntax analysis

A syntax or syntactic analysis is equivalent to
L<parsing|https://en.wikipedia.org/wiki/Parsing> a string to generate its
L<parse tree|#Parse_tree>.

X<|test suite>
=head1 Test suite

The Raku test suite is L<#roast>.

X<|TheDamian>
=head1 TheDamian

L<#IRC> screen name for L<#Damian Conway>, writer of the original
L<Exegeses|#Exegesis>.

X<|TimToady>
=head1 TimToady

L<#IRC> screen name for L<#Larry Wall>, creator of Perl. The name comes from
the pronunciation of L<#TIMTOWTDI> as a word.

X<|Token>
=head1 token

In this context, a L<C<token>|/syntax/token> is a regex that does not backtrack.
In general, L<tokens|https://en.wikipedia.org/wiki/Lexical_analysis> are
extracted from the source program while L<lexing|#Lexing>.

X<|Thunk>
=head1 Thunk

A piece of code that isn't immediately executed, but doesn't have an independent
scope.

X<|Loose>
X<|Tight>
=head1 Tight and loose precedence

In this context, tight or tighter refers to
L<precedence rules|/language/functions#index-entry-is_tighter>
and is the opposite of C<looser>. Precedence rules for new terms are
always expressed in relationship with other terms, so C<is tighter>
implies that operands with that operator will be grouped before operands
with the looser operator. Operators with
L<tight precedence|/language/operators#Tight_AND_precedence>
are grouped with priority to others and are generally tighter than most
others; loose
L<exactly the opposite|/language/traps#Loose_Boolean_operators>,
so it is always convenient to be aware of the exact precedence of all
operators used in an expression.

X<|twine>
=head1 twine

A data structure used to hold a POD string with embedded formatting
codes. For example:

=begin code
=begin pod
C<foo>
=end pod
say $=pod[0].contents[0].contents.raku;
=end code

The output will be:

=begin code
["", Pod::FormattingCode.new(type => "C", meta => [], config => {}, contents => ["foo"]),""]
=end code

N<The C<twine> is an array with an odd number of elements beginning
with a simple string, alternating with formatting code objects and
simple strings, and ending with a simple string; the formatting code
objects are interC<twine>d with the strings. The strings may be empty
(as shown in the example). A twine with no formatting code will contain
one simple string.>

X<|Type Objects>
=head1 Type objects

A
L<type object|/language/classtut#index-entry-type_object>
is an object that is used to represent a type or a class. Since in
object oriented programming everything is an object, classes are
objects too, and they inherit from L<Mu|/type/Mu>.

X<|Type Smiley>
=head1 Type smiley

A
L<type smiley|/type/Signature#Constraining_argument_definiteness>
is a suffix a type may have that indicates the definiteness of values
that can typecheck against it. This may be C<:D> to indicate that only
defined values can typecheck (i.e. instances), C<:U> to indicate that only
undefined values can typecheck (i.e. type objects), or C<:_> to indicate
that both defined and undefined values can typecheck. These resemble
emoticons, thus the name.

X<|value>
=head1 value

A value is what is actually contained in a container such as a variable.
Used in expressions such as L<lvalue|/language/glossary#lvalue>, to
indicate that that particular container can be assigned to.

X<|UB>
=head1 UB

Stands for "Undefined Behavior". In other words, it is something that
is not explicitly specified by the language specification.

X<|Value type>
=head1 Value type

A type is known as a B<value type> if it is immutable and any instance
of that type is interchangeable with any other instance "of the same
value"—that is, any instance constructed in the same way. An instance of
a value type is often I<called> a B<value> (but should not be confused
with L<#lvalue>s or L<#rvalue>s).

For example, numbers are value types, so a number constructed one place
in your program with, for instance, the literal C<3> can't be changed in
any way—it simply I<is> 3—and any later use of the literal C<3> can
safely be pointed at the same place in memory as the first with no ill
consequences.

Classes doing the roles L<Numeric|/type/Numeric> and
L<Stringy|/type/Stringy> are among a few examples of built-in value
types.

A value type is created by ensuring that an instance of the value type
is immutable (i.e., its attributes cannot be modified after
construction) and that its L«C<WHICH>|/routine/WHICH» method returns the
same thing every time an instance with the same value is constructed
(and conversely returns a different thing every time an instance with a
different value is constructed).

The language is free to optimize based on the assumption that equivalent
instances of value types are interchangeable, but you should not depend
on any such optimization. For instance, if you want
L«C<clone>|/routine/clone» to return an instance of C<self>, or you want
instance construction to be
L<memoized|https://en.wikipedia.org/wiki/Memoization> so that
re-construction of a previously-constructed value always returns the
same instance, you currently must override this behavior yourself.

(The same would hold true of object finalization, but if your instances
need special destruction behavior, you almost certainly do not actually
have a value type. Values should be thought of as "timeless" and
existing in some ideal form outside of your program's memory, like
natural values are.)

X<|Variable>
=head1 Variable

A variable is a name for a L<container|/language/containers>.

X<|Variable Interpolation>
=head1 Variable interpolation

The value of variables is interpolated into strings by simply inserting
that variable into the string:

    my $polation="polation";
    say "inter$polation";     # OUTPUT: «interpolation␤»

This might need curly braces in case it precedes some alphanumeric
characters

    my $inter="inter";
    say "{$inter}polation"; # OUTPUT: «interpolation␤»

Interpolation occurs in L<string context|/language/contexts#String>, so
a valid stringification method must exist for the class. More general
interpolation can be achieved using the
L<double q|/language/quoting#Interpolation:_qq> quoting constructs.

X<|Virtual Machine>
=head1 Virtual machine

A virtual machine is the Raku compiler entity that executes the
L<bytecode|#bytecode>. It can optimize the bytecode or generate machine code
Just in Time. Examples are L<#MoarVM>, L<#Parrot> (who are intended to run
Raku) and more generic virtual machines such as JVM and Javascript.

X<|WAT>
=head2 WAT

The opposite of a L<#DWIM>; counter-intuitive behavior. It is said
that to every DWIM there is a corresponding WAT.
See also L<https://www.destroyallsoftware.com/talks/wat>.

X<|whitespace>
=head1 whitespace

A character or group of blank characters, used to separate words. An
example is the space character « ».

X<|6model>
=head1 6model

C<6model> is used in the L<MoarVM|/language/glossary#MoarVM>, and provides
primitives used to create an object system. It is described in
L<this presentation by Jonathan Worthington|https://jnthn.net/papers/2013-yapceu-moarvm.pdf> and implemented
L<here in MoarVM|https://github.com/MoarVM/MoarVM/tree/master/src/6model>.

=end pod

# vim: expandtab softtabstop=4 shiftwidth=4 ft=perl6
