File tree Expand file tree Collapse file tree 1 file changed +13
-15
lines changed
Expand file tree Collapse file tree 1 file changed +13
-15
lines changed Original file line number Diff line number Diff line change @@ -377,21 +377,19 @@ and \"c\".
377377 " Convert list of DECLARATIONS to alist for `imenu--index-alist' .
378378
379379Declarations are organized as trees."
380- (apply
381- 'nconc
382- (mapcar
383- (lambda (declaration )
384- (let* ((name-token (swift-mode:declaration:name-token declaration))
385- (name (swift-mode:token:text name-token))
386- (position (swift-mode:token:start name-token))
387- (children (swift-mode:declaration:children declaration)))
388- (cons
389- (cons name position)
390- (mapcar
391- (lambda (pair )
392- (cons (concat name " ." (car pair)) (cdr pair)))
393- (swift-mode:format-for-imenu:flat children)))))
394- declarations)))
380+ (seq-mapcat
381+ (lambda (declaration )
382+ (let* ((name-token (swift-mode:declaration:name-token declaration))
383+ (name (swift-mode:token:text name-token))
384+ (position (swift-mode:token:start name-token))
385+ (children (swift-mode:declaration:children declaration)))
386+ (cons
387+ (cons name position)
388+ (mapcar
389+ (lambda (pair )
390+ (cons (concat name " ." (car pair)) (cdr pair)))
391+ (swift-mode:format-for-imenu:flat children)))))
392+ declarations))
395393
396394(defun swift-mode:format-for-imenu:nested (declarations )
397395 " Convert list of DECLARATIONS to alist for `imenu--index-alist' .
You can’t perform that action at this time.
0 commit comments