Skip to content

Commit

Permalink
Revises text and closes #2704
Browse files Browse the repository at this point in the history
  • Loading branch information
JJ committed Apr 3, 2019
1 parent 20330bd commit 45ed253
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions doc/Language/syntax.pod6
Expand Up @@ -583,9 +583,9 @@ or an explicit base in adverbial notation like C<< :16<A0> >> specifies it
otherwise. Unlike other programming languages, leading zeros do I<not> indicate
base 8; instead a compile-time warning is issued.
In all literal formats, you can use underscores to group digits; they
don't carry any semantic information; the following literals all
evaluate to the same number:
In all literal formats, you can use underscores to group digits, although they
don't carry any semantic information; the following literals all evaluate to the
same number:
=begin code :skip-test
1000000
Expand All @@ -594,21 +594,21 @@ evaluate to the same number:
100_00_00
=end code
=head4 Int literals
=head4 C<Int> literals
Integers default to signed base-10, but you can use other bases. For details,
see L<Int|/type/Int>.
=begin code :skip-test
# actually not a literal, but unary - operator applied to numeric literal 2
# not a single literal, but unary - operator applied to numeric literal 2
-2
12345
0xBEEF # base 16
0o755 # base 8
:3<1201> # arbitrary base, here base 3
=end code
=head4 Rat literals
=head4 C<Rat> literals
L<Rat|/type/Rat> literals (rationals) are very common, and take the
place of decimals or floats in many other languages. Integer division
Expand All @@ -623,7 +623,7 @@ also results in a C<Rat>.
2/3 # Not actually a literal, but still a Rat
=end code
=head4 Num literals
=head4 C<Num> literals
Scientific notation with an integer exponent to base ten after an C<e> produces
L<floating point number|/type/Num>:
Expand All @@ -636,7 +636,7 @@ L<floating point number|/type/Num>:
2e2.5 # error
=end code
=head4 Complex literals
=head4 C<Complex> literals
L<Complex|/type/Complex> numbers are written either as an imaginary number
(which is just a rational number with postfix C<i> appended), or as a sum of
Expand All @@ -648,7 +648,7 @@ a real and an imaginary number:
=end code
X<|Pairs (literals)>
=head3 Pair literals
=head3 X<Pair literals>
L<Pairs|/type/Pair> are made of a key and a value, and there are two
basic forms for constructing them: C<< key => 'value' >> and
Expand Down

0 comments on commit 45ed253

Please sign in to comment.