blob: e8290c0098afd80781bae68a67fa906dbaabc0d9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
// Avoid panicking if the Clone trait is not found while building error suggestions
// See #104870
#![feature(no_core, lang_items)]
#![no_core]
#[lang = "sized"]
trait Sized {}
#[lang = "copy"]
trait Copy {}
fn g<T>(x: T) {}
fn f(x: *mut u8) {
g(x);
g(x); //~ ERROR use of moved value: `x`
}
fn main() {}
|