Metakit / @doeixd/metakit/build

ClaimSamples

interface · packages/metakit/src/ops/lawEquations.ts:10

interface ClaimSamples {
  readonly identity?: Iterable<Args>
  readonly absorbing?: Iterable<Args>
  readonly idempotent?: Iterable<Args>
  readonly commutative?: Iterable<Args>
  readonly associative?: Iterable<readonly [args: Args, third: unknown]>
  readonly invertible?: Iterable<Args>
  readonly monotone?: Iterable<
    readonly [args: Args, position: number, other: number]
  >
  readonly total?: Iterable<Args>
  readonly mayCall?: ReadonlyArray<string>
  readonly onCall?: (op: Node.ForeignOp, args: Args, answer: unknown) => void
}

Argument tuples to try for each declared claim. Every args tuple has the operation's arity.

Members

ClaimSamples.identity

property · packages/metakit/src/ops/lawEquations.ts:11

readonly identity?: Iterable<Args>

ClaimSamples.absorbing

property · packages/metakit/src/ops/lawEquations.ts:12

readonly absorbing?: Iterable<Args>

ClaimSamples.idempotent

property · packages/metakit/src/ops/lawEquations.ts:13

readonly idempotent?: Iterable<Args>

ClaimSamples.commutative

property · packages/metakit/src/ops/lawEquations.ts:14

readonly commutative?: Iterable<Args>

ClaimSamples.associative

property · packages/metakit/src/ops/lawEquations.ts:16

readonly associative?: Iterable<readonly [args: Args, third: unknown]>

The first two operands and the third operand of the regrouping.

ClaimSamples.invertible

property · packages/metakit/src/ops/lawEquations.ts:17

readonly invertible?: Iterable<Args>

ClaimSamples.monotone

property · packages/metakit/src/ops/lawEquations.ts:19

readonly monotone?: Iterable<
  readonly [args: Args, position: number, other: number]
>

An argument tuple and a second value to try at one zero-based argument position.

ClaimSamples.total

property · packages/metakit/src/ops/lawEquations.ts:20

readonly total?: Iterable<Args>

ClaimSamples.mayCall

property · packages/metakit/src/ops/lawEquations.ts:26

readonly mayCall?: ReadonlyArray<string>

Names of operations the implementation may call that foreign leaves unbound. The evidence records them as unbound, so it stops applying once any is bound.

ClaimSamples.onCall

property · packages/metakit/src/ops/lawEquations.ts:28

readonly onCall?: (op: Node.ForeignOp, args: Args, answer: unknown) => void

Sees each call the equations make and its answer, as for a SQL parity check.