From 4e793766d03c72cab1b683ed386ecee137ce3d7c Mon Sep 17 00:00:00 2001 From: Apacheopteryx Date: Fri, 7 May 2021 21:20:53 -0500 Subject: [PATCH] include type in error --- lib/packer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/packer.ts b/lib/packer.ts index 04abfd7..fc6d589 100644 --- a/lib/packer.ts +++ b/lib/packer.ts @@ -101,7 +101,7 @@ const pack_value = (e: E, value: unknown) => { : small_atom(e, [110, 105, 108]); case "string": return string(e, value); case "undefined": return small_atom(e, [110, 105, 108]); - default: throw new Error("Unsupport type"); + default: throw new Error(`Unsupported type '${typeof value}'`); } };