Handle recursive calls to capturing function

This commit is contained in:
Ayaz Hafiz 2022-07-03 16:32:33 -04:00
parent d07c273542
commit b868e0e469
No known key found for this signature in database
GPG key ID: 0E2A37416A25EF58
3 changed files with 97 additions and 23 deletions

View file

@ -1682,3 +1682,18 @@ fn choose_u128_layout() {
"#
)
}
#[mono_test]
fn recursive_call_capturing_function() {
indoc!(
r#"
a = \b ->
c : U32 -> U32
c = \d ->
if True then d else c (d+b)
c 0
a 6
"#
)
}