pub trait IndexElement:
DeviceRepr
+ Sealed
+ Copy
+ 'static {
const KIND: IndexElementKind;
}Expand description
Sealed marker trait for index-element types accepted by the indexing / embedding / segment kernel families.
Phase 11.5 (Fuel team feedback #7): split out as a sibling of
Element so plans like [crate::indexing::GatherPlan] /
[crate::embedding::EmbeddingPlan] / [crate::segment::SegmentSumPlan]
can dispatch over the index dtype without coupling the value-dtype
trait hierarchy. Today’s members are i32 (legacy) and i64
(PyTorch default). Sealed because new members require a matching
FFI entry point in the *-kernels-sys crate.
Required Associated Constants§
Sourceconst KIND: IndexElementKind
const KIND: IndexElementKind
Runtime tag for this index element type.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".