Function: majutsu-template--method-split-segments
majutsu-template--method-split-segments is a natively compiled
function defined in majutsu-template.el.
Signature
(majutsu-template--method-split-segments INITIAL-NAME NODES)
Documentation
Split method chain into segments starting with INITIAL-NAME (string).
NODES are the remaining argument nodes. Returns list of (NAME . ARGS).
Source Code
;; Defined in /nix/store/jagqw3nms546pad0gxi5f3wsckk6pji7-emacs-packages-deps/share/emacs/site-lisp/majutsu-template.el
(defun majutsu-template--method-split-segments (initial-name nodes)
"Split method chain into segments starting with INITIAL-NAME (string).
NODES are the remaining argument nodes. Returns list of (NAME . ARGS)."
(let ((segments '())
(current-name initial-name)
(current-args '()))
(dolist (node nodes)
(if (majutsu-template--method-name-node-p node)
(progn
(push (cons current-name (nreverse current-args)) segments)
(setq current-name (majutsu-template--method-name-from-node node)
current-args '()))
(push node current-args)))
(push (cons current-name (nreverse current-args)) segments)
(nreverse segments)))