]> granicus.if.org Git - clang/commit
[analyzer] Don't track autorelease pools created by +new.
authorJordan Rose <jordan_rose@apple.com>
Thu, 31 Jan 2013 22:06:02 +0000 (22:06 +0000)
committerJordan Rose <jordan_rose@apple.com>
Thu, 31 Jan 2013 22:06:02 +0000 (22:06 +0000)
commite36d81b1eeab13fb1bbd15291d009a1699de6ec1
tree05b9782b758f3f54d6b06c3383dd8626b73fcd06
parent0ed439487491e09faffdbabfacb1d050292c7723
[analyzer] Don't track autorelease pools created by +new.

This matches our behavior for autorelease pools created by +alloc. Some
people like to create autorelease pools in one method and release them
somewhere else.

If you want safe autorelease pool semantics, use the new ARC-compatible
syntax: @autoreleasepool { ... }

<rdar://problem/13121353>

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174096 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
test/Analysis/retain-release.m