Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Objective-C では、NS_DEPRECATED、NS_RETURNS_NOT_RETAINED などの異なる属性でメソッドをマークできます。
複数の属性を持つメソッドをマークすることは可能ですか?
もちろん。それらをすべて一列に並べるだけです。
- (id)foo NS_RETURNS_NOT_RETAINED NS_DEPRECATED(...);
(NS_DEPRECATED は実際に使用するためのものではないことに注意してください。これは、OS リビジョンでの可用性を示すことを意図して、iOS または Mac バージョン範囲のパラメーターを取ります。)