MCPcopy Create free account
hub / github.com/arktypeio/arktype / unwrapChain

Function unwrapChain

ark/aot/scope.ts:834–838  ·  view source on GitHub ↗
(node: Node)

Source from the content-addressed store, hash-verified

832
833// e.g. `T` for `(T as Type)!` or `T?.and`
834export const unwrapChain = (node: Node): Node => {
835 while (isTransparent(node) || node.type === "ChainExpression")
836 node = node.expression
837 return node
838}
839
840// e.g. `T!` and `T!.and` for `T`
841export const operatorOf = (

Callers 15

parameterOfFunction · 0.90
isIntrospectionReadFunction · 0.90
isReadThroughMethod · 0.90
isNonExtensibleCallMethod · 0.90
isNodeNonExtensibleMethod · 0.90
calledParamOfMethod · 0.90
unresolvedImportOfMethod · 0.90
refusedDefinitionOfMethod · 0.90
isDeclaredInIslandMethod · 0.90
unrefedOfFunction · 0.90
arkExportNameOfMethod · 0.90

Calls 1

isTransparentFunction · 0.90

Tested by

no test coverage detected