Skip to content
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

Windows linend sequence CRLF throw parser errors (see also #33) #45

Closed
babig opened this issue Apr 9, 2018 · 3 comments
Closed

Windows linend sequence CRLF throw parser errors (see also #33) #45

babig opened this issue Apr 9, 2018 · 3 comments
Labels

Comments

@babig
Copy link

babig commented Apr 9, 2018

The appended files test-eol.zip contain the same minimal argument, one wir LF lineendings, one with crlf. The first works fine, the second throws a parser error:

13:36:39-Z:>argdown --version
0.9.0

13:36:44-Z:>argdown html test-lf.ad

13:36:51-Z:>argdown html test-crlf.ad
Argdown syntax errors in input: 1

At 6:8
Missing inference. Use four hyphens (----) between two numbered statements to in
sert an inference in your reconstruction and mark the latter statement as a conc
lusion.

TypeError: Cannot read property 'name' of undefined
at ArgdownTreeWalker.onArgumentStatementExit (C:\Users\gb\AppData\Roaming\np
m\node_modules\argdown-cli\node_modules\argdown-parser\lib\src\plugins\ModelPlug
in.js:735:32)
at ArgdownTreeWalker.emit (C:\Users\gb\AppData\Roaming\npm\node_modules\argd
own-cli\node_modules\eventemitter3\index.js:192:18)
at ArgdownTreeWalker.visitNode (C:\Users\gb\AppData\Roaming\npm\node_modules
\argdown-cli\node_modules\argdown-parser\lib\src\ArgdownTreeWalker.js:50:16)
at ArgdownTreeWalker.visitNode (C:\Users\gb\AppData\Roaming\npm\node_modules
\argdown-cli\node_modules\argdown-parser\lib\src\ArgdownTreeWalker.js:45:18)
at ArgdownTreeWalker.visitNode (C:\Users\gb\AppData\Roaming\npm\node_modules
\argdown-cli\node_modules\argdown-parser\lib\src\ArgdownTreeWalker.js:45:18)
at ArgdownTreeWalker.visitNode (C:\Users\gb\AppData\Roaming\npm\node_modules
\argdown-cli\node_modules\argdown-parser\lib\src\ArgdownTreeWalker.js:45:18)
at ArgdownTreeWalker.walk (C:\Users\gb\AppData\Roaming\npm\node_modules\argd
own-cli\node_modules\argdown-parser\lib\src\ArgdownTreeWalker.js:25:12)
at AsyncArgdownApplication.runAsync (C:\Users\gb\AppData\Roaming\npm\node_mo
dules\argdown-cli\lib\src\AsyncArgdownApplication.js:40:34)
at

@christianvoigt
Copy link
Owner

Strange, I thought I fixed this. I could reproduce the error and will look into it.

@christianvoigt
Copy link
Owner

ok, found the issue. The test I had written only tested for line endings after statements outside argument reconstructions. So I overlooked those cases in the lexer. This will be fixed in the next release.

@christianvoigt
Copy link
Owner

fixed in argdown-cli 0.9.1.
The VS Code extension still needs to be update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants