mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-11-23 19:22:43 +00:00
C++ Interop: Fix access calculation to handle private member of base classes correctly (#6238)
Always take into account both the lookup access specifier and the declaration. When set, lookup access specifier takes precedence. When not set, we have two use cases: 1. This is not a record member, so no access is specified at all. Treat this as public. 2. This is a record member of a base class. Treat this as private. [Reference](https://github.com/llvm/llvm-project/blob/4b1d7827c07381610ad4fa7bd9d1a9659008b963/clang/include/clang/AST/DeclCXX.h#L1724). Also, deduplicate access mapping between import and overload resolution. Background: https://github.com/carbon-language/carbon-lang/pull/6221#issuecomment-3407981790 Part of #5859.
This commit is contained in:
1 parent
3d6810beb6
commit
840562feb3
6 files changed
+1924
-151
No files matched your search
+1843
-110
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user