Tests
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Julien Valverdé
2024-02-04 03:32:12 +01:00
parent f6d2d68eee
commit 2d32e4807d

View File

@@ -1,6 +1,5 @@
import { Call, ComposeLeft, Pipe } from "hotscript" import { Call, ComposeLeft } from "hotscript"
import { Implements, TraitExpressionAbstractFn, TraitExpressionTraitsFn, abstract, expression, trait } from "." import { Implements, TraitExpressionAbstractFn, abstract, expression, trait } from "."
import { Simplify } from "type-fest"
import { SimplifyFn } from "./util" import { SimplifyFn } from "./util"
@@ -66,15 +65,15 @@ type Abs = Call<ComposeLeft<[
SimplifyFn, SimplifyFn,
]>, typeof exp> ]>, typeof exp>
exp.subtrait( // exp.subtrait(
s => { // s => {
interface Subtrait extends (typeof s) { // interface Subtrait extends (typeof s) {
} // }
return abstract<Subtrait>() // return abstract<Subtrait>()
}, // },
) // )
class User extends exp.extends implements Implements<typeof exp> { class User extends exp.extends implements Implements<typeof exp> {
declare status: { _tag: "awaitingPayment" } | { _tag: "active"; activeSince: Date; expiresAt?: Date | undefined } | { _tag: "expired"; expiredSince: Date } declare status: { _tag: "awaitingPayment" } | { _tag: "active"; activeSince: Date; expiresAt?: Date | undefined } | { _tag: "expired"; expiredSince: Date }