mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 13:59:08 +00:00
use get_lambda_set helper
This commit is contained in:
parent
4a1ade65fe
commit
4d681821bf
1 changed files with 6 additions and 11 deletions
|
@ -9543,19 +9543,14 @@ fn find_lambda_sets<'a>(
|
||||||
bumpalo::collections::Vec::with_capacity_in(lambda_set_variables.len(), env.arena);
|
bumpalo::collections::Vec::with_capacity_in(lambda_set_variables.len(), env.arena);
|
||||||
|
|
||||||
for (variable, lambda_set_id) in lambda_set_variables {
|
for (variable, lambda_set_id) in lambda_set_variables {
|
||||||
match env.subs.get_content_without_compacting(variable) {
|
let lambda_set = env.subs.get_lambda_set(variable);
|
||||||
Content::LambdaSet(lambda_set) => {
|
let raw_function_layout = RawFunctionLayout::from_var(env, lambda_set.ambient_function)
|
||||||
let raw_function_layout =
|
|
||||||
RawFunctionLayout::from_var(env, lambda_set.ambient_function)
|
|
||||||
.value()
|
.value()
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
|
||||||
let key = (lambda_set_id, raw_function_layout);
|
let key = (lambda_set_id, raw_function_layout);
|
||||||
answer.push(key);
|
answer.push(key);
|
||||||
}
|
}
|
||||||
_ => unreachable!(),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
answer
|
answer
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue