diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2015-06-28 11:37:13 +0200 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2015-06-28 11:37:13 +0200 |
commit | aa9c4bfb6fe1f5db240b4f9b2d781abd1138e018 (patch) | |
tree | 72547e50703a5bc6c2e0b42c909e2a88f9a51a83 | |
parent | 3c73e6476cb6ffac277d95060bc42751895a0e5f (diff) | |
download | org-mode-aa9c4bfb6fe1f5db240b4f9b2d781abd1138e018.tar.gz |
org-element: Remove dependency on `org-at-table-p'
* lisp/org-element.el (org-element-table-parser): Do not call
`org-at-table.el-p'.
(org-element--current-element): Do not call `org-at-table-p'.
-rw-r--r-- | lisp/org-element.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/org-element.el b/lisp/org-element.el index 29c5464..ff0fa75 100644 --- a/lisp/org-element.el +++ b/lisp/org-element.el @@ -2492,7 +2492,7 @@ Assume point is at the beginning of the table." (save-excursion (let* ((case-fold-search t) (table-begin (point)) - (type (if (org-at-table.el-p) 'table.el 'org)) + (type (if (looking-at "[ \t]*|") 'org 'table.el)) (begin (car affiliated)) (table-end (if (re-search-forward org-table-any-border-regexp limit 'm) @@ -3787,7 +3787,8 @@ element it has to parse." ((looking-at "%%(") (org-element-diary-sexp-parser limit affiliated)) ;; Table. - ((org-at-table-p t) (org-element-table-parser limit affiliated)) + ((looking-at "[ \t]*\\(|\\|\\+\\(-+\\+\\)+[ \t]*$\\)") + (org-element-table-parser limit affiliated)) ;; List. ((looking-at (org-item-re)) (org-element-plain-list-parser |