MCPcopy Index your code
hub / github.com/Effect-TS/effect / indicesFrom

Function indicesFrom

packages/effect/src/internal/configProvider.ts:628–637  ·  view source on GitHub ↗
(quotedIndices: HashSet.HashSet<string>)

Source from the content-addressed store, hash-verified

626}
627
628const indicesFrom = (quotedIndices: HashSet.HashSet<string>): Effect.Effect<Array<number>> =>
629 pipe(
630 core.forEachSequential(quotedIndices, parseQuotedIndex),
631 core.mapBoth({
632 onFailure: () => Arr.empty<number>(),
633 onSuccess: Arr.sort(number.Order)
634 }),
635 core.either,
636 core.map(Either.merge)
637 )
638
639const STR_INDEX_REGEX = /(^.+)(\[(\d+)\])$/
640const QUOTED_INDEX_REGEX = /^(\[(\d+)\])$/

Callers

nothing calls this directly

Calls 2

pipeFunction · 0.70
mapMethod · 0.65

Tested by

no test coverage detected