MCPcopy Create free account
hub / github.com/LambdaNote/support-ts-tapl / error

Function error

article/utils.ts:593–600  ·  view source on GitHub ↗
(msg: string, node: any)

Source from the content-addressed store, hash-verified

591
592// deno-lint-ignore no-explicit-any
593export function error(msg: string, node: any): never {
594 if (node.loc) {
595 const { start, end } = node.loc;
596 throw new Error(`test.ts:${start.line}:${start.column + 1}-${end.line}:${end.column + 1} ${msg}`);
597 } else {
598 throw new Error(msg);
599 }
600}
601
602// deno-lint-ignore no-explicit-any
603export function generateTestUtils(typecheck: (code: any) => Type) {

Callers 14

typecheckFunction · 0.90
typecheckFunction · 0.90
expandTypeAliasesFunction · 0.70
getIdentifierFunction · 0.70
getLiteralStringFunction · 0.70
getTypePropFunction · 0.70
getPropFunction · 0.70
getTagAndValFunction · 0.70
getSwitchVarNameFunction · 0.70
getParamFunction · 0.70
getRecFuncFunction · 0.70
convertTypeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected