diff --git a/packages/schema/src/Arbitrary/_arbitrary/index.ts b/packages/schema/src/Arbitrary/_arbitrary/index.ts index 59ee84c..7e41828 100644 --- a/packages/schema/src/Arbitrary/_arbitrary/index.ts +++ b/packages/schema/src/Arbitrary/_arbitrary/index.ts @@ -30,10 +30,10 @@ const cache = new WeakMap() function for_< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/Collect/_collect/index.ts b/packages/schema/src/Collect/_collect/index.ts index 8488c37..3d82e8a 100644 --- a/packages/schema/src/Collect/_collect/index.ts +++ b/packages/schema/src/Collect/_collect/index.ts @@ -65,10 +65,10 @@ const cache = new WeakMap() export function collectAnnotationsFor< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/Constructor/_constructor/index.ts b/packages/schema/src/Constructor/_constructor/index.ts index ca7b898..7d1bcfa 100644 --- a/packages/schema/src/Constructor/_constructor/index.ts +++ b/packages/schema/src/Constructor/_constructor/index.ts @@ -75,10 +75,10 @@ const cache = new WeakMap() function constructorFor< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/Encoder/_encoder/index.ts b/packages/schema/src/Encoder/_encoder/index.ts index 8abbe05..18e242d 100644 --- a/packages/schema/src/Encoder/_encoder/index.ts +++ b/packages/schema/src/Encoder/_encoder/index.ts @@ -35,10 +35,10 @@ const cache = new WeakMap() function encoderFor< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/Guard/_guard/index.ts b/packages/schema/src/Guard/_guard/index.ts index e9163ca..ce4c111 100644 --- a/packages/schema/src/Guard/_guard/index.ts +++ b/packages/schema/src/Guard/_guard/index.ts @@ -30,10 +30,10 @@ const cache = new WeakMap() function guardFor< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/Parser/_parser/index.ts b/packages/schema/src/Parser/_parser/index.ts index 85b7a4e..b42fab8 100644 --- a/packages/schema/src/Parser/_parser/index.ts +++ b/packages/schema/src/Parser/_parser/index.ts @@ -106,10 +106,10 @@ const cache = new WeakMap() function parserFor< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/array.ts b/packages/schema/src/_api/array.ts index c321625..90bc5c2 100644 --- a/packages/schema/src/_api/array.ts +++ b/packages/schema/src/_api/array.ts @@ -15,10 +15,10 @@ import { withDefaults } from "./withDefaults" export const arrayIdentifier = S.makeAnnotation<{ self: S.SchemaUPI }>() export function array< - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/brand.ts b/packages/schema/src/_api/brand.ts index 5a74d95..bd4efb9 100644 --- a/packages/schema/src/_api/brand.ts +++ b/packages/schema/src/_api/brand.ts @@ -1,5 +1,4 @@ // tracing: off -import type * as MO from "../_schema" import type { ApiSelfType, Schema } from "../_schema/schema" import type { DefaultSchema } from "./withDefaults" import { withDefaults } from "./withDefaults" @@ -7,10 +6,10 @@ import { withDefaults } from "./withDefaults" export function brand() { return < ParserInput, - ParserError extends MO.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends MO.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/chunk.ts b/packages/schema/src/_api/chunk.ts index a3ca439..2cab62d 100644 --- a/packages/schema/src/_api/chunk.ts +++ b/packages/schema/src/_api/chunk.ts @@ -18,10 +18,10 @@ export const fromChunkIdentifier = makeAnnotation<{ self: S.SchemaAny }>() export function fromChunk< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( @@ -95,10 +95,10 @@ export function fromChunk< export const chunkIdentifier = makeAnnotation<{ self: S.SchemaAny }>() export function chunk< - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/condemn.ts b/packages/schema/src/_api/condemn.ts index deecf19..baca102 100644 --- a/packages/schema/src/_api/condemn.ts +++ b/packages/schema/src/_api/condemn.ts @@ -4,7 +4,6 @@ import * as T from "@effect-ts/core/Effect" import * as E from "@effect-ts/core/Either" import { Case } from "@effect-ts/system/Case" -import type { AnyError } from "../_schema" import { drawError } from "../_schema" import type { These } from "../These" @@ -33,32 +32,32 @@ export class CondemnException extends Case<{ readonly message: string }> { export class ThrowableCondemnException extends Error { readonly _tag = "CondemnException" - constructor(readonly error: AnyError) { - super(drawError(error)) + constructor(readonly error: unknown) { + super(drawError(error as any)) // TODO } } -export function condemnFail(self: (a: X) => These) { +export function condemnFail(self: (a: X) => These) { return (a: X, __trace?: string) => T.fromEither(() => { const res = self(a).effect if (res._tag === "Left") { - return E.left(new CondemnException({ message: drawError(res.left) })) + return E.left(new CondemnException({ message: drawError(res.left as any) })) } const warn = res.right.get(1) if (warn._tag === "Some") { - return E.left(new CondemnException({ message: drawError(warn.value) })) + return E.left(new CondemnException({ message: drawError(warn.value as any) })) } return E.right(res.right.get(0)) }, __trace) } -export function condemnDie(self: (a: X) => These) { +export function condemnDie(self: (a: X) => These) { const orFail = condemnFail(self) return (a: X, __trace?: string) => T.orDie(orFail(a, __trace)) } -export function unsafe(self: (a: X) => These) { +export function unsafe(self: (a: X) => These) { return (a: X) => { const res = self(a).effect if (res._tag === "Left") { diff --git a/packages/schema/src/_api/intersect.ts b/packages/schema/src/_api/intersect.ts index 56c8ca6..c3b80e7 100644 --- a/packages/schema/src/_api/intersect.ts +++ b/packages/schema/src/_api/intersect.ts @@ -41,16 +41,16 @@ export const intersectIdentifier = S.makeAnnotation<{ self: S.SchemaUPI; that: S.SchemaUPI }>() export function intersect_< - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api, - ThatParserError extends S.AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends S.AnyError, + ThatConstructorError, ThatEncoded, ThatApi >( @@ -242,10 +242,10 @@ export function intersect_< } export function intersect< - ThatParserError extends S.AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends S.AnyError, + ThatConstructorError, ThatEncoded, ThatApi >( @@ -258,14 +258,7 @@ export function intersect< ThatEncoded, ThatApi > -): < - ParserError extends S.AnyError, - ParsedShape, - ConstructorInput, - ConstructorError extends S.AnyError, - Encoded, - Api ->( +): ( self: S.Schema< unknown, ParserError, @@ -288,10 +281,10 @@ export function intersect< } export function intersectLazy< - ThatParserError extends S.AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends S.AnyError, + ThatConstructorError, ThatEncoded, ThatApi >( @@ -305,14 +298,7 @@ export function intersectLazy< ThatApi > ) { - return < - ParserError extends S.AnyError, - ParsedShape, - ConstructorInput, - ConstructorError extends S.AnyError, - Encoded, - Api - >( + return ( self: S.Schema< unknown, ParserError, diff --git a/packages/schema/src/_api/lazy.ts b/packages/schema/src/_api/lazy.ts index 4f5e3aa..b48dfb9 100644 --- a/packages/schema/src/_api/lazy.ts +++ b/packages/schema/src/_api/lazy.ts @@ -1,14 +1,14 @@ -import type { AnyError, Schema } from "../_schema" +import type { Schema } from "../_schema" import { SchemaLazy } from "../_schema" import type { DefaultSchema } from "./withDefaults" import { withDefaults } from "./withDefaults" export function lazy< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/nonEmpty.ts b/packages/schema/src/_api/nonEmpty.ts index 0074d9a..da7bb7b 100644 --- a/packages/schema/src/_api/nonEmpty.ts +++ b/packages/schema/src/_api/nonEmpty.ts @@ -14,10 +14,10 @@ export const nonEmptyIdentifier = S.makeAnnotation<{ self: S.SchemaAny }>() export function nonEmpty< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape extends { length: number }, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/nullable.ts b/packages/schema/src/_api/nullable.ts index 4556c55..aa5955f 100644 --- a/packages/schema/src/_api/nullable.ts +++ b/packages/schema/src/_api/nullable.ts @@ -15,10 +15,10 @@ export const nullableIdentifier = S.makeAnnotation<{ self: S.SchemaAny }>() export function nullable< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/positive.ts b/packages/schema/src/_api/positive.ts index 23f9eaf..d3c9aaa 100644 --- a/packages/schema/src/_api/positive.ts +++ b/packages/schema/src/_api/positive.ts @@ -16,10 +16,10 @@ export const positiveIdentifier = S.makeAnnotation<{ self: S.SchemaAny }>() export function positive< ParserInput, - ParserError extends S.AnyError, + ParserError, ParsedShape extends number, ConstructorInput, - ConstructorError extends S.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_api/refinement.ts b/packages/schema/src/_api/refinement.ts index c969363..debf773 100644 --- a/packages/schema/src/_api/refinement.ts +++ b/packages/schema/src/_api/refinement.ts @@ -16,7 +16,7 @@ export const refinementIdentifier = error: (value: unknown) => unknown }>() -export function refinement( +export function refinement( refinement: Refinement, error: (value: unknown) => E ): DefaultSchema< diff --git a/packages/schema/src/_api/schemed.ts b/packages/schema/src/_api/schemed.ts index 499dc3a..a8fbf88 100644 --- a/packages/schema/src/_api/schemed.ts +++ b/packages/schema/src/_api/schemed.ts @@ -77,9 +77,9 @@ type ShapeFromClass< export const fromFields = Symbol() -export function Schemed< - Self extends S.Schema ->(self: Self): Schemed { +export function Schemed>( + self: Self +): Schemed { const of_ = Constructor.for(self)["|>"](unsafe) // @ts-expect-error return class { diff --git a/packages/schema/src/_api/union.ts b/packages/schema/src/_api/union.ts index 50a4313..2f03798 100644 --- a/packages/schema/src/_api/union.ts +++ b/packages/schema/src/_api/union.ts @@ -276,7 +276,6 @@ export function union>( ) ) } else { - // @ts-expect-error return Th.mapError_(parsers[tag.value.index[u[tag.value.key]]](u), (e) => S.compositionE( Chunk.single( @@ -296,7 +295,6 @@ export function union>( const res = parser(u) if (res.effect._tag === "Right") { - // @ts-expect-error return Th.mapError_(res, (e) => S.compositionE(Chunk.single(S.nextE(S.unionE(Chunk.single(S.memberE(k, e)))))) ) diff --git a/packages/schema/src/_api/withDefaultConstructorField.ts b/packages/schema/src/_api/withDefaultConstructorField.ts index 3024803..ab78bfd 100644 --- a/packages/schema/src/_api/withDefaultConstructorField.ts +++ b/packages/schema/src/_api/withDefaultConstructorField.ts @@ -25,14 +25,7 @@ export function withDefaultConstructorField< >( key: Key, value: Lazy -): < - ParserInput, - ParserError extends S.AnyError, - ParsedShape, - ConstructorError extends S.AnyError, - Encoded, - Api ->( +): ( self: S.Schema< ParserInput, ParserError, diff --git a/packages/schema/src/_api/withDefaults.ts b/packages/schema/src/_api/withDefaults.ts index 23586cb..9c9ce0e 100644 --- a/packages/schema/src/_api/withDefaults.ts +++ b/packages/schema/src/_api/withDefaults.ts @@ -12,10 +12,10 @@ import { unsafe } from "./condemn" export interface SchemaDefaultSchema< ParserInput, - ParserError extends MO.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends MO.AnyError, + ConstructorError, Encoded, Api > extends Schema< @@ -59,10 +59,10 @@ export interface SchemaDefaultSchema< export type DefaultSchema< ParserInput, - ParserError extends MO.AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends MO.AnyError, + ConstructorError, Encoded, Api > = SchemaDefaultSchema< @@ -89,9 +89,9 @@ type CarryFromApi = UnionToIntersection< export function withDefaults< ParserInput, ParsedShape, - ParserError extends MO.AnyError, + ParserError, ConstructorInput, - ConstructorError extends MO.AnyError, + ConstructorError, Encoded, Api >( diff --git a/packages/schema/src/_schema/primitives.ts b/packages/schema/src/_schema/primitives.ts index f71f71a..a6ec2c5 100644 --- a/packages/schema/src/_schema/primitives.ts +++ b/packages/schema/src/_schema/primitives.ts @@ -5,7 +5,7 @@ import type * as fc from "fast-check" import type * as Th from "../These" import type { Annotation } from "./annotation" -import type { AnyError, CompositionE, NamedE, NextE, PrevE, RefinementE } from "./error" +import type { CompositionE, NamedE, NextE, PrevE, RefinementE } from "./error" import type { ApiSelfType, Schema, SchemaAny } from "./schema" import { SchemaAnnotated, @@ -24,14 +24,7 @@ import { } from "./schema" export function opaque() { - return < - ConstructorInput, - ConstructorError extends AnyError, - ParserInput, - ParserError extends AnyError, - Encoded, - Api - >( + return ( schema: Schema< ParserInput, ParserError, @@ -55,10 +48,10 @@ export function opaque() { export function named(name: Name) { return < ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -90,12 +83,12 @@ export function identity( export function constructor< NewConstructorInput, - NewConstructorError extends AnyError, + NewConstructorError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >(f: (_: NewConstructorInput) => Th.These) { @@ -122,12 +115,12 @@ export function constructor< export function constructor_< NewConstructorInput, - NewConstructorError extends AnyError, + NewConstructorError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -155,12 +148,12 @@ export function constructor_< export function parser< NewParserInput, - NewParserError extends AnyError, + NewParserError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >(f: (_: NewParserInput) => Th.These) { @@ -187,12 +180,12 @@ export function parser< export function parser_< NewParserInput, - NewParserError extends AnyError, + NewParserError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -221,14 +214,7 @@ export function parser_< export function arbitrary( f: (_: typeof fc) => fc.Arbitrary ) { - return < - ParserInput, - ParserError extends AnyError, - ConstructorInput, - ConstructorError extends AnyError, - Encoded, - Api - >( + return ( self: Schema< ParserInput, ParserError, @@ -251,10 +237,10 @@ export function arbitrary( export function arbitrary_< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -281,14 +267,7 @@ export function arbitrary_< } export function encoder(f: (_: ParsedShape) => A) { - return < - ParserInput, - ParserError extends AnyError, - ConstructorInput, - ConstructorError extends AnyError, - Encoded, - Api - >( + return ( self: Schema< ParserInput, ParserError, @@ -311,10 +290,10 @@ export function encoder(f: (_: ParsedShape) => A) { export function encoder_< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, A @@ -341,21 +320,10 @@ export function encoder_< return new SchemaEncoder(self, f) } -export function refine< - E extends AnyError, - NewParsedShape extends ParsedShape, - ParsedShape ->( +export function refine( refinement: Refinement, error: (value: ParsedShape) => E -): < - ParserInput, - ParserError extends AnyError, - ConstructorInput, - ConstructorError extends AnyError, - Encoded, - Api ->( +): ( self: Schema< ParserInput, ParserError, @@ -377,17 +345,8 @@ export function refine< return (self) => new SchemaRefinement(self, refinement, error) } -export function mapParserError( - f: (e: E) => E1 -) { - return < - ParserInput, - ParsedShape, - ConstructorInput, - ConstructorError extends AnyError, - Encoded, - Api - >( +export function mapParserError(f: (e: E) => E1) { + return ( self: Schema< ParserInput, E, @@ -408,17 +367,8 @@ export function mapParserError( > => new SchemaMapParserError(self, f) } -export function mapConstructorError( - f: (e: E) => E1 -) { - return < - ParserInput, - ParserError extends AnyError, - ParsedShape, - ConstructorInput, - Encoded, - Api - >( +export function mapConstructorError(f: (e: E) => E1) { + return ( self: Schema< ParserInput, ParserError, @@ -442,10 +392,10 @@ export function mapConstructorError( export function mapApi(f: (e: E) => E1) { return < ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded >( self: Schema< @@ -470,10 +420,10 @@ export function mapApi(f: (e: E) => E1) { export function identified_< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, Meta @@ -517,10 +467,10 @@ export function annotate( export function guard_< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -548,14 +498,7 @@ export function guard_< export function guard( guard: (u: unknown) => u is ParsedShape -): < - ParserInput, - ParserError extends AnyError, - ConstructorInput, - ConstructorError extends AnyError, - Encoded, - Api ->( +): ( self: Schema< ParserInput, ParserError, @@ -579,16 +522,16 @@ export function guard( export function into_< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, - ThatParserError extends AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends AnyError, + ThatConstructorError, ThatApi >( self: Schema< @@ -623,10 +566,10 @@ export function into_< export function into< Api, - ThatParserError extends AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends AnyError, + ThatConstructorError, ThatApi, ParsedShape >( @@ -639,13 +582,7 @@ export function into< ParsedShape, ThatApi > -): < - ParserInput, - ParserError extends AnyError, - ConstructorInput, - ConstructorError extends AnyError, - Encoded ->( +): ( self: Schema< ParserInput, ParserError, diff --git a/packages/schema/src/_schema/schema.ts b/packages/schema/src/_schema/schema.ts index 87210c7..651ee69 100644 --- a/packages/schema/src/_schema/schema.ts +++ b/packages/schema/src/_schema/schema.ts @@ -6,7 +6,7 @@ import type * as fc from "fast-check" import type * as Th from "../These" import type { Annotation } from "./annotation" -import type { AnyError, CompositionE, NamedE, NextE, PrevE, RefinementE } from "./error" +import type { CompositionE, NamedE, NextE, PrevE, RefinementE } from "./error" export const SchemaSym = Symbol() export type SchemaSym = typeof SchemaSym @@ -26,10 +26,10 @@ export type SchemaSym = typeof SchemaSym */ export abstract class Schema< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > { @@ -43,10 +43,10 @@ export abstract class Schema< abstract readonly Api: Api readonly [">>>"] = < - ThatParserError extends AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends AnyError, + ThatConstructorError, ThatApi >( that: Schema< @@ -82,18 +82,10 @@ export abstract class Schema< > => new SchemaAnnotated(this, identifier, meta) } -export type SchemaAny = Schema -export type SchemaUPI = Schema +export type SchemaAny = Schema +export type SchemaUPI = Schema -export type Standard = Schema< - unknown, - AnyError, - A, - A, - AnyError, - Enc, - {} -> +export type Standard = Schema export interface ApiSelfType { _AS: AS @@ -109,10 +101,10 @@ export type SchemaContinuationSymbol = typeof SchemaContinuationSymbol export interface HasContinuation { readonly [SchemaContinuationSymbol]: Schema< unknown, - AnyError, + any, unknown, unknown, - AnyError, + any, unknown, unknown > @@ -120,10 +112,10 @@ export interface HasContinuation { export function hasContinuation< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >( @@ -158,9 +150,7 @@ export type ParserInputOf> = export type ParserErrorOf> = [ X ] extends [Schema] - ? Y extends AnyError - ? Y - : never + ? Y : never export type ConstructorInputOf> = [ @@ -172,9 +162,7 @@ export type ConstructorInputOf> = [ X ] extends [Schema] - ? Y extends AnyError - ? Y - : never + ? Y : never export type EncodedOf> = [ @@ -205,12 +193,12 @@ export class SchemaIdentity extends Schema { export class SchemaConstructor< NewConstructorInput, - NewConstructorError extends AnyError, + NewConstructorError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > @@ -249,12 +237,12 @@ export class SchemaConstructor< export class SchemaParser< NewParserInput, - NewParserError extends AnyError, + NewParserError, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > @@ -294,10 +282,10 @@ export class SchemaParser< export class SchemaArbitrary< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > @@ -337,10 +325,10 @@ export class SchemaArbitrary< export class SchemaEncoder< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, Encoded2 @@ -380,13 +368,13 @@ export class SchemaEncoder< } export class SchemaRefinement< - E extends AnyError, + E, NewParsedShape extends ParsedShape, ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > extends Schema< @@ -421,16 +409,16 @@ export class SchemaRefinement< export class SchemaPipe< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, - ThatParserError extends AnyError, + ThatParserError, ThatParsedShape, ThatConstructorInput, - ThatConstructorError extends AnyError, + ThatConstructorError, ThatApi > extends Schema< @@ -476,11 +464,11 @@ export class SchemaPipe< export class SchemaMapParserError< ParserInput, - ParserError extends AnyError, - ParserError2 extends AnyError, + ParserError, + ParserError2, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > @@ -519,11 +507,11 @@ export class SchemaMapParserError< export class SchemaMapConstructorError< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, - ConstructorError2 extends AnyError, + ConstructorError, + ConstructorError2, Encoded, Api > @@ -562,10 +550,10 @@ export class SchemaMapConstructorError< export class SchemaMapApi< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, Api2 @@ -606,10 +594,10 @@ export class SchemaMapApi< export class SchemaNamed< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, Name extends string @@ -681,10 +669,10 @@ export function isAnnotatedSchema( export class SchemaAnnotated< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api, Meta @@ -727,10 +715,10 @@ export class SchemaAnnotated< export class SchemaGuard< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api > @@ -769,10 +757,10 @@ export class SchemaGuard< export class SchemaLazy< ParserInput, - ParserError extends AnyError, + ParserError, ParsedShape, ConstructorInput, - ConstructorError extends AnyError, + ConstructorError, Encoded, Api >