You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have an header with just the language and no spaces or other arguments, like #+begin_src python, when point is inside a polymode managed buffer (so a src block) org parses the language wrongly, it includes the subsequent line...the regex used by org to parse the language uses \S so any includes non white-space...and indeed \n is not a whitespace..but why does it happen only inside polymode? Parsing the point is at the header line works fine...
My current workaround is to just append a space to the end of the line if there isn't one
The text was updated successfully, but these errors were encountered:
Note the new line, and it doesn't have os because there is a space between import and os,
indeed the function org-element-src-block-parser defined in org-element.el matches against \S that is any non whitespace; since the org regex is loose about new lines I guess this is a problem with narrowing? since probably that org function only matches against 1 line, but when inside an innermode it matches against multi lines.
If you have an header with just the language and no spaces or other arguments, like
#+begin_src python
, when point is inside a polymode managed buffer (so a src block) org parses the language wrongly, it includes the subsequent line...the regex used by org to parse the language uses\S
so any includes non white-space...and indeed\n
is not a whitespace..but why does it happen only inside polymode? Parsing the point is at the header line works fine...My current workaround is to just append a space to the end of the line if there isn't one
The text was updated successfully, but these errors were encountered: