Merge branch 'main' into fromutf-roc

This commit is contained in:
shua 2025-01-20 19:16:38 +01:00
commit 6c29d7aa1f
No known key found for this signature in database
237 changed files with 7237 additions and 5353 deletions

View file

@ -2510,13 +2510,15 @@ mod solve_expr {
infer_eq_without_problem(
indoc!(
r"
empty : [Cons a (ConsList a), Nil] as ConsList a
empty = Nil
ConsList a : [Cons a (ConsList a), Nil]
empty
"
empty : ConsList _
empty = Nil
empty
"
),
"ConsList a",
"ConsList *",
);
}
@ -3742,7 +3744,7 @@ mod solve_expr {
indoc!(
r"
\rec ->
{ x, y } : { x : I64, y ? Bool }*
{ x, y } : { x : I64, y ? Bool }_
{ x, y ? Bool.false } = rec
{ x, y }
@ -3824,6 +3826,18 @@ mod solve_expr {
);
}
#[test]
fn str_with_ascii_lowercased() {
infer_eq_without_problem(
indoc!(
r"
Str.with_ascii_lowercased
"
),
"Str -> Str",
);
}
#[test]
fn list_take_first() {
infer_eq_without_problem(
@ -3909,26 +3923,6 @@ mod solve_expr {
);
}
#[test]
fn double_named_rigids() {
infer_eq_without_problem(
indoc!(
r#"
app "test" provides [main] to "./platform"
main : List x
main =
empty : List x
empty = []
empty
"#
),
"List x",
);
}
#[test]
fn double_tag_application() {
infer_eq_without_problem(