Skip to content

Commit

Permalink
XREF_PACK_NAMED -> REF_ALTTEXT (sed)
Browse files Browse the repository at this point in the history
Done by:

arg='\s*([^(),]*)'
from='\$\(XREF_PACK_NAMED\s'$arg','$arg','$arg','$arg'\)'
to='$(REF_ALTTEXT \4, \3, std,\1,\2)'
(find . -type f -name "*.d" -print0; \
    find . -type f -name "*.dd" -print0) | \
xargs -0 sed -i -r "s/$from/$to/g"
  • Loading branch information
aG0aep6G committed May 27, 2016
1 parent d648f93 commit ef97229
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 50 deletions.
2 changes: 1 addition & 1 deletion std/algorithm/comparison.d
Expand Up @@ -79,7 +79,7 @@ Returns:
found value plus one is returned.
See_Also:
$(XREF_PACK_NAMED algorithm,searching,find,find) and $(XREF_PACK_NAMED algorithm,searching,canFind, canFind) for finding a value in a
$(REF_ALTTEXT find, find, std,algorithm,searching) and $(REF_ALTTEXT canFind, canFind, std,algorithm,searching) for finding a value in a
range.
*/
uint among(alias pred = (a, b) => a == b, Value, Values...)
Expand Down
24 changes: 12 additions & 12 deletions std/algorithm/iteration.d
Expand Up @@ -1331,7 +1331,7 @@ $(D pred(element, element)).
Params:
pred = Binary predicate for determining equivalence of two elements.
r = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to
r = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to
iterate over.
Returns: A range of elements of type $(D Tuple!(ElementType!R, uint)),
Expand Down Expand Up @@ -2014,9 +2014,9 @@ joined directly without anything in between them (often called $(D flatten)
in other languages).
Params:
r = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) of input
r = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) of input
ranges to be joined.
sep = A $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) of
sep = A $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) of
element(s) to serve as separators in the joined range.
Returns:
Expand Down Expand Up @@ -3473,7 +3473,7 @@ below).
Params:
pred = The predicate for comparing each element with the separator,
defaulting to $(D "a == b").
r = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to be
r = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to be
split. Must support slicing and $(D .length).
s = The element to be treated as the separator between range segments to be
split.
Expand Down Expand Up @@ -3754,9 +3754,9 @@ empty elements.
Params:
pred = The predicate for comparing each element with the separator,
defaulting to $(D "a == b").
r = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to be
r = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to be
split.
s = The $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) to
s = The $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) to
be treated as the separator between segments of $(D r) to be split.
Constraints:
Expand Down Expand Up @@ -4026,7 +4026,7 @@ empty elements.
Params:
isTerminator = The predicate for deciding where to split the range.
input = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to
input = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to
be split.
Constraints:
Expand Down Expand Up @@ -4276,7 +4276,7 @@ Params:
s = The string to be split.
Returns:
An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) of slices of
An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) of slices of
the original string split by whitespace.
+/
auto splitter(C)(C[] s)
Expand Down Expand Up @@ -4459,15 +4459,15 @@ if (isSomeChar!C)
// sum
/**
Sums elements of $(D r), which must be a finite
$(XREF_PACK_NAMED range,primitives,isInputRange,input range). Although
$(REF_ALTTEXT input range, isInputRange, std,range,primitives). Although
conceptually $(D sum(r)) is equivalent to $(LREF fold)!((a, b) => a +
b)(r, 0), $(D sum) uses specialized algorithms to maximize accuracy,
as follows.
$(UL
$(LI If $(D $(REF ElementType, std,range,primitives)!R) is a floating-point
type and $(D R) is a
$(XREF_PACK_NAMED range,primitives,isRandomAccessRange,random-access range) with
$(REF_ALTTEXT random-access range, isRandomAccessRange, std,range,primitives) with
length and slicing, then $(D sum) uses the
$(WEB en.wikipedia.org/wiki/Pairwise_summation, pairwise summation)
algorithm.)
Expand Down Expand Up @@ -4760,11 +4760,11 @@ bidirectional, $(D uniq) also yields a bidirectional range.
Params:
pred = Predicate for determining equivalence between range elements.
r = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) of
r = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) of
elements to filter.
Returns:
An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) of
An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) of
consecutively unique elements in the original range. If $(D r) is also a
forward range or bidirectional range, the returned range will be likewise.
*/
Expand Down
22 changes: 11 additions & 11 deletions std/algorithm/mutation.d
Expand Up @@ -474,7 +474,7 @@ Assigns $(D value) to each element of input _range $(D range).
Params:
range = An
$(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
$(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
that exposes references to its elements and has assignable
elements
value = Assigned to each element of range
Expand Down Expand Up @@ -588,10 +588,10 @@ $(D range) does not have to be a multiple of the length of $(D
filler). If $(D filler) is empty, an exception is thrown.
Params:
range = An $(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
range = An $(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
that exposes references to its elements and has assignable elements.
filler = The
$(XREF_PACK_NAMED _range,primitives,isForwardRange,forward _range)
$(REF_ALTTEXT forward _range, isForwardRange, std,_range,primitives)
representing the _fill pattern.
*/
void fill(Range1, Range2)(Range1 range, Range2 filler)
Expand Down Expand Up @@ -710,7 +710,7 @@ Assumes that the elements of the range are uninitialized.
Params:
range = An
$(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
$(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
that exposes references to its elements and has assignable
elements
Expand Down Expand Up @@ -1277,9 +1277,9 @@ This precondition will be asserted. If you cannot ensure there is enough room in
`tgt` to accommodate all of `src` use $(LREF moveSome) instead.
Params:
src = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) with
src = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) with
movable elements.
tgt = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) with
tgt = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) with
elements that elements from $(D src) can be moved into.
Returns: The leftover portion of $(D tgt) after all elements from $(D src) have
Expand Down Expand Up @@ -1384,9 +1384,9 @@ element `b` in `tgt`, in increasing order, stopping when either range has been
exhausted.
Params:
src = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) with
src = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) with
movable elements.
tgt = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) with
tgt = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) with
elements that elements from $(D src) can be moved into.
Returns: The leftover portions of the two ranges after one or the other of the
Expand Down Expand Up @@ -2524,9 +2524,9 @@ be of different types but must have the same element type and support
swapping.
Params:
r1 = an $(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
r1 = an $(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
with swappable elements
r2 = an $(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
r2 = an $(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
with swappable elements
Returns:
Expand Down Expand Up @@ -2565,7 +2565,7 @@ uninitializedFill are equivalent).
Params:
range = An
$(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
$(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
that exposes references to its elements and has assignable
elements
value = Assigned to each element of range
Expand Down
46 changes: 23 additions & 23 deletions std/algorithm/searching.d
Expand Up @@ -385,10 +385,10 @@ Params:
pred = The predicate to use in comparing elements for commonality. Defaults
to equality $(D "a == b").
r1 = A $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) of
r1 = A $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) of
elements.
r2 = An $(XREF_PACK_NAMED range,primitives,isInputRange,input range) of
r2 = An $(REF_ALTTEXT input range, isInputRange, std,range,primitives) of
elements.
Returns:
Expand Down Expand Up @@ -700,16 +700,16 @@ size_t count(alias pred = "true", R)(R haystack)

/++
Counts elements in the given
$(XREF_PACK_NAMED range,primitives,isForwardRange,forward range)
$(REF_ALTTEXT forward range, isForwardRange, std,range,primitives)
until the given predicate is true for one of the given $(D needles).
Params:
pred = The predicate for determining when to stop counting.
haystack = The
$(XREF_PACK_NAMED range,primitives,isInputRange,input range) to be
$(REF_ALTTEXT input range, isInputRange, std,range,primitives) to be
counted.
needles = Either a single element, or a
$(XREF_PACK_NAMED range,primitives,isForwardRange,forward range)
$(REF_ALTTEXT forward range, isForwardRange, std,range,primitives)
of elements, to be evaluated in turn against each
element in $(D haystack) under the given predicate.
Expand Down Expand Up @@ -872,7 +872,7 @@ ptrdiff_t countUntil(alias pred = "a == b", R, N)(R haystack, N needle)
Params:
pred = Predicate to when to stop counting.
haystack = An
$(XREF_PACK_NAMED range,primitives,isInputRange,input range) of
$(REF_ALTTEXT input range, isInputRange, std,range,primitives) of
elements to be counted.
Returns: The number of elements which must be popped from $(D haystack)
before $(D pred(haystack.front)) is $(D true).
Expand Down Expand Up @@ -969,7 +969,7 @@ Params:
the needle(s).
doesThisEnd = The
$(XREF_PACK_NAMED range,primitives,isBidirectionalRange,bidirectional range)
$(REF_ALTTEXT bidirectional range, isBidirectionalRange, std,range,primitives)
to check.
withOneOfThese = The needles to check against, which may be single
Expand Down Expand Up @@ -1326,7 +1326,7 @@ $(D "a == b").
The negated predicate $(D "a != b") can be used to search instead for the first
element $(I not) matching the needle.
haystack = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range)
haystack = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives)
searched in.
needle = The element searched for.
Expand Down Expand Up @@ -1618,7 +1618,7 @@ Params:
pred = The predicate for determining if a given element is the one being
searched for.
haystack = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to
haystack = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to
search in.
Returns:
Expand Down Expand Up @@ -1697,10 +1697,10 @@ Params:
pred = The predicate to use for comparing respective elements from the haystack
and the needle. Defaults to simple equality $(D "a == b").
haystack = The $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range)
haystack = The $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives)
searched in.
needle = The $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range)
needle = The $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives)
searched for.
Returns:
Expand Down Expand Up @@ -2339,7 +2339,7 @@ evaluations of $(D pred).
Params:
pred = The predicate to satisfy.
r = A $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) to
r = A $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) to
search in.
Returns:
Expand Down Expand Up @@ -2415,9 +2415,9 @@ Performs $(BIGOH seq.length * choices.length) evaluations of $(D pred).
Params:
pred = The predicate to use for determining a match.
seq = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to
seq = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to
search.
choices = A $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range)
choices = A $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives)
of possible choices.
Returns:
Expand Down Expand Up @@ -2463,10 +2463,10 @@ Range1 findAmong(alias pred = "a == b", Range1, Range2)(
*
* Params:
* haystack = The
* $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) to search
* $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) to search
* in.
* needle = The
* $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) to search
* $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) to search
* for.
*
* Returns: $(D true) if the needle was found, in which case $(D haystack) is
Expand Down Expand Up @@ -3407,9 +3407,9 @@ range, or do nothing if there is no match.
Params:
pred = The predicate that determines whether elements from each respective
range match. Defaults to equality $(D "a == b").
r1 = The $(XREF_PACK_NAMED range,primitives,isForwardRange,forward range) to
r1 = The $(REF_ALTTEXT forward range, isForwardRange, std,range,primitives) to
move forward.
r2 = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range)
r2 = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives)
representing the initial segment of $(D r1) to skip over.
Returns:
Expand Down Expand Up @@ -3487,7 +3487,7 @@ Params:
pred = The predicate that determines whether an element from the range
matches the given element.
r = The $(XREF_PACK_NAMED range,primitives,isInputRange,input range) to skip
r = The $(REF_ALTTEXT input range, isInputRange, std,range,primitives) to skip
over.
e = The element to match.
Expand Down Expand Up @@ -3536,7 +3536,7 @@ bool skipOver(alias pred, R, E)(ref R r, E e)

