From a0a2ed1c0915013192ab54b4e380c1bbf79735c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A9ter=20Szil=C3=A1gyi?= Date: Mon, 11 Feb 2019 13:17:03 +0200 Subject: [PATCH] trie: make must-parse panics a bit more informative --- trie/node.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trie/node.go b/trie/node.go index 1fafb7a538..1ec56b1e9b 100644 --- a/trie/node.go +++ b/trie/node.go @@ -120,7 +120,7 @@ func (n valueNode) fstring(ind string) string { func mustDecodeNode(hash, buf []byte, cachegen uint16) node { n, err := decodeNode(hash, buf, cachegen) if err != nil { - panic(fmt.Sprintf("node %x: %v", hash, err)) + panic(fmt.Sprintf("node %x (%x): %v", hash, buf, err)) } return n }