mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-13 05:38:46 +00:00
Add regression test
This commit is contained in:
parent
0d49da5e18
commit
7f76a73a38
1 changed files with 21 additions and 0 deletions
|
@ -1177,3 +1177,24 @@ fn multiexp_inner() {
|
|||
"#,
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn macro_expands_to_impl_trait() {
|
||||
check_no_mismatches(
|
||||
r#"
|
||||
trait Foo {}
|
||||
|
||||
macro_rules! ty {
|
||||
() => {
|
||||
impl Foo
|
||||
}
|
||||
}
|
||||
|
||||
fn foo(_: ty!()) {}
|
||||
|
||||
fn bar() {
|
||||
foo(());
|
||||
}
|
||||
"#,
|
||||
)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue