Commit Graph

3 Commits

Author SHA1 Message Date
Becca Royal-Gordon
6e9d386d9e Fix indexing crasher with implicit objcImpl inits
Implicit initializers are given a source location within the type they belong to. This works poorly for @objc @implementation classes, because the class they belong to is imported and so those SourceLocs are in a different source buffer from the extension they’re inside, breaking an invariant enforced by index-while-building features.

Fix these SourceLocs to come from the implementation context, so they’ll come from the extension for an objcImpl class and the type itself otherwise.
2025-02-07 13:22:43 -08:00
Becca Royal-Gordon
6d3e1ad794 Fix -target in several objcImpl tests 2024-04-30 12:03:46 -07:00
Ben Barham
1808a398f1 [Index] Use access level to check decls to include
`isAccessibleFrom` has special handling for `@_objcImplementation`
members, which causes the definition in Swift to be missed. Use access
level directly rather than passing `nullptr` into `isAccessibleFrom`.
2023-02-06 15:59:54 -08:00