mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-03 11:52:19 +00:00
Separate ability members and their specializations in reference checking
This commit is contained in:
parent
7a4c57d3dc
commit
41eb3ad9a4
3 changed files with 1 additions and 10 deletions
|
@ -1568,13 +1568,6 @@ fn canonicalize_var_lookup(
|
|||
output.references.insert_value_lookup(symbol);
|
||||
|
||||
if scope.abilities_store.is_ability_member_name(symbol) {
|
||||
// Is there a shadow implementation with the same name? If so, we might be in
|
||||
// the def for that shadow. In that case add a value lookup of the shadow impl,
|
||||
// so that it's marked as possibly-recursive.
|
||||
if let Some(shadow) = scope.get_member_shadow(symbol) {
|
||||
output.references.insert_value_lookup(shadow.value);
|
||||
}
|
||||
|
||||
AbilityMember(
|
||||
symbol,
|
||||
Some(scope.abilities_store.fresh_specialization_id()),
|
||||
|
|
|
@ -206,7 +206,6 @@ pub fn canonicalize_def_header_pattern<'a>(
|
|||
// Likely a specialization of an ability.
|
||||
Some(ability_member_name) => {
|
||||
output.references.insert_bound(symbol);
|
||||
output.references.insert_value_lookup(ability_member_name);
|
||||
Pattern::AbilityMemberSpecialization {
|
||||
ident: symbol,
|
||||
specializes: ability_member_name,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue