Add test to reproduce Ok and Err alias failure

This commit is contained in:
Richard Feldman 2024-04-25 19:48:56 -04:00
parent 87feeb5135
commit e4bc7147c9
No known key found for this signature in database
GPG key ID: F1F21AA5B1D9E43B

View file

@ -1200,6 +1200,22 @@ fn tag_with_type_behind_alias() {
);
}
#[test]
fn aliases_named_err_and_ok() {
expect_success(
indoc!(
r#"
Err : [Blah]
Ok : [Stuff]
v : (Err, Ok)
v = (Blah, Stuff)
v"#
),
r#"(Blah, Stuff) : ( [Blah], [Stuff] )*"#,
);
}
#[cfg(not(feature = "wasm"))]
#[test]
fn issue_2588_record_with_function_and_nonfunction() {