2024-03-16 21:03:36 +03:00
|
|
|
#![feature(fn_delegation)]
|
2024-03-26 18:59:03 +03:00
|
|
|
#![allow(incomplete_features)]
|
2024-03-16 21:03:36 +03:00
|
|
|
|
|
|
|
trait Trait {
|
|
|
|
fn foo(&self) -> u32 { 0 }
|
|
|
|
}
|
|
|
|
|
|
|
|
struct F;
|
|
|
|
struct S;
|
|
|
|
|
|
|
|
mod to_reuse {
|
|
|
|
use crate::S;
|
|
|
|
|
|
|
|
pub fn foo(_: &S) -> u32 { 0 }
|
|
|
|
}
|
|
|
|
|
|
|
|
impl Trait for S {
|
|
|
|
reuse to_reuse::foo { self }
|
|
|
|
reuse Trait::foo;
|
|
|
|
//~^ ERROR duplicate definitions with name `foo`
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|