[clazy] [Bug 431389] New: qstring-allocations does not detect constructing a QStringList with braced initialization

Christian Schärf bugzilla_noreply at kde.org
Sun Jan 10 13:28:11 GMT 2021


https://bugs.kde.org/show_bug.cgi?id=431389

            Bug ID: 431389
           Summary: qstring-allocations does not detect constructing a
                    QStringList with braced initialization
           Product: clazy
           Version: unspecified
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: unassigned-bugs at kde.org
          Reporter: c.schaerf at t-online.de
                CC: smartins at kde.org
  Target Milestone: ---

Consider the following code:

#include <QStringList>

void f() {
    QStringList list{"test"};
}

Clazy does not emit a warning from the qstring-allocations check, despite a
QString being constructed from a const char*. The the relevant AST is attached.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the Unassigned-bugs mailing list