Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/mbe/src/tests/expand.rs')
-rw-r--r--crates/mbe/src/tests/expand.rs54
1 files changed, 0 insertions, 54 deletions
diff --git a/crates/mbe/src/tests/expand.rs b/crates/mbe/src/tests/expand.rs
index 15a7184029..52a218ed11 100644
--- a/crates/mbe/src/tests/expand.rs
+++ b/crates/mbe/src/tests/expand.rs
@@ -102,60 +102,6 @@ fn test_attr_to_token_tree() {
}
#[test]
-fn test_underscore() {
- parse_macro(
- r#"
- macro_rules! foo {
- ($_:tt) => { 0 }
- }
- "#,
- )
- .assert_expand_items(r#"foo! { => }"#, r#"0"#);
-}
-
-#[test]
-fn test_underscore_not_greedily() {
- parse_macro(
- r#"
-macro_rules! q {
- ($($a:ident)* _) => {0};
-}
-"#,
- )
- // `_` overlaps with `$a:ident` but rustc matches it under the `_` token
- .assert_expand_items(r#"q![a b c d _]"#, r#"0"#);
-
- parse_macro(
- r#"
-macro_rules! q {
- ($($a:expr => $b:ident)* _ => $c:expr) => {0};
-}
-"#,
- )
- // `_ => ou` overlaps with `$a:expr => $b:ident` but rustc matches it under `_ => $c:expr`
- .assert_expand_items(r#"q![a => b c => d _ => ou]"#, r#"0"#);
-}
-
-#[test]
-fn test_underscore_as_type() {
- parse_macro(
- r#"
-macro_rules! q {
- ($a:ty) => {0};
-}
-"#,
- )
- // Underscore is a type
- .assert_expand_items(r#"q![_]"#, r#"0"#);
-}
-
-#[test]
-fn test_underscore_lifetime() {
- parse_macro(r#"macro_rules! q { ($a:lifetime) => {0}; }"#)
- .assert_expand_items(r#"q!['_]"#, r#"0"#);
-}
-
-#[test]
fn test_vertical_bar_with_pat() {
parse_macro(
r#"