Skip to content

Commit 7084956

Browse files
committed
Fix type formatting for several files.
(and some very minor textual cleanups)
1 parent 2deedb5 commit 7084956

File tree

10 files changed

+102
-103
lines changed

10 files changed

+102
-103
lines changed

doc/Programs/01-debugging.rakudoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ dd %hash, $a;
4646
=end code
4747

4848
Please note that C<dd> will ignore named parameters. You can use a
49-
C<Capture> or C<Array> to force it to dump everything passed to it.
49+
L<C<Capture>|/type/Capture> or L<C<Array>|/type/Array> to force it to dump everything passed to it.
5050

5151
=begin code :ok-test<dd>
5252
dd \((:a(1), :b(2)), :c(3));
@@ -65,7 +65,7 @@ This can be handy as a cheap trace function.
6565

6666
=head2 Using backtraces
6767

68-
The L<Backtrace|/type/Backtrace> class gets the current call stack, and can return it as
68+
The L<C<Backtrace>|/type/Backtrace> class gets the current call stack, and can return it as
6969
a string:
7070

7171
my $trace = Backtrace.new;

doc/Type/Backtrace.rakudoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
class Backtrace {}
88

99
A backtrace contains the dynamic call stack, usually leading up to a point where
10-
an exception was thrown, and is a List of L<Backtrace::Frame|/type/Backtrace::Frame> objects. Its
10+
an exception was thrown, and is a List of L<C<Backtrace::Frame>|/type/Backtrace::Frame> objects. Its
1111
default stringification excludes backtrace frames that are deemed unnecessary or
1212
confusing; for example routines like C<&die> are hidden by default. Being a
1313
list, you can also access individual elements.
@@ -114,7 +114,7 @@ frames, compiler-specific frames, and those from the setting.
114114

115115
multi method list(Backtrace:D:)
116116

117-
Returns a list of L<Backtrace::Frame|/type/Backtrace::Frame> objects for this backtrace.
117+
Returns a list of L<C<Backtrace::Frame>|/type/Backtrace::Frame> objects for this backtrace.
118118

119119
=head2 method summary
120120

doc/Type/Bag.rakudoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
class Bag does Baggy { }
88

99
A C<Bag> is an immutable bag/multiset implementing
10-
L<Associative|/type/Associative>, meaning a collection of distinct
10+
L<C<Associative>|/type/Associative>, meaning a collection of distinct
1111
elements in no particular order that each have an integer weight
1212
assigned to them signifying how many copies of that element are
13-
considered "in the bag". (For I<mutable> bags, see L<BagHash|/type/BagHash> instead.)
13+
considered "in the bag". (For I<mutable> bags, see L<C<BagHash>|/type/BagHash> instead.)
1414

1515
C<Bag>s are often used for performing weighted random selections - see
1616
L<.pick|/routine/pick> and L<.roll|/routine/roll>.
@@ -69,7 +69,7 @@ values become the associated integer weights:
6969
say $n.values.raku; # OUTPUT: «(1, 4).Seq␤»
7070

7171
Furthermore, you can get a C<Bag> by using bag operators (see next
72-
section) on objects of other types such as L<List|/type/List>, which will
72+
section) on objects of other types such as L<C<List>|/type/List>, which will
7373
act like they internally call C<.Bag> on them before performing the operation.
7474
Be aware of the tight precedence of those operators though, which may
7575
require you to use parentheses around arguments:
@@ -141,8 +141,8 @@ Creates a new C<Bag> from C<@args>.
141141

142142
=head1 Note on C<reverse> and ordering
143143

144-
This method is inherited from L<Any|/type/Any#routine_reverse>, however,
145-
C<Mix>es do not have an inherent order and you should not trust it
144+
This method is inherited from L<C<Any>|/type/Any#routine_reverse>, however,
145+
L<C<Mix>|/type/Mix>es do not have an inherent order and you should not trust it
146146
returning a consistent output.
147147

148148
=head1 See also

doc/Type/BagHash.rakudoc

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ them signifying how many copies of that element are considered "in the
1212
bag". If you do not need the mutability that a C<BagHash> provides,
1313
consider using the I<immutable> L<C«Bag»|/type/Bag> type instead.
1414

15-
An item may be a definite object of any type – not just a C<Str>. For
15+
An item may be a definite object of any type – not just a L<C<Str>|/type/Str>. For
1616
example, you can store L<C«Sub»|/type/Sub>'s in a C<BagHash>, and you
17-
will store the actual C<Sub> rather than a string with the same name
18-
as the C<Sub>. Within a C<BagHash>, items that would compare
17+
will store the actual L<C<Sub>|/type/Sub> rather than a string with the same name
18+
as the L<C<Sub>|/type/Sub>. Within a C<BagHash>, items that would compare
1919
positively with the L<===|/routine/===> operator are considered the
2020
same element, with the number of how many there were as its weight.
2121
Alternatively, you can use the C<kxxv> method to easily get back the
@@ -164,7 +164,7 @@ say $a ⊎ $b; # OUTPUT: «BagHash(2(3) 4(2) 3(2))␤»
164164
=head1 Note on C<reverse> and ordering.
165165

166166
BagHash inherits C<reverse> from L<Any|/type/Any#routine_reverse>,
167-
however, C<Bag>s do not have an inherent order and you should not trust
167+
however, L<C<Bag>|/type/Bag>s do not have an inherent order and you should not trust
168168
it returning a consistent output.
169169

170170
If you sort a BagHash, the result is a list of pairs, at which point
@@ -184,9 +184,9 @@ say $a.sort.reverse; # OUTPUT: «(18 => 1 4 => 1 3 => 1 2 => 2)␤»
184184

185185
When C<to-add> is a single item, C<add> inserts it into the C<BagHash>
186186
or, if it was already present, increases its weight by 1. When
187-
C<to-add> is a C<List>, C<Array>, C<Seq>, or any other type that
187+
C<to-add> is a L<C<List>|/type/List>, L<C<Array>|/type/Array>, L<C<Seq>|/type/Seq>, or any other type that
188188
C<does> the L<C«Iterator»|/type/Iterator> Role, C<add> inserts each
189-
element of the C<Iterator> into the C<SetHash> or increments the
189+
element of the L<C<Iterator>|/type/Iterator> into the L<C<SetHash>|/type/SetHash> or increments the
190190
weight of each element by 1.
191191

192192
I<Note:> Added in version 2020.02.
@@ -199,7 +199,7 @@ When C<to-remove> is a single item, C<remove> reduces the weight of
199199
that item by one. If this results in the item having a weight of 0,
200200
this removes the item from the C<BagHash>. If the item is not present
201201
in the C<BagHash>, C<remove> has no effect. When C<to-remove> is a
202-
C<List>, C<Array>, C<Seq>, or any other type that C<does> the
202+
L<C<List>|/type/List>, L<C<Array>|/type/Array>, L<C<Seq>|/type/Seq>, or any other type that C<does> the
203203
L<C«Iterator»|/type/Iterator> Role, C<remove> reduces the weight of
204204
each element by 1 and removes any items with the resulting weight of
205205
0.

doc/Type/Buf.rakudoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ cases where it is the best representation for a particular encoding.
4545

4646
method subbuf-rw($from = 0, $elems = self.elems - $from) is rw
4747

48-
A mutable version of C<subbuf> that returns a L<Proxy|/type/Proxy>
48+
A mutable version of C<subbuf> that returns a L<C<Proxy>|/type/Proxy>
4949
functioning as a writable reference to a part of a buffer. Its first
5050
argument, C<$from> specifies the index in the buffer from which a
5151
substitution should occur, and its last argument, C<$elems> specifies
@@ -110,7 +110,7 @@ inconsistent across different virtual machines.
110110

111111
multi method list(Buf:D:)
112112

113-
Returns a C<List> of integers.
113+
Returns a L<C<List>|/type/List> of integers.
114114

115115
say Buf.new(122,105,112,205).list; # OUTPUT: «(122 105 112 205)␤»
116116

@@ -198,9 +198,9 @@ These methods are available on the C<buf8> type only. They allow low level
198198
access to writing bytes to the underlying data and in different ways with
199199
regards to type (integer or floating point (num)), size (8, 16, 32, 64 or 128
200200
bits), signed or unsigned (for integer values) and endianness (native, little
201-
and big endianness). These methods always return C<Nil>.
201+
and big endianness). These methods always return L<C<Nil>|/type/Nil>.
202202

