-
-
Notifications
You must be signed in to change notification settings - Fork 557
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
CRLF support #14
Comments
I forgot to mention that commonmark.js seems to handle CRLFs correctly in every case I tested. |
Yes, please do post your patches to blocks.c. And, good idea about the +++ Ben Trask [Mar 15 15 16:53 ]:
|
Sorry for the delay, working on a more complete patch. Needs some changes to scanner.re too, not sure what else yet. |
* Add failing UTF-8 BOM test * Add simple UTF-8 BOM skip * Restrict BOM check to first line
Thanks for your quick work on issue #11. I've continued integrating Cmark with my project.
I've found that when parsing files that use CRLF line endings with Cmark, block quotes extend into subsequent paragraphs, text after lists stays indented, and there are problems with fenced code.
I think the biggest problem is that the test cases don't seem to exercise alternate line endings at all. I'd suggest that all of the test cases should be automatically converted to each type of line ending (LF, CR, and CRLF) during
make test
and Cmark should be expected to pass all of them.Perhaps there should also be some test cases for a single file brokenly mixing different line endings. This should be possible to handle reasonably intelligently.
I got CRLF support mostly working with some quick patches to blocks.c, which I can post if it would help. I didn't try digging into the tests.
The text was updated successfully, but these errors were encountered: