Skip to content

Commit 263d7b5

Browse files
committed
Fail-fast in haskell-mode-jump-to-tag
`haskell-mode-jump-to-tag` will now crash if given a non-`nil` non-string (inside `haskell-string-trim`), as gracjan requested in #603.
1 parent c4cbd61 commit 263d7b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

haskell.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@
312312
(let ((ident (haskell-ident-at-point))
313313
(tags-file-name (haskell-session-tags-filename (haskell-session)))
314314
(tags-revert-without-query t))
315-
(when (and (stringp ident) (not (string= "" (haskell-string-trim ident))))
315+
(when (and ident (not (string= "" (haskell-string-trim ident))))
316316
(cond ((file-exists-p tags-file-name)
317317
(find-tag ident next-p))
318318
(t (haskell-process-generate-tags ident))))))

0 commit comments

Comments
 (0)