[PATCH] D36750: [analyzer] RetainCount: When diagnosing overrelease, mention if it's coming from a nested block.
Devin Coughlin via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 16 09:12:06 PDT 2017
dcoughlin added a comment.
> By the way, plist-based tests in retain-release.m are disabled since r163536 (~2012), and need to be updated. It's trivial to re-enable them but annoying to maintain - would we prefer to re-enable or delete them or replace with -analyzer-output=text tests?
This is rdar://problem/33514142
My preference would be to factor out/re-target some specific tests into their own file and check that with -verify + -analyzer-output=text and with plist comparisons
Comment at: lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp:89
ErrorReleaseNotOwned, // Release of an object that was not owned.
+ ErrorReleaseNotOwnedByBlock, // Release of an object not owned by a block.
Is it possible to detect this from the location context in RetainCountChecker::processNonLeakError() rather than encoding it in the analysis state? This would avoid a multiplicity of 'ByBlock' kinds.
More information about the cfe-commits