/**
Checks whether the given
$(XREF_PACK_NAMED range,primitives,isInputRange,input range) starts with (one
$(REF_ALTTEXT input range, isInputRange, std,range,primitives) starts with (one
of) the given needle(s) or, if no needles are given,
if its front element fulfils predicate $(D pred).
Expand Down Expand Up @@ -3897,18 +3897,18 @@ $(D pred(e, sentinel)) is true.
Params:
pred = Predicate to determine when to stop.
range = The $(XREF_PACK_NAMED _range,primitives,isInputRange,input _range)
range = The $(REF_ALTTEXT input _range, isInputRange, std,_range,primitives)
to iterate over.
sentinel = The element to stop at.
openRight = Determines whether the element for which the given predicate is
true should be included in the resulting range ($(D OpenRight.no)), or
not ($(D OpenRight.yes)).
Returns:
An $(XREF_PACK_NAMED _range,primitives,isInputRange,input _range) that
An $(REF_ALTTEXT input _range, isInputRange, std,_range,primitives) that
iterates over the original range's elements, but ends when the specified
predicate becomes true. If the original range is a
$(XREF_PACK_NAMED _range,primitives,isForwardRange,forward _range) or
$(REF_ALTTEXT forward _range, isForwardRange, std,_range,primitives) or
higher, this range will be a forward range.
*/
Until!(pred, Range, Sentinel)
Expand Down
4 changes: 2 additions & 2 deletions std/algorithm/sorting.d
Expand Up @@ -2618,10 +2618,10 @@ Params:
Defaults to $(D a < b).
ss = $(RED (Not implemented yet.)) Specify the swapping strategy.
r = A
$(XREF_PACK_NAMED range,primitives,isRandomAccessRange,random-access range)
$(REF_ALTTEXT random-access range, isRandomAccessRange, std,range,primitives)
of elements to make an index for.
index = A
$(XREF_PACK_NAMED range,primitives,isRandomAccessRange,random-access range)
$(REF_ALTTEXT random-access range, isRandomAccessRange, std,range,primitives)
with assignable elements to build the index in. The length of this range
determines how many top elements to index in $(D r).
Expand Down
2 changes: 1 addition & 1 deletion std/array.d
Expand Up @@ -1433,7 +1433,7 @@ alias splitter = std.algorithm.iteration.splitter;
Eagerly splits $(D range) into an array, using $(D sep) as the delimiter.
The _range must be a
$(XREF_PACK_NAMED _range,primitives,isForwardRange,forward _range).
$(REF_ALTTEXT forward _range, isForwardRange, std,_range,primitives).
The separator can be a value of the same type as the elements in $(D range)
or it can be another forward _range.
Expand Down

0 comments on commit ef97229

Please sign in to comment.