aboutsummaryrefslogtreecommitdiffstats
path: root/skate/zippy.go
diff options
context:
space:
mode:
authorMartin Czygan <martin.czygan@gmail.com>2021-06-03 11:01:16 +0200
committerMartin Czygan <martin.czygan@gmail.com>2021-06-03 11:01:16 +0200
commit094178acfa32ec913b0adc4655e25a9316e29510 (patch)
tree3c38a8cb3f865ce33817ecc56ccf0bcd84425492 /skate/zippy.go
parent22d7b1d4bf157145f5d2713f8055eb59e36cedcb (diff)
downloadrefcat-094178acfa32ec913b0adc4655e25a9316e29510.tar.gz
refcat-094178acfa32ec913b0adc4655e25a9316e29510.zip
improve error message
Diffstat (limited to 'skate/zippy.go')
-rw-r--r--skate/zippy.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/skate/zippy.go b/skate/zippy.go
index 5d62704..65155e8 100644
--- a/skate/zippy.go
+++ b/skate/zippy.go
@@ -223,7 +223,7 @@ func CutSep(line, sep string, column int) string {
func makeKeyFunc(sep string, column int) func(string) (string, error) {
return func(s string) (string, error) {
if k := CutSep(s, sep, column); k == "" {
- return k, fmt.Errorf("cannot get key: %s", s)
+ return k, fmt.Errorf("cannot get key from column %d in line (len=%d): %s", column, len(s), s)
} else {
return k, nil
}