MCPcopy Index your code
hub / github.com/anomalyco/opencode / checksPortable

Function checksPortable

packages/httpapi-codegen/src/index.ts:858–869  ·  view source on GitHub ↗
(checks: SchemaAST.Checks | undefined)

Source from the content-addressed store, hash-verified

856}
857
858function checksPortable(checks: SchemaAST.Checks | undefined): boolean {
859 if (checks === undefined) return true
860 return checks.every((check) =>
861 check._tag === "Filter"
862 ? !check.aborted &&
863 check.annotations?.meta !== undefined &&
864 typeof check.annotations.arbitrary === "object" &&
865 check.annotations.arbitrary !== null &&
866 "constraint" in check.annotations.arbitrary
867 : checksPortable(check.checks),
868 )
869}
870
871function metadataPortable(ast: SchemaAST.AST, seen: Set<SchemaAST.AST>): boolean {
872 if (seen.has(ast)) return true

Callers 3

visitCurrentFunction · 0.85
assertPortableFunction · 0.85
metadataPortableFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected