]> granicus.if.org Git - clang/commit
Remove the fixit for the diagnostics regarding capturing autoreleasing variables...
authorGeorge Karpenkov <ekarpenkov@apple.com>
Mon, 14 May 2018 20:29:16 +0000 (20:29 +0000)
committerGeorge Karpenkov <ekarpenkov@apple.com>
Mon, 14 May 2018 20:29:16 +0000 (20:29 +0000)
commit07fe64cddfe450fb0b1716958a04758f4b2ceae7
treed76aeae9d6a8261dd803318e151253c48a05c3b2
parent3593417ce457859f64bd1049c42501aa643b365c
Remove the fixit for the diagnostics regarding capturing autoreleasing variables in a block

The fixit is actively harmful, as it encourages developers to ignore the
warning and to write unsafe code.
It is almost impossible to write safe code while capturing autoreleasing
variables in the block, as in order to check that the block is never
called in the autoreleasing pool the developer has to check the
transitive closure of all potential callers of the block.

Differential Revision: https://reviews.llvm.org/D46778

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@332288 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaExpr.cpp
test/SemaObjC/arc.m