Merge remote-tracking branch 'origin/main' into glue-getters-rtfeldman

This commit is contained in:
Folkert 2023-03-08 19:46:00 +01:00
commit fe15a2e79c
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
124 changed files with 2445 additions and 9925 deletions

View file

@ -2723,3 +2723,48 @@ fn unspecialized_lambda_set_unification_does_not_duplicate_identical_concrete_ty
"#
)
}
#[mono_test]
fn inline_return_joinpoints_in_bool_lambda_set() {
indoc!(
r#"
app "test" provides [f] to "./platform"
f = \x ->
caller = if Bool.false then f else \n -> n
caller (x + 1)
"#
)
}
#[mono_test]
fn inline_return_joinpoints_in_enum_lambda_set() {
indoc!(
r#"
app "test" provides [f] to "./platform"
f = \x ->
caller = \t -> when t is
A -> f
B -> \n -> n
C -> \n -> n + 1
D -> \n -> n + 2
(caller A) (x + 1)
"#
)
}
#[mono_test]
fn inline_return_joinpoints_in_union_lambda_set() {
indoc!(
r#"
app "test" provides [f] to "./platform"
f = \x ->
caller = \t -> when t is
A -> f
B -> \n -> n + x
(caller A) (x + 1)
"#
)
}