* bug#36441: 26.2.90; Simplify dom-texts
@ 2019-06-30 4:30 Xu Chunyang
2019-07-06 18:43 ` Noam Postavsky
0 siblings, 1 reply; 2+ messages in thread
From: Xu Chunyang @ 2019-06-30 4:30 UTC (permalink / raw)
To: 36441
In the dom-texts function
(mapconcat 'identity (mapcar ...) ...)
can be simplified
(mapconcat ...)
diff -u --label /Users/xcy/src/emacs-mac/lisp/dom.el --label \#\<buffer\ dom.el\> /Users/xcy/src/emacs-mac/lisp/dom.el /var/folders/7f/s191h4q97p90374yw15ssrs00000gn/T/buffer-content-jql2ad
--- /Users/xcy/src/emacs-mac/lisp/dom.el
+++ #<buffer dom.el>
@@ -79,13 +79,11 @@
(defun dom-texts (node &optional separator)
"Return all textual data under NODE concatenated with SEPARATOR in-between."
(mapconcat
- 'identity
- (mapcar
- (lambda (elem)
- (if (stringp elem)
- elem
- (dom-texts elem separator)))
- (dom-children node))
+ (lambda (elem)
+ (if (stringp elem)
+ elem
+ (dom-texts elem separator)))
+ (dom-children node)
(or separator " ")))
(defun dom-child-by-tag (dom tag)
Diff finished. Sun Jun 30 12:23:43 2019
^ permalink raw reply [flat|nested] 2+ messages in thread
* bug#36441: 26.2.90; Simplify dom-texts
2019-06-30 4:30 bug#36441: 26.2.90; Simplify dom-texts Xu Chunyang
@ 2019-07-06 18:43 ` Noam Postavsky
0 siblings, 0 replies; 2+ messages in thread
From: Noam Postavsky @ 2019-07-06 18:43 UTC (permalink / raw)
To: Xu Chunyang; +Cc: 36441
severity 36441 minor
tags 36441 fixed
close 36441 27.1
quit
Xu Chunyang <mail@xuchunyang.me> writes:
> In the dom-texts function
>
> (mapconcat 'identity (mapcar ...) ...)
>
> can be simplified
>
> (mapconcat ...)
Right, applied on master.
d07dd64fd0 2019-07-06T14:34:47-04:00 "* lisp/dom.el (dom-texts): Simplify (Bug#36441)."
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=d07dd64fd0476e0346d2de65b965193703ae6e7a
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-07-06 18:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-30 4:30 bug#36441: 26.2.90; Simplify dom-texts Xu Chunyang
2019-07-06 18:43 ` Noam Postavsky
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).