mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Get rid of AddPatternInst (#7075)
Instead, use the inst category to select the right block stack. This simplifies the API for adding insts, and in subsequent changes it will enable certain inst kinds like `SpliceInst` to seamlessly function as either procedural insts or pattern insts.
This commit is contained in:
@@ -102,7 +102,7 @@ auto HandleParseNode(Context& context, Parse::TuplePatternId node_id) -> bool {
|
||||
auto type_id = GetPatternType(context, GetTupleType(context, type_inst_ids));
|
||||
context.node_stack().Push(
|
||||
node_id,
|
||||
AddPatternInst<SemIR::TuplePattern>(
|
||||
AddInst<SemIR::TuplePattern>(
|
||||
context, node_id, {.type_id = type_id, .elements_id = refs_id}));
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user