Contents

indices(of:)

Returns the indices within self where the memory represented by other is located, or nil if other is not located within self.

Declaration

func indices(of other: borrowing Span<Element>) -> Range<Span<Element>.Index>?

Return Value

A range of indices within self, or nil

Discussion

  • other: a span that may be a subrange of self