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

Remove dead code in the stylesheet parser #1640

Merged
merged 1 commit into from Mar 23, 2022
Merged

Conversation

stof
Copy link
Contributor

@stof stof commented Feb 25, 2022

At that point, the scanner is still at the same position than the previous check for children returning a nested declaration, so it is
impossible for it to be looking at children.

As part of my rewrite of scssphp to a more modern and more spec-compliant codebase, I ported the dart-sass parser to PHP. This dead code was reported by our static analyzer in its updated version, and my own investigation of the code makes me agree with the tool.

At that point, the scanner is still at the same position than the
previous check for children returning a nested declaration, so  it is
impossible for it to be looking at children.
@stof
Copy link
Contributor Author

stof commented Mar 17, 2022

@nex3 has this PR been missed ?

Copy link
Member

@jathak jathak left a comment

Choose a reason for hiding this comment

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

Thanks! Sorry for the delay in reviewing

@jathak jathak merged commit 85ca0b2 into sass:main Mar 23, 2022
@stof stof deleted the clean_dead_code branch March 24, 2022 09:02
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.

None yet

2 participants