-
Notifications
You must be signed in to change notification settings - Fork 591
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
[Markdown] reduce backtracking possibilities #877
Conversation
I find the majority of these comments to be redundant. I can see myself that |
I quite like the idea of being able to just read the comments to understand what a regex is doing, without having to look at the pattern itself at all, hence the "redundant" comments :) if you were to become the main maintainer of this package/syntax then I'm sure you could feel free to remove them ;) I've updated the code fence regex you didn't like though :) |
Of course, I was just voicing my opinion and giving an analogy to code. I just spotted the code fence regex while trying to look for a comment that does not literally describe the regex and something seemed off, so that was pure coincidence. 😆 |
[Markdown] reduce backtracking possibilities
Everything passes with the latest unreleased version of Sublime Text |
[Markdown] reduce backtracking possibilities
this PR reduces the number of backtracking possibilities for regex engines like Oniguruma that use backtracking, and also explains the regex patterns better.
a simple Markdown snippet with a missing end backtick like
will now fail in 73 steps rather than over 5000!