Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Various typos/grammar related cleanup.
  • Loading branch information
coke committed Apr 16, 2010
1 parent 9c2ebf3 commit b7aa7a8
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 13 deletions.
6 changes: 3 additions & 3 deletions src/builtins.pod
Expand Up @@ -55,7 +55,7 @@ X<types; Rat>

C<Rat>, short for I<rational>, stores fractional numbers without loss of
precision. Because C<Rat> tracks its numerator and denominator as integers,
mathmatical operations on C<Rat>s with large components can become quite slow.
mathematical operations on C<Rat>s with large components can become quite slow.
For this reason, rationals with large denominators automatically degrade to
C<Num>.

Expand Down Expand Up @@ -90,7 +90,7 @@ The following operators are available for all number types:

Binary operators:
Operator Description
** Exponentation: $a**$b is $a to the power of $b
** Exponentiation: $a**$b is $a to the power of $b
* multiplication
/ division
div integer division
Expand Down Expand Up @@ -153,7 +153,7 @@ The following operations are available for strings:
~ concatenation: 'a' ~ 'b' is 'ab'
x replication: 'a' x 2 is 'aa'

Unary oerators:
Unary operators:
Operator Description
~ conversion to string: ~1 becomes '1'

Expand Down
2 changes: 1 addition & 1 deletion src/classes-and-objects.pod
Expand Up @@ -383,7 +383,7 @@ before finishing:

It's time to introduce the C<augment> syntax.

Also, C<!$!done> is unnecessarily hard to read if you see ! as a quasiquoting
Also, C<!$!done> is unnecessarily hard to read if you see ! as a quasi-quoting
symbol. It's a $ sandwich.

=end for
Expand Down
2 changes: 1 addition & 1 deletion src/grammars.pod
Expand Up @@ -99,7 +99,7 @@ defined later on. The symbol C<{*}> provides a hook which makes it possible to
plug in custom "actions" during the matching process. The C<#= object> and
C<#= array> markers don't influence the match in any way; they just provide
labels to make it easier for the action to determine which of the two
alternatives matched. We discuss actions in the secion "Extracting
alternatives matched. We discuss actions in the section "Extracting
data", below.

The following calls are straightforward, and reflect the structure in which
Expand Down
8 changes: 4 additions & 4 deletions src/operators.pod
Expand Up @@ -131,7 +131,7 @@ operator, it is applied to a list piece by piece. So C<[max] 1, 5, 3, 7> is
the same as C<1 max 5 max 3 max 7> and evaluates to C<7>.

Likewise you can write C<[+]> to get the sum of a list of values, C<[*]> for
the product, and use C<< [<=] >> to check if a list is ordered ascendingly.
the product, and use C<< [<=] >> to check if a list is ordered ascending.

After the C<[max]> you see the expression C<@scores».key».chars>. Just like
C<@variable.method> calls a method on the C<@variable>, C<@array».method>
Expand All @@ -157,8 +157,8 @@ X<meta operator; reduction>
X<meta operator; []>

The square brackets are called the I<reduction meta operator>: it transforms
the enclosed infix operator into an operator that exepects a list (a
I<listop>), and carries out the operation between each two conscutive list
the enclosed infix operator into an operator that expects a list (a
I<listop>), and carries out the operation between each two consecutive list
items.

For plotting the names of the players and bar charts, the program needs to
Expand Down Expand Up @@ -221,7 +221,7 @@ characters.

=head1 A Word on Precedence

X<operator precdence>
X<operator precedence>
X<precedence>

The explanations of the example above have one implication, which was not yet
Expand Down
2 changes: 1 addition & 1 deletion src/preface.pod
Expand Up @@ -53,7 +53,7 @@ Archive Network); Perl is community (perl5porters, perl6-language).
These are things that both Perl 5 and Perl 6 will share to varying
degrees. Also, due to Perl's habit of stealing good ideas, Perl 5 and
Perl 6 will converge in some areas as Perl 5 borrows ideas from Perl 6
and vice versa.
and vice-versa.

=head1 Perl 6 implementations

Expand Down
6 changes: 3 additions & 3 deletions src/roles.pod
Expand Up @@ -118,7 +118,7 @@ simple commands.

=head1 What is a role?

Previous chapters have explained classes and grammers. A role is another type
Previous chapters have explained classes and grammars. A role is another type
of package. Like classes and grammars, a role can contain methods (including
named regexes) and attributes. However, a role cannot stand on its own. To use
a role, you must incorporate it into an object, a class, or a grammar.
Expand Down Expand Up @@ -151,7 +151,7 @@ X<composition; conflicts>

Take a look at the C<KarmaKeeper> class definition. The body is empty; the
class defines no attributes or methods of its own. The class inherits from
C<IRCBot>, using the C<is> trait modifier -- something familiar from ealier
C<IRCBot>, using the C<is> trait modifier -- something familiar from earlier
chapters -- but it also uses the C<does> trait modifier to compose two roles
into the class.

Expand Down Expand Up @@ -258,7 +258,7 @@ Just as the C<*> quantifier in regexes means "zero or more", the C<.*> dispatch
operator will call zero or more matching methods. If no C<on-message> multi
candidates match, the call will not produce an error. If more than one
C<on-message> multi candidate matches, Perl will call all of them, whether
found by multiple dispatch, searching the inheritance hierarch, or both.
found by multiple dispatch, searching the inheritance hierarchy, or both.

There are two other variants. C<.+> greedily calls all methods but dies if
there is not at least one method that matches. C<.?>, which tries to call one
Expand Down

0 comments on commit b7aa7a8

Please sign in to comment.