In contrast to other platforms on Windows it's not possible to activate valgrind. A great solution for MSVC would be to just use the CRT-Library with
Unfortunately that doesn't compile. The reason is, that with CRT-Library uses #define to replace malloc, realloc, and free by their debug-version; but the Qt sources contain methods whose names coincide with these standard library functions in some places:
- In QList's QListData has a realloc method. It's private and undocumented: all references are in your hands. It's just a minor refactoring.
- In QVarLengthArray first: it's just a private method. No problem to refactor this also.
- In QVarLengthArray second: it's a template seems to be used internally and undocumented. May be reachable from outside.
- New since 5.14 there is a method realloc in QVector.
Can't these usages just be renamed to remove the problems?
(Remark: I know there's another ticket to this topic but it's from 2014 and down-voted in priority – no one looks at it. This case is way more substantial than that ticket reflects!)