* lisp/org-element.el (org-element--collect-affiliated-keywords): Fix return value. * testing/lisp/test-org-element.el: Add test.
@@ -3547,7 +3547,7 @@ position of point and CDR is nil."
;; They will be parsed as a paragraph.
(when (looking-at "[ \t]*$") (goto-char origin) (setq output nil))
;; Return value.
- (cons (point) output))))
+ (cons origin output))))
@@ -165,6 +165,12 @@ Some other text
:name
(org-test-with-temp-text "#+NAME: para\nParagraph"
(org-element-at-point)))))
+ (should
+ (= 1
+ (org-element-property
+ :begin
+ (org-test-with-temp-text "#+NAME: para\nParagraph"
+ (org-element-at-point)))))
;; Parse multiple keywords.
(should
(equal