]> git.proxmox.com Git - rustc.git/blame - tests/ui/resolve/use_suggestion_placement.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / resolve / use_suggestion_placement.rs
CommitLineData
136023e0
XL
1// run-rustfix
2#![allow(dead_code)]
3
3b2f2976
XL
4macro_rules! y {
5 () => {}
6}
7
8mod m {
9 pub const A: i32 = 0;
10}
54a0048b 11
3b2f2976 12mod foo {
5e7ed085 13 #[derive(Debug)]
3b2f2976
XL
14 pub struct Foo;
15
16 // test whether the use suggestion isn't
17 // placed into the expansion of `#[derive(Debug)]
ff7c6d11 18 type Bar = Path; //~ ERROR cannot find
a7813a04 19}
7453a54e 20
a7813a04 21fn main() {
3b2f2976 22 y!();
ff7c6d11 23 let _ = A; //~ ERROR cannot find
3b2f2976
XL
24 foo();
25}
26
27fn foo() {
ff7c6d11 28 type Dict<K, V> = HashMap<K, V>; //~ ERROR cannot find
223e47cc 29}