Parse destructured tag annotations as annotations rather than aliases

Closes #178
This commit is contained in:
ayazhafiz 2021-12-26 15:39:36 -06:00
parent fe62e59e31
commit b3ddfa7515
8 changed files with 192 additions and 34 deletions

View file

@ -2981,20 +2981,20 @@ mod solve_expr {
);
}
// #[test]
// fn let_tag_pattern_with_annotation() {
// infer_eq_without_problem(
// indoc!(
// r#"
// UserId x : [ UserId I64 ]
// UserId x = UserId 42
#[test]
fn let_tag_pattern_with_annotation() {
infer_eq_without_problem(
indoc!(
r#"
UserId x : [ UserId I64 ]
UserId x = UserId 42
// x
// "#
// ),
// "I64",
// );
// }
x
"#
),
"I64",
);
}
#[test]
fn typecheck_record_linked_list_map() {