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

chore: mini refactorings and dead code removal #5512

Merged
merged 3 commits into from
Jul 20, 2024

Conversation

Nerixyz
Copy link
Contributor

@Nerixyz Nerixyz commented Jul 18, 2024

The PR does a few things:

  • Removes ConcurrentMap.hpp (2x: util/ and common/)
  • Removes util/Clamp.hpp (uses C++ 17's std::clamp)
  • Removes util/SplitCommand.{c,h}pp (uses QProcess::splitCommand, 5.15+)
  • Removes util/Overloaded.hpp (we only use util/Variant.hpp)
  • Removes util/PersistSignalVector.hpp (unused)
  • Removes unused code from util/PostToThread.hpp
  • Changes chatterino::_helpers_internal to chatterino::helpers::detail
  • Adds missing whitespace in DisplayBadge.hpp
  • Removes unused <algorithm> include in ExponentialBackoff.hpp
  • Changes the initialization from constructor → members for step_ in ExponentialBackoff.hpp (clang-tidy complained that step_ was uninitialized (?))
  • Adds IWYU paragma: export to PubSubMessages.hpp (sadly clangd doesn't seem to pick this up in files using the header)
  • Converts LayoutCreator to use concepts (should make it a bit easier to read)
    • Replaces T2 with U - U being the newly created/returned type
    • Introduces requirement for addSpacing to be called on a QLayout (widgets don't support that)
    • Simplifies addItem (a bit)

@pajlada pajlada merged commit b3c09b6 into Chatterino:master Jul 20, 2024
17 of 19 checks passed
@Nerixyz Nerixyz deleted the chore/mini-stuff branch July 20, 2024 10:02
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