We need to support attributes on Objective-C categories to allow the use of external_source_symbol attributes for categories. We don't want to use the external_source_symbol attributes from the interfaces for categories because they might come from a different Swift module.
I would have assumed the use in the @implementation would have been enough to trigger it, is that not the behavior we'd want?
If not, can you extend the test to show that a use of the category triggers the deprecation warning?
I'm not sure. Typically an implementation of a category is located in a framework, so even if it's deprecated for the users of a framework, you wouldn't really want to get a warning about it when compiling that framework. That said there's is a non-default -Wdeprecated-implementation warning for class implementations, so I think it would make sense to use it for category implementations as well. I will add make sure that the warning is emitted when committing the patch.
Well, deprecated category only shows "Implementing deprecated category" message.
However, I would like to tell users that all methods of this category are deprecated.
For that I need to add deprecated attribute for each method in this category.