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

feat(parser): make line count header optional #143

Merged
merged 10 commits into from
Apr 2, 2024
Merged

Conversation

endes0
Copy link
Member

@endes0 endes0 commented Apr 2, 2024

For backward compatibility reasons, the code parser support an initial line indicating the number of lines of the code that was ignored but required. As @icasrod pointed, this line shouldn't be required at all. This PR fixes this and also updates the examples shown in the load code modals.

@endes0 endes0 requested a review from oxcabe April 2, 2024 11:07
@oxcabe oxcabe changed the title fix(parsers): don't require an unused initial lines count line feat(parsing): make line count header optional Apr 2, 2024
@oxcabe oxcabe changed the title feat(parsing): make line count header optional feat(parser): make line count header optional Apr 2, 2024
Copy link
Member

@oxcabe oxcabe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good so far. Add tests for both cases. Feel free to run biome on both parser files and, if possible, add some tsdoc documentation as well.

@endes0
Copy link
Member Author

endes0 commented Apr 2, 2024

Looking good so far. Add tests for both cases. Feel free to run biome on both parser files and, if possible, add some tsdoc documentation as well.

Done except for tsdoc, while it will be great I think it is outside this scope (and also, if I'm honest, I'm lazy ).

src/core/Common/CodeParser.ts Show resolved Hide resolved
src/core/Common/CodeParser.ts Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWCode.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWCode.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
@oxcabe
Copy link
Member

oxcabe commented Apr 2, 2024

This is getting noisy, 36 comments, almost all of them from reviewdog 😶

@endes0
Copy link
Member Author

endes0 commented Apr 2, 2024

This is getting noisy, 36 comments, almost all of them from reviewdog 😶

yeah, first con of it.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/Common/CodeParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/core/VLIW/VLIWParser.ts Outdated Show resolved Hide resolved
src/test/unit/core/Common/Code.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/Common/Code.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
src/test/unit/core/VLIW/VLIWParser.spec.ts Outdated Show resolved Hide resolved
@oxcabe oxcabe merged commit 8e072fa into main Apr 2, 2024
2 checks passed
@oxcabe oxcabe deleted the fix/parser-first-line branch April 2, 2024 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants