https://bugs.kde.org/show_bug.cgi?id=402917
Bug ID: 402917
Summary: Check converting number to string
Product: clazy
Version: unspecified
Platform: Other
OS: Linux
Status: REPORTED
Severity: minor
Priority: NOR
Component: general
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Target Milestone: ---
I have found in my code strings like this:
int value = 2; // just an example
...
QString("%1").arg(value)
Clazy complains about qstring-allocations here. This is correct, but such a
code has small sense since we could just write
QString::number(value) or QString().number(value)
It seems Clazy could improve readability if advises replace single placeholder
(%1-%99) with conversion from number.
--
You are receiving this mail because:
You are watching all bug changes.