Skip to content

Remove or fix dead code / unused exports#2632

Merged
robertbrignull merged 13 commits intomainfrom
robertbrignull/deadcode_changes
Jul 24, 2023
Merged

Remove or fix dead code / unused exports#2632
robertbrignull merged 13 commits intomainfrom
robertbrignull/deadcode_changes

Conversation

@robertbrignull
Copy link
Copy Markdown
Contributor

See #2631 for the dead code CI check. This PR is the result of going through the codebase fixing all of the cases found by that check. Where there is code deleted I've done each item as a separate commit, and then at the end I've done one commit for all the cases of things that were unnecessarily-exported but still used within their file.

I haven't tested all features yet to make sure everything still works, but from what I could tell as I was going through things there's nothing that's likely to not be caught at compile time, so I'm fairly confident this is all ok so long as it compiles.

Checklist

  • CHANGELOG.md has been updated to incorporate all user visible changes made by this pull request.
  • Issues have been created for any UI or other user-facing changes made by this pull request.
  • [Maintainers only] If this pull request makes user-facing changes that require documentation changes, open a corresponding docs pull request in the github/codeql repo and add the ready-for-doc-review label there.

Copy link
Copy Markdown
Contributor

@charisk charisk left a comment

Choose a reason for hiding this comment

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

Thanks for cleaning up! 🧹

@robertbrignull robertbrignull force-pushed the robertbrignull/deadcode_changes branch from 7f36372 to 729471d Compare July 24, 2023 13:20
@robertbrignull
Copy link
Copy Markdown
Contributor Author

It seems that extensions/ql-vscode/test/__mocks__/styleMock.ts and extensions/ql-vscode/test/__mocks__/fileMock.ts are in fact needed. I missed the references to them originally. I've added those back in (by removing the commits that deleted them) and I'll mark them as allowed in #2631

@robertbrignull robertbrignull force-pushed the robertbrignull/deadcode_changes branch from 729471d to 8e8e0fa Compare July 24, 2023 13:22
@robertbrignull
Copy link
Copy Markdown
Contributor Author

Annoying I rebased on the wrong base commit originally, but https://github.com/github/vscode-codeql/compare/7f363723f9c0e4c2d4703172d2f5497a00a6e1b3..8e8e0faa9e4e0284d0ea5ec2be9dfbb06f8515ca shows the change from where this PR was at before.

@robertbrignull robertbrignull enabled auto-merge July 24, 2023 15:26
@robertbrignull robertbrignull merged commit ef27730 into main Jul 24, 2023
@robertbrignull robertbrignull deleted the robertbrignull/deadcode_changes branch July 24, 2023 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants