@@ -4,21 +4,39 @@ error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
44LL | #[global_allocator]
55 | ------------------- in this attribute macro expansion
66LL | static A: usize = 0;
7- | ^^^^^ the trait `GlobalAlloc ` is not implemented for `usize`
7+ | ^^^^^ the nightly-only, unstable trait `GlobalAllocator ` is not implemented for `usize`
88 |
9- help: the trait `GlobalAlloc` is implemented for `System`
10- --> $SRC_DIR/std/src/sys/alloc/unix.rs:LL:COL
9+ help: the following other types implement trait `GlobalAllocator`
10+ --> $SRC_DIR/core/src/alloc/mod.rs:LL:COL
11+ |
12+ = note: `&A`
13+ ::: $SRC_DIR/core/src/alloc/mod.rs:LL:COL
14+ |
15+ = note: `&mut A`
16+ --> $SRC_DIR/std/src/alloc.rs:LL:COL
17+ |
18+ = note: `System`
19+ = note: required for `usize` to implement `GlobalAlloc`
1120
1221error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
1322 --> $DIR/not-an-allocator.rs:5:11
1423 |
1524LL | #[global_allocator]
1625 | ------------------- in this attribute macro expansion
1726LL | static A: usize = 0;
18- | ^^^^^ the trait `GlobalAlloc` is not implemented for `usize`
27+ | ^^^^^ the nightly-only, unstable trait `GlobalAllocator` is not implemented for `usize`
28+ |
29+ help: the following other types implement trait `GlobalAllocator`
30+ --> $SRC_DIR/core/src/alloc/mod.rs:LL:COL
31+ |
32+ = note: `&A`
33+ ::: $SRC_DIR/core/src/alloc/mod.rs:LL:COL
34+ |
35+ = note: `&mut A`
36+ --> $SRC_DIR/std/src/alloc.rs:LL:COL
1937 |
20- help: the trait `GlobalAlloc` is implemented for `System`
21- --> $SRC_DIR/std/src/sys/alloc/unix.rs:LL:COL
38+ = note: `System`
39+ = note: required for `usize` to implement `GlobalAlloc`
2240 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
2341
2442error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
@@ -27,10 +45,19 @@ error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
2745LL | #[global_allocator]
2846 | ------------------- in this attribute macro expansion
2947LL | static A: usize = 0;
30- | ^^^^^ the trait `GlobalAlloc ` is not implemented for `usize`
48+ | ^^^^^ the nightly-only, unstable trait `GlobalAllocator ` is not implemented for `usize`
3149 |
32- help: the trait `GlobalAlloc` is implemented for `System`
33- --> $SRC_DIR/std/src/sys/alloc/unix.rs:LL:COL
50+ help: the following other types implement trait `GlobalAllocator`
51+ --> $SRC_DIR/core/src/alloc/mod.rs:LL:COL
52+ |
53+ = note: `&A`
54+ ::: $SRC_DIR/core/src/alloc/mod.rs:LL:COL
55+ |
56+ = note: `&mut A`
57+ --> $SRC_DIR/std/src/alloc.rs:LL:COL
58+ |
59+ = note: `System`
60+ = note: required for `usize` to implement `GlobalAlloc`
3461 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
3562
3663error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
@@ -39,10 +66,19 @@ error[E0277]: the trait bound `usize: GlobalAlloc` is not satisfied
3966LL | #[global_allocator]
4067 | ------------------- in this attribute macro expansion
4168LL | static A: usize = 0;
42- | ^^^^^ the trait `GlobalAlloc` is not implemented for `usize`
69+ | ^^^^^ the nightly-only, unstable trait `GlobalAllocator` is not implemented for `usize`
70+ |
71+ help: the following other types implement trait `GlobalAllocator`
72+ --> $SRC_DIR/core/src/alloc/mod.rs:LL:COL
73+ |
74+ = note: `&A`
75+ ::: $SRC_DIR/core/src/alloc/mod.rs:LL:COL
76+ |
77+ = note: `&mut A`
78+ --> $SRC_DIR/std/src/alloc.rs:LL:COL
4379 |
44- help: the trait `GlobalAlloc` is implemented for `System`
45- --> $SRC_DIR/std/src/sys/alloc/unix.rs:LL:COL
80+ = note: `System`
81+ = note: required for `usize` to implement `GlobalAlloc`
4682 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
4783
4884error: aborting due to 4 previous errors
0 commit comments