-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Markup parsers should only consider markup on word boundaries #49
Comments
CC: @zhujinxuan (only CC'ing to let you know, I have a branch with a fix already in-place I haven't pushed it yet because I want to add more thorough tests). |
Hi, I think we shall write Hyperlink parser like the LaTeX parser. The elements inside the [] shall be considered as |
@zhujinxuan I agree with you. However this is still a problem with the markup parser as it considers some text as "marked up" that org-mode's fontification does not. I have the latter fixed and I will also implement your suggestion. |
@ixmatus I think we can guard that by typing. If we define
Then we will not need to worry about whether the content of LaTeX is parsed as markup. |
I don't think that's a problem. I mean that:
... is parsed incorrectly. Disregarding org-mode hyperlink markup syntax, we expect
|
As an example, some of the tests demonstrate incorrect behavior too, for instance:
... should not parse as |
@ixmatus Do you have a document of orgmode markup syntax? It seems many corner cases are not documented in https://orgmode.org/manual/Markup.html |
@ixmatus I agree. I tested in emacs-org. I am wondering shall we consider |
No, I don't think we should. I think we should follow org-mode's fontification behavior and treat |
I'm finding lots of corner cases (by adding tests) that we didn't account for in the markup parser that I need to resolve before I can push up my work. |
@ixmatus Can you open up a PR with some of the tests? |
I will when I clean up some of my experiments :) I will probably get to it throughout the week, no stress! |
I haven't had much free-time to finish this up but I do have free-time coming up for the holidays and I will be working on this then. |
@ixmatus Hi, are you working on this recently? If not, I will begin the fix in next Sat (Mar 30th) |
@zhujinxuan my real life and job have taken an intense turn. I won't get to this until late May now so if you're able to then that would be great. Thank you. |
Discovered while testing the HyperLink parser. The parser will incorrectly parse the following:
... as:
This should be easy to fix since formatting markup is only treated as such if the beginning sentinel character is preceded by whitespace and followed by a non-whitespace character.
The text was updated successfully, but these errors were encountered: