-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Error with single backslash at end of line #2860
Comments
The missing control sequence can be defined as equivalent to
A backslash followed by a tab character also gives a parse error, and could presumably be defined as a macro too... However, line breaks and tabs should be equivalent to spaces not only in source text, but also in macro definitions. Perhaps |
LaTeX parses `\` followed by whitespace including up to one newline as equivalent to `\ `. (With multiple newlines, you get paragraph breaks.) Fix #2860.
* fix: Correctly parse \ followed by whitespace LaTeX parses `\` followed by whitespace including up to one newline as equivalent to `\ `. (With multiple newlines, you get paragraph breaks.) Fix #2860. * Improve comments * Avoid second RegExp match in control words * Document capturing groups Co-authored-by: Ron Kok <ronkok@comcast.net>
🎉 This issue has been resolved in version 0.13.6 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Describe the bug:
(Copying from a fixed pandoc issue:)
KaTeX treats a single
\
at the end of the line as an error.To Reproduce:
Steps to reproduce the behavior:
\
followed immediately by a line break.KaTeX parse error: Undefined control sequence: \ at position 1: \̲ ̲
.Expected behavior:
It should produce a regular space instead of a parse error.
Screenshots:
Environment:
Additional context:
MathJax allows a single backslash at the end of the line.
The text was updated successfully, but these errors were encountered: