mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-19 23:20:52 +01:00
Try Clazy fix-its
clazy is a compiler plugin which allows clang to understand Qt semantics. You get more than 50 Qt related compiler warnings, ranging from unneeded memory allocations to misusage of API, including fix-its for automatic refactoring. https://invent.kde.org/sdk/clazy
This commit is contained in:
@@ -241,7 +241,8 @@ int TerminalStripDrawer::height() const
|
||||
|
||||
height_ = std::max(height_, m_pattern->m_spacer_rect.y() + m_pattern->m_spacer_rect.height());
|
||||
|
||||
for (const auto &rect : m_pattern->m_terminal_rect) {
|
||||
for (const auto& rect : std::as_const(m_pattern->m_terminal_rect))
|
||||
{
|
||||
height_ = std::max(height_, rect.y() + rect.height());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user