<div dir="ltr">Hi all,<div><br></div><div>I'm trying to extract all attributes from an ObjCPropertyDecl such as:</div><div><br></div><div>```</div><div>@property (strong, nonatomic) NSMutableDictionary* fieldsToBePosted;<br></div><div>```</div><div><br></div><div>So I refered to the clang docs and found the function `clang::ObjCPropertyDecl::getPropertyAttributes()`, which looks like what I need. Then I wrote a piece of code like this:</div><div><br></div><div>```</div><div>clang::ObjCPropertyDecl::PropertyAttributeKind kind = decl->getPropertyAttributes();<br></div><div>cout << kind << endl;</div><div>```</div><div><br></div><div>What surprised me is that I got 64 (0x40), which is OBJC_PR_nonatomic. What I expected is OBJC_PR_nonatomic | OBJC_PR_strong <i>a.k.a.</i> 1088(0x440).</div><div><br></div><div>Also, as I tried to dump the decl, it looks like this:</div><div><br></div><div>```</div><div><div>ObjCPropertyDecl 0x7fc9ac66c640 </Users/wzpan/Documents/workspace/HelloWorld/HelloWorldViewController.m:14:1, col:52> col:52 fieldsToBePosted 'NSMutableDictionary *' nonatomic</div></div><div>```<br></div><div><br></div><div>Where has the `strong` attributes gone? Can anyone please tell me how to get all the attributes? Thanks.</div><div><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><span style="font-family:Arial,Helvetica,sans-serif,SimSun;font-size:14px;line-height:22px"><pre style="margin:0px;padding:0px;white-space:pre-wrap">Yours respectfully,</pre><pre style="margin:0px;padding:0px;white-space:pre-wrap">潘伟洲(Weizhou Pan)</pre><pre style="margin:0px;padding:0px;white-space:pre-wrap"><a href="http://hahack.com" target="_blank">hahack.com</a></pre></span></div></div>
</div></div>