2019-09-27 20:46:55 -05:00
|
|
|
#![deny(clippy::multiple_inherent_impl)]
|
|
|
|
|
2024-08-24 12:43:34 -05:00
|
|
|
// Test for https://github.com/rust-lang/rust-clippy/issues/4578
|
2019-09-27 20:46:55 -05:00
|
|
|
|
|
|
|
macro_rules! impl_foo {
|
|
|
|
($struct:ident) => {
|
|
|
|
impl $struct {
|
|
|
|
fn foo() {}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
macro_rules! impl_bar {
|
|
|
|
($struct:ident) => {
|
|
|
|
impl $struct {
|
|
|
|
fn bar() {}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
struct MyStruct;
|
|
|
|
|
|
|
|
impl_foo!(MyStruct);
|
|
|
|
impl_bar!(MyStruct);
|
|
|
|
|
|
|
|
fn main() {}
|