Commit Graph

3 Commits

Author SHA1 Message Date
Allan Shortlidge
b4376a9bd3 AST: Filter out some Obj-C overrides when MemberImportVisibility is enabled.
Unlike in Swift, Obj-C allows method overrides to be declared in extensions
(categories), even outside of the module that defines the type that is being
extended. When MemberImportVisibility is enabled, these overrides must be
filtered out to prevent them from hijacking name lookup and causing the
compiler to insist that the module that defines the extension be imported.

Resolves rdar://145329988.
2025-04-24 21:26:34 -07:00
Allan Shortlidge
a020cf8367 Revert "AST: Filter out some Obj-C overrides when MemberImportVisibility is enabled."
This reverts commit 324fa235b0.
2025-04-21 17:08:01 -07:00
Allan Shortlidge
324fa235b0 AST: Filter out some Obj-C overrides when MemberImportVisibility is enabled.
Unlike in Swift, Obj-C allows method overrides to be declared in extensions
(categories), even outside of the module that defines the type that is being
extended. When MemberImportVisibility is enabled, these overrides must be
filtered out to prevent them from hijacking name lookup and causing the
compiler to insist that the module that defines the extension be imported.

Resolves rdar://145329988.
2025-04-06 09:52:58 -07:00