GNU bug report logs - #34104
26.1; Inaccurate error report of (sort "cba" #'<)

Previous Next

Package: emacs;

Reported by: mail <at> xuchunyang.me

Date: Wed, 16 Jan 2019 14:54:03 UTC

Severity: minor

Found in version 26.1

Done: Philipp Stephani <p.stephani2 <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Philipp Stephani <p.stephani2 <at> gmail.com>
To: mail <at> xuchunyang.me
Cc: 34104 <at> debbugs.gnu.org
Subject: bug#34104: 26.1; Inaccurate error report of (sort "cba" #'<)
Date: Thu, 17 Jan 2019 23:43:16 +0100
[Message part 1 (text/plain, inline)]
Am Mi., 16. Jan. 2019 um 15:54 Uhr schrieb <mail <at> xuchunyang.me>:
>
>
> Eval (sort "cba" #'<) gives
>
> Debugger entered--Lisp error: (wrong-type-argument sequencep "cba")
>   sort("cba" <)
>   eval((sort "cba" (function <)) nil)
>   elisp--eval-last-sexp(nil)
>   eval-last-sexp(nil)
>   funcall-interactively(eval-last-sexp nil)
>   call-interactively(eval-last-sexp nil nil)
>   command-execute(eval-last-sexp)
>
> the error is inaccurate since "cba" is indeed a sequence
>
> (sequencep "cba")
> ;; => t
>
> it should report "cba" is not a list or vector instead.
>


Here's a patch.
[0001-Improve-error-data-when-passing-a-wrong-type-to-sort.txt (text/plain, attachment)]

This bug report was last modified 6 years and 184 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.