[PATCH] D54912: [attributes] Add a family of OS_CONSUMED, OS_RETURNS and OS_RETURNS_RETAINED attributes
Aaron Ballman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 30 06:21:08 PST 2018
aaron.ballman added inline comments.
================
Comment at: cfe/trunk/lib/Sema/SemaDeclAttr.cpp:4862
+ case ParsedAttr::AT_OSReturnsNotRetained:
ExpectedDeclKind = ExpectedFunctionOrMethod;
break;
----------------
I mentioned that I could fix this up in another patch, but there's a different subtlety here -- you can apply NSReturnsRetained and friends to types. See test\SemaObjC\attr-ns_returns_retained.m for an example -- where it's being added to a block type. It also seems to appertain to block literals (test\SemaObjC\block-literal-with-attribute.m).
Should the OS versions also apply to types and block literals?
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D54912/new/
https://reviews.llvm.org/D54912
More information about the llvm-commits
mailing list