I have a mixed language framework (note: not a Swift package) that contains Swift, Objective-C, Objective-C++ and C++. Right now I'm building documentation with Jazzy, but I'm interested in migrating to DocC for simplified tooling. All the public types are either in Swift or Objective-C.
If I build documentation with Xcode, I get a documentation package that only contains documentation for Objective-C types and for Swift types that are both public and @objc. Also it looks like _documentation(visibility:) has no effect on them: whatever I specify as the visibility, they show up in the generated documentation.
I can reproduce this behavior with a fresh framework project. A new framework project that contains Swift types that are public, internal or private, @objc and not @objc, with and without _documentation(visibility: private) gives me a documentation package that only contains @objc public types, regardless of their documentation visibility level.
This is with both Xcode 15.0 and with Xcode 15.1 beta. Is there anything I do to force Xcode to build docs for the Swift only code too, and to respect the documentation visibility settings?