phobos-next ~master (2022-05-18T09:58:38.2169964)
Dub
Repo
IndexedBy
nxt
typecons_ex
Undocumented in source.
struct
IndexedBy
(R, I)
struct
IndexedBy
(R, string IndexTypeName)
struct
IndexedBy (
R
string
IndexTypeName
)
if
(
hasIndexing
!
R
&&
IndexTypeName
!= "IndexTypeName"
) {
template
Mod
(size_t m, T = UnsignedOfModulo!m)
via
import
nxt
.
modulo
:
Mod
;
;
mixin
_genIndexAndSliceOps_unchecked
!(
I__
)
;
static if
(
__traits(isStaticArray, R)
)
auto
findIndex
(E e);
mixin
_genIndexAndSliceOps
!(
mixin
(
IndexTypeName
))
;
R
_r
;
}
Alias This
_r
Members
Functions
findIndex
auto
findIndex
(E e)
Get index of element
E
wrapped in a
bool
-convertable struct.
Mixins
__anonymous
mixin
_genIndexAndSliceOps_unchecked
!(
I__
)
Undocumented in source.
__anonymous
mixin
_genIndexAndSliceOps
!(
mixin
(
IndexTypeName
))
Undocumented in source.
Variables
_r
R
_r
;
Undocumented in source.
Meta
Source
See Implementation
nxt
typecons_ex
enums
hasIndexing
isCastableTo
isIndex
isIndexableBy
functions
enumToString
indexedBy
nullable
nullableRef
strictlyIndexed
mixin templates
RvalueRef
structs
IndexedArray
IndexedBy
templates
New
TypesafelyIndexed
makeEnumFromSymbolNames