blob: 6dbc8d39976ad431af8c04b661558a4298e82a13 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
pub fn main() {
let x = "Hello " + "World!";
//~^ ERROR cannot be applied to type
// Make sure that the span outputs a warning
// for not having an implementation for std::ops::Add
// that won't output for the above string concatenation
let y = World::Hello + World::Goodbye;
//~^ ERROR cannot be applied to type
let x = "Hello " + "World!".to_owned();
//~^ ERROR cannot be applied to type
}
enum World {
Hello,
Goodbye,
}
|