From fe0f30e02276391e9b4a56c0c8af2ec9a9efdb04 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Wed, 13 May 2015 12:37:53 +0200 Subject: [PATCH] org-element: Tiny refactoring * lisp/org-element.el (org-element-link-parser): Use `string-to-char' instead of (aref STRING 0). --- 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 9037b3723..be19dd28e 100644 --- a/lisp/org-element.el +++ b/lisp/org-element.el @@ -3062,7 +3062,7 @@ Assume point is at the beginning of the link." ((string-match "\\`(\\(.*\\))\\'" raw-link) (setq type "coderef" path (match-string 1 raw-link))) ;; Custom-id type: PATH is the name of the custom id. - ((= (aref raw-link 0) ?#) + ((= (string-to-char raw-link) ?#) (setq type "custom-id" path (substring raw-link 1))) ;; Fuzzy type: Internal link either matches a target, an ;; headline name or nothing. PATH is the target or