ae.utils.range

ae.utils.range

Members

Functions

emptyRange
EmptyRange!E emptyRange()

Empty range of type E.

fastArrayRange
auto fastArrayRange(T[] arr)
Undocumented in source. Be warned that the author may not have intended to support it.
infiniteIota
InfiniteIota!T infiniteIota()
Undocumented in source. Be warned that the author may not have intended to support it.
lazyInitRange
auto lazyInitRange(R delegate() constructor)

Defer range construction until first empty/front call.

nullTerminated
auto nullTerminated(E* ptr)
Undocumented in source. Be warned that the author may not have intended to support it.
onlyLazy
auto onlyLazy(E value)

Like only, but evaluates the argument lazily, i.e. when the range's "front" is evaluated. DO NOT USE before this bug is fixed: https://issues.dlang.org/show_bug.cgi?id=11044

ptrSlice
T[] ptrSlice(T* a, T* b)
Undocumented in source. Be warned that the author may not have intended to support it.

Structs

EmptyRange
struct EmptyRange(E)

Empty range of type E.

FastArrayRange
struct FastArrayRange(T, bool CHECKED = isDebug)

An equivalent of an array range, but which maintains a start and end pointer instead of a start pointer and length. This allows .popFront to be faster. Optionally, omits bounds checking for even more speed.

InfiniteIota
struct InfiniteIota(T)
Undocumented in source.
NullTerminated
struct NullTerminated(E)

Presents a null-terminated pointer (C-like string) as a range.

Templates

pairwise
template pairwise(alias pred)

Apply a predicate over each consecutive pair.

Meta

License

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.

Authors

Vladimir Panteleev <vladimir@thecybershadow.net>