all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#36418: 26.2.90; mapconcat "SEPARATOR must be a string." is incorrect
@ 2019-06-28 13:23 Xu Chunyang
  2019-07-06  4:17 ` Stefan Kangas
  0 siblings, 1 reply; 3+ messages in thread
From: Xu Chunyang @ 2019-06-28 13:23 UTC (permalink / raw)
  To: 36418

C-h f mapconcat says

> SEPARATOR must be a string.

but nil works fine

    (mapconcat #'identity '("a" "b") nil)
    ;; => "ab"

and `string-join` relies on this fact (by the way, string-join's
docstring doesn't explain the case when separator is omitted or nil)

    (defsubst string-join (strings &optional separator)
      "Join all STRINGS using SEPARATOR."
      (mapconcat 'identity strings separator))

C-h S mapconcat says

> SEPARATOR, which also must be a string, or a vector or list of
> characters.

C-h f concat says

> Each argument may be a string or a list or vector of characters (integers).





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-06  7:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-28 13:23 bug#36418: 26.2.90; mapconcat "SEPARATOR must be a string." is incorrect Xu Chunyang
2019-07-06  4:17 ` Stefan Kangas
2019-07-06  7:32   ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.