* lisp/emacs-lisp/helpers.el (string-join): New function.
This commit is contained in:
parent
e4091d8586
commit
4301875e6e
3 changed files with 8 additions and 1 deletions
1
etc/NEWS
1
etc/NEWS
|
@ -775,6 +775,7 @@ frame.
|
|||
** New library helpers.el for misc helper functions
|
||||
*** `hash-table-keys'
|
||||
*** `hash-table-values'
|
||||
*** `string-join`
|
||||
*** `string-trim-left'
|
||||
*** `string-trim-right'
|
||||
*** `string-trim'
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
2013-11-25 Bozhidar Batsov <bozhidar@bozhidar.com>
|
||||
2013-11-25 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* emacs-lisp/bytecomp.el (byte-compile-form): Fix a typo.
|
||||
|
||||
* emacs-lisp/helpers.el (string-join): New function.
|
||||
|
||||
2013-11-25 Sebastian Wiesner <lunaryorn@gmail.com>
|
||||
|
||||
* emacs-lisp/bytecomp.el (byte-compile-interactive-only-functions):
|
||||
|
|
|
@ -37,6 +37,10 @@
|
|||
(maphash (lambda (_k v) (push v values)) hash-table)
|
||||
values))
|
||||
|
||||
(defsubst string-join (strings &optional separator)
|
||||
"Join all STRINGS using SEPARATOR."
|
||||
(mapconcat 'identity strings separator))
|
||||
|
||||
(defsubst string-trim-left (string)
|
||||
"Remove leading whitespace from STRING."
|
||||
(if (string-match "\\`[ \t\n\r]+" string)
|
||||
|
|
Loading…
Add table
Reference in a new issue