diff options
author | Stefan Kangas <stefankangas@gmail.com> | 2022-08-23 04:54:57 +0200 |
---|---|---|
committer | Stefan Kangas <stefankangas@gmail.com> | 2022-08-23 04:54:57 +0200 |
commit | b7e867b841f47dcff3aeaef9b5608a237386ce70 (patch) | |
tree | 57154cb336fcfdf9fbf80e4c6bb24b07a0432b66 /lisp/org/org-element.el | |
parent | e425b7d231d02e76ec3e3790418121fc07877e70 (diff) | |
download | emacs-b7e867b841f47dcff3aeaef9b5608a237386ce70.tar.gz emacs-b7e867b841f47dcff3aeaef9b5608a237386ce70.tar.bz2 emacs-b7e867b841f47dcff3aeaef9b5608a237386ce70.zip |
Make point-at-eol and point-at-bol obsolete
* lisp/subr.el (point-at-eol, point-at-bol): Make XEmacs compat
aliases obsolete in favor of `pos-bol'/'line-beginning-position' or
'pos-eol'/'line-end-position'. Update callers.
Ref: https://lists.gnu.org/r/emacs-devel/2022-08/msg00853.html
Diffstat (limited to 'lisp/org/org-element.el')
-rw-r--r-- | lisp/org/org-element.el | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/org/org-element.el b/lisp/org/org-element.el index 20b5b030392..4c018062af3 100644 --- a/lisp/org/org-element.el +++ b/lisp/org/org-element.el @@ -2205,7 +2205,7 @@ CDR is a plist containing `:key', `:value', `:begin', `:end', (key (progn (looking-at "[ \t]*#\\+\\(\\S-*\\):") (upcase (match-string-no-properties 1)))) (value (org-trim (buffer-substring-no-properties - (match-end 0) (point-at-eol)))) + (match-end 0) (line-end-position)))) (pos-before-blank (progn (forward-line) (point))) (end (progn (skip-chars-forward " \r\t\n" limit) (if (eobp) (point) (line-beginning-position))))) @@ -4273,7 +4273,7 @@ This function assumes that current major mode is `org-mode'." (goto-char (point-min)) (org-skip-whitespace) (org-element--parse-elements - (point-at-bol) (point-max) + (line-beginning-position) (point-max) ;; Start in `first-section' mode so text before the first ;; headline belongs to a section. 'first-section nil granularity visible-only (list 'org-data nil)))) @@ -6207,12 +6207,12 @@ end of ELEM-A." (end-A (save-excursion (goto-char (org-element-property :end elem-A)) (skip-chars-backward " \r\t\n") - (point-at-eol))) + (line-end-position))) (beg-B (org-element-property :begin elem-B)) (end-B (save-excursion (goto-char (org-element-property :end elem-B)) (skip-chars-backward " \r\t\n") - (point-at-eol))) + (line-end-position))) ;; Store inner overlays responsible for visibility status. ;; We also need to store their boundaries as they will be ;; removed from buffer. |