Hi there,

I’ve noticed that `org-element-parser` upcases the keywords, even though
the standard established in 13424336a6f30c50952d291e7a82906c1210daf0 is
to ‘Prefer lower case letters for blocks and keywords’.

I’ve changed it to `downcase` to maintain consistency.  This might cause
problems with some hard-coded upper case letters in the codebase, but
I haven’t run into any issue so far.

HTH,

-- 
Leo Vivier
>From 574549a1ab07fd1500111a25d3f1caec4aa40bfb Mon Sep 17 00:00:00 2001
From: Leo Vivier <leo.vivier+...@gmail.com>
Date: Mon, 8 Jun 2020 12:14:55 +0200
Subject: [PATCH] org-element.el: Fix properties being upcased by parser
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

* org-element.el (org-element-keyword-parser): Downcase properties
instead of upcasing them.

This is to follow the standard established by
13424336a6f30c50952d291e7a82906c1210daf0 to ‘Prefer lower case letters
for blocks and keywords’.

TINY CHANGE
---
 lisp/org-element.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/org-element.el b/lisp/org-element.el
index ac41b7650..e73b37b2b 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -2184,7 +2184,7 @@ containing `:key', `:value', `:begin', `:end', `:post-blank' and
     (let ((begin (or (car affiliated) (point)))
 	  (post-affiliated (point))
 	  (key (progn (looking-at "[ \t]*#\\+\\(\\S-*\\):")
-		      (upcase (match-string-no-properties 1))))
+		      (downcase (match-string-no-properties 1))))
 	  (value (org-trim (buffer-substring-no-properties
 			    (match-end 0) (point-at-eol))))
 	  (pos-before-blank (progn (forward-line) (point)))
-- 
2.26.2

Reply via email to