Skip to content

Commit

Permalink
refactor: remove stale functions
Browse files Browse the repository at this point in the history
  • Loading branch information
xzhayon committed May 27, 2024
1 parent d708d09 commit 3ce5bbc
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 34 deletions.
4 changes: 0 additions & 4 deletions src/concurrency/Promise.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ import { ConcurrencyError } from '../error/ConcurrencyError'
import * as $Error from '../error/Error'
import { InterruptError } from '../error/InterruptError'

export function is(u: unknown): u is Promise<unknown> {
return u instanceof Promise
}

export function all<G extends AnyEffector<any, any, any>>(
effectors: ReadonlyArray<OrLazy<G>>,
) {
Expand Down
30 changes: 0 additions & 30 deletions src/fiber/Status.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,33 +62,3 @@ export function failed(error: unknown): Status<never, never> {
export function terminated<T>(value: T): Status<T, never> {
return { ..._status('Terminated'), value }
}

export function isReady(status: Status<any, any>): status is Ready {
return status[$Type.tag] === 'Ready'
}

export function isStarted(status: Status<any, any>): status is Started {
return status[$Type.tag] === 'Started'
}

export function isRunning(status: Status<any, any>): status is Running {
return status[$Type.tag] === 'Running'
}

export function isSuspended<S>(status: Status<any, S>): status is Suspended<S> {
return status[$Type.tag] === 'Suspended'
}

export function isInterrupted(status: Status<any, any>): status is Interrupted {
return status[$Type.tag] === 'Interrupted'
}

export function isFailed(status: Status<any, any>): status is Failed {
return status[$Type.tag] === 'Failed'
}

export function isTerminated<T>(
status: Status<T, any>,
): status is Terminated<T> {
return status[$Type.tag] === 'Terminated'
}

0 comments on commit 3ce5bbc

Please sign in to comment.