0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-08-24 20:02:51 +00:00

org-indent-line: Remove unnecessary call to `org-element-at-point'

* lisp/org.el (org-indent-line): Do not re-calculate already known
element.
This commit is contained in:
Ihor Radchenko 2023-05-09 16:17:40 +02:00
parent fe74a3ed2d
commit 9d304d371e
No known key found for this signature in database
GPG key ID: 6470762A7DA11D8B

View file

@ -19068,8 +19068,7 @@ Also align node properties according to `org-property-format'."
;; signals org-src--edit-element to preserve the indentation on exit
(when (and (looking-at-p "^[[:space:]]*$")
(not org-src-preserve-indentation))
(let ((element (org-element-at-point))
block-content-ind some-ind)
(let (block-content-ind some-ind)
(org-with-point-at (org-element-property :begin element)
(setq block-content-ind (+ (org-current-text-indentation)
org-edit-src-content-indentation))