mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Preserve the is_final bit when importing an impl declaration (#5461)
We were importing all impls as non-final, since we forgot to set the new field when constructing the imported Impl. Adds a test that fails before this PR, since the imported Impl is treated as non-final.
This commit is contained in:
@@ -2126,7 +2126,8 @@ static auto MakeImplDeclaration(ImportContext& context,
|
||||
{.self_id = SemIR::TypeInstId::None,
|
||||
.constraint_id = SemIR::TypeInstId::None,
|
||||
.interface = SemIR::SpecificInterface::None,
|
||||
.witness_id = witness_id}});
|
||||
.witness_id = witness_id,
|
||||
.is_final = import_impl.is_final}});
|
||||
|
||||
// Write the impl ID into the ImplDecl.
|
||||
auto impl_const_id =
|
||||
|
||||
Reference in New Issue
Block a user