mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Refactor name addition, particularly for associated entities. (#3924)
This is so that the constant associated with a function is used after the function declaration is complete, related to changing how function constants work.
This commit is contained in:
@@ -435,7 +435,7 @@ auto HandleBaseDecl(Context& context, Parse::BaseDeclId node_id) -> bool {
|
||||
SemIR::StructTypeField{SemIR::NameId::Base, base_info.type_id}}));
|
||||
|
||||
// Bind the name `base` in the class to the base field.
|
||||
context.decl_name_stack().AddNameToLookup(
|
||||
context.decl_name_stack().AddNameOrDiagnoseDuplicate(
|
||||
context.decl_name_stack().MakeUnqualifiedName(node_id,
|
||||
SemIR::NameId::Base),
|
||||
class_info.base_id);
|
||||
|
||||
Reference in New Issue
Block a user