[PATCH] [analyzer][Review request] Partial fix for PR19102.
anton.yartsev at gmail.com
Wed Jun 4 17:40:44 PDT 2014
Attached patch is a partial fix for PR19102. The idea is to assume the unused operator new as not a leak if the following requirement is met:
* The invoked constructor has a parameter - pointer or reference to a record that has a public method (any access level , if a constructed record is a friend of a parameter record), that accepts a pointer to the type of the constructed record or one of its bases.
The analysis can be much more precise if the analyzer can analyze the body of the constructor, but for now the criteria above can be used regardless of whether the body of the constructor is accessible to the analyzer or not.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 6156 bytes
Desc: not available
More information about the cfe-commits