Declare defsubst indentation

* exwm-core.el (exwm--id->buffer, exwm--buffer->id, exwm--terminal-p):
* exwm-input.el (exwm-input--unread-event):
* exwm-workspace.el (exwm-workspace--position)
(exwm-workspace--workspace-p): Declare indentation.
This commit is contained in:
Adrián Medraño Calvo 2023-08-18 00:00:00 +00:00
parent d340a6a563
commit d8fcf18db7
3 changed files with 8 additions and 2 deletions

View file

@ -116,10 +116,12 @@ FORMAT-STRING is a string specifying the message to output, as in
(defsubst exwm--id->buffer (id) (defsubst exwm--id->buffer (id)
"X window ID => Emacs buffer." "X window ID => Emacs buffer."
(declare (indent defun))
(cdr (assoc id exwm--id-buffer-alist))) (cdr (assoc id exwm--id-buffer-alist)))
(defsubst exwm--buffer->id (buffer) (defsubst exwm--buffer->id (buffer)
"Emacs buffer BUFFER => X window ID." "Emacs buffer BUFFER => X window ID."
(declare (indent defun))
(car (rassoc buffer exwm--id-buffer-alist))) (car (rassoc buffer exwm--id-buffer-alist)))
(defun exwm--lock (&rest _args) (defun exwm--lock (&rest _args)
@ -183,6 +185,7 @@ least SECS seconds later."
(defsubst exwm--terminal-p (&optional frame) (defsubst exwm--terminal-p (&optional frame)
"Return t when FRAME's terminal is EXWM's terminal. "Return t when FRAME's terminal is EXWM's terminal.
If FRAME is null, use selected frame." If FRAME is null, use selected frame."
(declare (indent defun))
(eq exwm--terminal (frame-terminal frame))) (eq exwm--terminal (frame-terminal frame)))
(defun exwm--get-client-event-mask () (defun exwm--get-client-event-mask ()

View file

@ -587,9 +587,11 @@ instead."
(and (= emacs-major-version 26) (and (= emacs-major-version 26)
(< emacs-minor-version 2))) (< emacs-minor-version 2)))
(defsubst exwm-input--unread-event (event) (defsubst exwm-input--unread-event (event)
(declare (indent defun))
(setq unread-command-events (setq unread-command-events
(append unread-command-events (list event)))) (append unread-command-events (list event))))
(defsubst exwm-input--unread-event (event) (defsubst exwm-input--unread-event (event)
(declare (indent defun))
(setq unread-command-events (setq unread-command-events
(append unread-command-events `((t . ,event))))))) (append unread-command-events `((t . ,event)))))))

View file

@ -150,8 +150,8 @@ Please manually run the hook `exwm-workspace-list-change-hook' afterwards.")
(defsubst exwm-workspace--position (frame) (defsubst exwm-workspace--position (frame)
"Retrieve index of given FRAME in workspace list. "Retrieve index of given FRAME in workspace list.
NIL if FRAME is not a workspace."
NIL if FRAME is not a workspace" (declare (indent defun))
(cl-position frame exwm-workspace--list)) (cl-position frame exwm-workspace--list))
(defsubst exwm-workspace--count () (defsubst exwm-workspace--count ()
@ -160,6 +160,7 @@ NIL if FRAME is not a workspace"
(defsubst exwm-workspace--workspace-p (frame) (defsubst exwm-workspace--workspace-p (frame)
"Return t if FRAME is a workspace." "Return t if FRAME is a workspace."
(declare (indent defun))
(memq frame exwm-workspace--list)) (memq frame exwm-workspace--list))
(defsubst exwm-workspace--workarea (frame) (defsubst exwm-workspace--workarea (frame)