mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 12:51:04 +01:00
Reduce special-casing of parameters in ParamOrArgSave. (#3001)
I think this is a simpler and more efficient way of achieving the same end result.
This commit is contained in:
@@ -33,9 +33,8 @@ auto SemanticsHandleStructFieldType(SemanticsContext& context,
|
||||
auto [name_node, name_id] =
|
||||
context.node_stack().PopWithParseNode<ParseNodeKind::Name>();
|
||||
|
||||
context.AddNode(
|
||||
SemanticsNode::StructTypeField::Make(name_node, cast_type_id, name_id));
|
||||
context.node_stack().Push(parse_node);
|
||||
context.AddNodeAndPush(parse_node, SemanticsNode::StructTypeField::Make(
|
||||
name_node, cast_type_id, name_id));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user