Support constant InstActions (#7671)

Treat `InstConstantKind::InstAction` the same as
`InstConstantKind::ConstInstAction`. Drop `ConstInstAction`, since the
two now behave the same.

Fix eval for specifics in a couple places to handle `InstId::None`.
This commit is contained in:
Nicholas Bishop
2026-08-24 18:05:15 +00:00
committed by GitHub
parent 369b8fd06f
commit 7f3584a123
17 changed files with 451 additions and 172 deletions
+1 -3
View File
@@ -46,9 +46,7 @@ static auto FinishInst(Context& context, SemIR::InstId inst_id,
// Template-dependent instructions are handled separately by
// `AddDependentActionInst`.
CARBON_CHECK(
inst.kind().constant_kind() !=
SemIR::InstConstantKind::ConstantInstAction &&
inst.kind().constant_kind() != SemIR::InstConstantKind::InstAction,
inst.kind().constant_kind() != SemIR::InstConstantKind::InstAction,
"Use AddDependentActionInst to add an action instruction");
// Keep track of dependent instructions.