Rudolf Adamkovič <rud...@adamkovic.org> writes: >> Maybe, but it is also much more complex in terms of parser. >> Backtracking will introduce non-linear complexity to the parser, >> degrading the performance significantly. > > Is that so? I thought it is all about simple precedence rules. In this > case, once the parser finds the opening \(, it interprets everything as > LaTeX, until it finds the closing \).
Yes, it is. Please check how Org parser works in `org-element--parse-elements' and `org-element--parse-objects'. >> We cannot change it at this point without breaking all the historical >> documents + third-party parsers. That's why I am talking about >> providing markup extension to address the issue rather than altering >> the existing parser fundamentals. > > It would only break the documents that have one-sided \( or \) in the > cells of the same column, no? And that is ... virtually never? In a theoretical case if we agree to what you are suggesting, it should not be just for tables. There are similar cases with other markup, like *foo =* *= bar* -- Ihor Radchenko // yantar92, Org mode maintainer, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92>