MCPcopy Create free account
hub / github.com/Snowflyt/tinyeffect / safeDivide2

Function safeDivide2

test/README.example.proof.ts:429–432  ·  view source on GitHub ↗
(a: number, b: number)

Source from the content-addressed store, hash-verified

427 const none: Option<never> = { kind: "none" };
428
429 const safeDivide2 = (a: number, b: number) =>
430 safeDivide(a, b)
431 .andThen((value) => some(value))
432 .terminate("raise", () => none);
433
434 expect(safeDivide2).to(equal<(a: number, b: number) => Effected<never, Option<number>>>);
435 }

Callers

nothing calls this directly

Calls 5

safeDivideFunction · 0.70
someFunction · 0.70
terminateMethod · 0.65
andThenMethod · 0.65
withMethod · 0.65

Tested by

no test coverage detected