Skip to content

Explicitly setting the line number fixes #44 #54

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dr0ps
Copy link

@dr0ps dr0ps commented Jan 4, 2022

I added a bunch of tests code for the various parts of the tool. I stepped through the failing tests with a debugger. I found that the test at the beginning of the parser line loop does not correctly break the loop at the next line as the current line is still empty. This is because the gcode will only be pushed by the next mnemonic, there is no comment and the line number is none. Therefore it helps to immediately set the line number when processing the first word. Unfortunately this seems to break the "G\n" case in the docs. I personally do not care for this case at all so I did not look into it. Now it parses Fusion360 generated code perfectly and that matters to me.

@dr0ps dr0ps changed the title Setting the line numer explicitly fixes #44 Explicitly Setting the line number fixes #44 Jan 4, 2022
@dr0ps dr0ps changed the title Explicitly Setting the line number fixes #44 Explicitly setting the line number fixes #44 Jan 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant