Skip to content

Commit

Permalink
Checkpoint progress.
Browse files Browse the repository at this point in the history
  • Loading branch information
josh11b committed Jan 2, 2025
1 parent 3909ec3 commit 2a49a77
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
5 changes: 1 addition & 4 deletions toolchain/check/impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,7 @@ static auto CheckAssociatedFunctionImplementation(
// Builds an initial empty witness.
auto ImplWitnessForDeclaration(Context& context, const SemIR::Impl& impl)
-> SemIR::InstId {
// FIXME: CARBON_CHECK(!impl.has_started_definition());
CARBON_CHECK(!impl.is_being_defined());
CARBON_CHECK(!impl.is_defined());
// FIXME
CARBON_CHECK(!impl.has_definition_started());

auto facet_type_id = context.GetTypeIdForTypeInst(impl.constraint_id);
if (facet_type_id == SemIR::ErrorInst::SingletonTypeId) {
Expand Down
12 changes: 8 additions & 4 deletions toolchain/check/import_ref.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1726,12 +1726,16 @@ static auto MakeFunctionDecl(ImportContext& context,
.type_id = SemIR::TypeId::Invalid,
.function_id = SemIR::FunctionId::Invalid,
.decl_block_id = SemIR::InstBlockId::Empty};
#if 0
// FIXME: Better workaround for bug.
auto function_decl_id = context.local_context().AddPlaceholderInstInNoBlock(
// FIXME: Better workaround for bug.
SemIR::LocIdAndInst::NoLoc(
// context.local_context().MakeImportedLocAndInst(
// AddImportIRInst(context, import_function.first_decl_id()),
SemIR::LocIdAndInst::NoLoc(function_decl));
#else
auto function_decl_id = context.local_context().AddPlaceholderInstInNoBlock(
context.local_context().MakeImportedLocAndInst(
AddImportIRInst(context, import_function.first_decl_id()),
function_decl));
#endif

// Start with an incomplete function.
function_decl.function_id = context.local_functions().Add(
Expand Down

0 comments on commit 2a49a77

Please sign in to comment.