From 097b3a2927076a5f4cfdfca296b87f4e8f5ef4bc Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Mon, 14 Mar 2022 00:24:45 -0700 Subject: [PATCH] Add cast tests that should fail to parse --- tests/test_expr.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/test_expr.rs b/tests/test_expr.rs index 8c1cc73a96..67af006d84 100644 --- a/tests/test_expr.rs +++ b/tests/test_expr.rs @@ -318,3 +318,9 @@ fn test_closure_vs_rangefull() { } "###); } + +#[test] +fn test_postfix_operator_after_cast() { + syn::parse_str::("|| &x as T[0]").unwrap(); // FIXME + syn::parse_str::("|| () as ()()").unwrap(); // FIXME +}