swiftlang / swift-docc

Documentation compiler that produces rich API reference documentation and interactive tutorials for your Swift framework or package.
https://swift.org/documentation/docc
Apache License 2.0
1.17k stars 124 forks source link

Document Objective-C extensions with DocC #843

Open Frizlab opened 7 months ago

Frizlab commented 7 months ago

Feature Name

Document Objective-C Extensions

Description

Implement #210, but this time for Objective-C.

Motivation

I have a project which is basically an extension on NSObject. Without the documentation on extended Objective-C objects, the doc generated by DocC is completely useless for my project.

Importance

I think this feature is relatively important. I am trying a very ugly workaround for the time being, but this would simply not work for a bigger project. Extension-only frameworks are not uncommon and documenting them should, IMHO, be possible, even for Objective-C projects, especially since DocC has official support for Objective-C.

Alternatives Considered

For now I’m trying a workaround with a separate target where a custom object, subclass of NSObject is created and the extension on NSObject are done on this custom object just for the documentation. It’s ugly and absolutely not scalable, and I’m currently not even sure it’ll work.

d-ronnqvist commented 7 months ago

@daniel-grumberg does this issue belong somewhere in the clang repo or here?

daniel-grumberg commented 4 months ago

https://github.com/llvm/llvm-project/issues/92240