203-
Endianness must be indicated by using values of the L<Endian|/type/Endian>
203+
Endianness must be indicated by using values of the L<C<Endian>|/type/Endian>
204204
enum as the B<third> parameter to these methods. If no endianness is
205205
specified, C<NativeEndian> will be assumed. Other values are
206206
C<LittleEndian> and C<BigEndian>.
@@ -324,7 +324,7 @@ returned to allow for easier chaining of operations on the C<buf8> object.
324324
The buffer will be automatically resized to support any bytes being written
325325
if it is not large enough yet.
326326

327-
Endianness must be indicated by using values of the L<Endian|/type/Endian>
327+
Endianness must be indicated by using values of the L<C<Endian>|/type/Endian>
328328
enum as the B<third> parameter to these methods. If no endianness is
329329
specified, C<NativeEndian> will be assumed. Other values are
330330
C<LittleEndian> and C<BigEndian>.
@@ -435,6 +435,6 @@ C<BigEndian>.
435435

436436
Available as of the 2021.06 Rakudo compiler release.
437437

438-
Coerces the invocant into an immutable L<Blob|/type/Blob> object.
438+
Coerces the invocant into an immutable L<C<Blob|/type/Blob> object.
439439

440440
=end pod

doc/Type/Distribution/Locally.rakudoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88

99
Provides read access to specific files pointed at by a distributions metadata,
1010
providing the L<Distribution#method_content|/type/Distribution#method_content>
11-
method for L<Distribution::Path|/type/Distribution::Path> and
12-
L<Distribution::Hash|/type/Distribution::Hash>.
11+
method for L<C<Distribution::Path>|/type/Distribution::Path> and
12+
L<C<Distribution::Hash>|/type/Distribution::Hash>.
1313

1414
=head1 Methods
1515

@@ -21,7 +21,7 @@ A prefix path to be used in conjuncture with the paths found in the metadata.
2121

2222
Provides L<Distribution#method_content|/type/Distribution#method_content>
2323

24-
Returns an C<IO::Handle> to the file represented by C<$name-path>. C<$name-path>
24+
Returns an L<C<IO::Handle>|/type/IO::Handle> to the file represented by C<$name-path>. C<$name-path>
2525
is a relative path as it would be found in the metadata such as C<lib/Foo.rakumod>
2626
or C<resources/foo.txt>, and these paths will be prefixed with
2727
L<Distribution#method_prefix|#method_prefix>.

doc/Type/Distribution/Resource.rakudoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ itself, is an instance of C<Distribution::Resources>. These resources are
1313
installed as part of the standard distribution installation process; please
1414
check the definition of C<%?RESOURCES> above for more context.
1515

16-
Externally, every one of these resources behaves as an C<IO::Path>, and it
17-
shares many of the same methods; however, it's really I<not> an C<IO::Path>
16+
Externally, every one of these resources behaves as an L<C<IO::Path>|/type/IO::Path>, and it
17+
shares many of the same methods; however, it's really I<not> an L<C<IO::Path>|/type/IO::Path>
1818
and thus cannot be smartmatched to it.
1919

2020
This variable will work with the current repository chain structure, and will
@@ -110,7 +110,7 @@ on the type of distribution, and in any case C<.key> will return the name of
110110
the resources pseudo-hash key.
111111

112112
Please note also that accessing the resource via its key will return a handle
113-
on the resource, which gists to a C<IO::Path> but is, in fact, a
113+
on the resource, which gists to a L<C<IO::Path>|/type/IO::Path> but is, in fact, a
114114
C<Distribution::Resource> object. Looking again at the "regular" resources,
115115
the path it translates to will be the same as the one declared in
116116
C<resources> in META6.json, but it will change for "library" resources
@@ -124,7 +124,7 @@ it represents, such as a file, for instance
124124
=for code
125125
my @data = %?RESOURCES<data/swim.csv>.lines.split(",");
126126

127-
However, this is I<not> because it returns a C<IO::Path>, but because it
127+
However, this is I<not> because it returns a L<C<IO::Path>|/type/IO::Path>, but because it
128128
shares many method with it: C<Str, gist, raku, absolute, is-absolute,
129129
relative, is-relative, parts, volume, dirname, basename, extension, open,
130130
resolve, slurp, lines, comb, split, words, copy>; above we use C<.lines>, for
@@ -151,7 +151,7 @@ regular resource files.
151151

152152
method IO()
153153

154-
Returns the corresponding resource as an C<IO::Path>, which can effectively
154+
Returns the corresponding resource as an L<C<IO::Path>|/type/IO::Path>, which can effectively
155155
be used as such.
156156

157157
=end pod

0 commit comments

Comments
 (0)