[PATCH][Review request] unix.Malloc checker improvement: +handling new/delete, +memory.MismatchedFree, +memory.MismatchedDelete, +improved display names for allocators/deallocators

Anton Yartsev anton.yartsev at gmail.com
Thu Mar 28 17:42:06 PDT 2013


>> Evolved one more problem to solve: if overloaded standard operator 
>> new is defined and is called as a function, then it is not recognized 
>> as overloaded operator for some reason. Tests testOpNewArray() and 
>> testOpNew() in NewDelete-custom.cpp cover these issue.
>
> You can check if it has to do with redeclarations of the allocator 
> function, but I wouldn't expect that. Definitely something we need to 
> fix before putting out another open-source checker build.
Addressed the issue. Actually the problem is caused by the fact, that 
overloaded operator new was inlined and has not been processed by 
checkPostStmt(const CallExpr) at all as it skips inlined calls.
What Is the reason for skipping inline calls?


-- 
Anton




More information about the cfe-commits mailing list