import { ErrBase } from "https://deno.land/x/rimbu@1.0.4/common/index.ts";
const { msg } = ErrBase;
Returns a function that, when called, throws an Err.ForcedError
with the given message
string.
Examples
Example 1
Example 1
const emptyMap = HashMap.empty<number, string>()
emptyMap.get(5, ErrBase.msg('not found'));
// throws: Err.CustomError(message: 'not found')