mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Give the .Self instruction a location (#7147)
This lets us stop eliding it in textual semir tests with dump ranges. Previously it would always get elided, even though it was part of the range being dumped, and was referred to by other instructions in the dump range. Since each `.Self` is unique (can change its type if not its value) in a facet type, having each one distinct by location also aids understanding.
This commit is contained in:
@@ -69,7 +69,7 @@ auto HandleParseNode(Context& context, Parse::WhereOperandId node_id) -> bool {
|
||||
context.scope_stack().PushForSameRegion();
|
||||
// Introduce `.Self` as a symbolic binding. Its type is the value of the
|
||||
// expression to the left of `where`, so `MyInterface` in the example above.
|
||||
MakePeriodSelfFacetValue(context, period_self_type_id);
|
||||
MakePeriodSelfFacetValue(context, node_id, period_self_type_id);
|
||||
|
||||
// Going to put each requirement on `args_type_info_stack`, so we can have an
|
||||
// inst block with the varying number of requirements but keeping other
|
||||
|
||||
Reference in New Issue
Block a user