refactor: Rename ship() to done() #9

Merged
glen merged 1 commits from refactor/ship_done into main 2024-10-21 22:02:36 +00:00
5 changed files with 8 additions and 8 deletions
Showing only changes of commit 33a0938818 - Show all commits

View File

@ -125,7 +125,7 @@ export function common<T>() {
return dep.divideReal(num, denom) return dep.divideReal(num, denom)
} }
}) })
.ship() .done()
} }
// Additional implementations for non-uniform signatures // Additional implementations for non-uniform signatures
@ -148,5 +148,5 @@ export function mixed<T>() {
divide: dep => (z, r) => divide: dep => (z, r) =>
dep.complex(dep.divTR(z.re, r), dep.divTR(z.im, r)) dep.complex(dep.divTR(z.re, r), dep.divTR(z.im, r))
}) })
.ship() .done()
} }

View File

@ -48,7 +48,7 @@ export function lift<T>() {
return implementations<CommonSignature<T>>() return implementations<CommonSignature<T>>()
.dependent({zero: {}}, { .dependent({zero: {}}, {
complex: dep => (a, b) => cplex(a, b || dep.zero(a)) complex: dep => (a, b) => cplex(a, b || dep.zero(a))
}).ship() }).done()
} }
export function common<T>() { export function common<T>() {
@ -68,5 +68,5 @@ export function common<T>() {
.dependent(baseSignature({re: {}}), { .dependent(baseSignature({re: {}}), {
re: dep => z => dep.re(z.re) re: dep => z => dep.re(z.re)
}) })
.ship() .done()
} }

View File

@ -139,7 +139,7 @@ interface ImplementationBuilder<
Specs & {[K in NewKeys]: DepCheck<RD, Signatures>} Specs & {[K in NewKeys]: DepCheck<RD, Signatures>}
> >
ship(info?: ReflectedTypeInfo): Implementations<Signatures, NeedKeys, NeedList, Specs> & ReflectedTypeInfo done(info?: ReflectedTypeInfo): Implementations<Signatures, NeedKeys, NeedList, Specs> & ReflectedTypeInfo
} }
// And a function that actually provides the builder interface: // And a function that actually provides the builder interface:
@ -191,7 +191,7 @@ function impBuilder<
Specs & {[K in NewKeys]: DepCheck<RD, Signatures, DepKeys>} Specs & {[K in NewKeys]: DepCheck<RD, Signatures, DepKeys>}
> >
}, },
ship(info?: ReflectedTypeInfo) { done(info?: ReflectedTypeInfo) {
return { ...sofar, ...info } return { ...sofar, ...info }
} }
} }

View File

@ -23,4 +23,4 @@ export const common = implementations<CommonSignature<number>>()
return dep.complex(0, Math.sqrt(-a)) return dep.complex(0, Math.sqrt(-a))
} }
}}) }})
.ship() .done()

View File

@ -28,4 +28,4 @@ export const common = implementations<CommonSignature<number>>()
one: a => 1, one: a => 1,
nan: a => NaN, nan: a => NaN,
re: a => a re: a => a
}).ship() }).done()