]> git.proxmox.com Git - rustc.git/blame - src/test/ui/resolve/issue-65035-static-with-parent-generics.stderr
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / resolve / issue-65035-static-with-parent-generics.stderr
CommitLineData
e74abb32
XL
1error[E0401]: can't use generic parameters from outer function
2 --> $DIR/issue-65035-static-with-parent-generics.rs:6:26
3 |
4LL | fn f<T>() {
5 | - type parameter from outer function
6LL | extern "C" {
7LL | static a: *const T;
8 | ^ use of generic parameter from outer function
9
10error[E0401]: can't use generic parameters from outer function
11 --> $DIR/issue-65035-static-with-parent-generics.rs:12:22
12 |
13LL | fn g<T: Default>() {
14 | - type parameter from outer function
15LL | static a: *const T = Default::default();
16 | ^ use of generic parameter from outer function
17
18error[E0401]: can't use generic parameters from outer function
19 --> $DIR/issue-65035-static-with-parent-generics.rs:18:24
20 |
21LL | fn h<const N: usize>() {
22 | - const parameter from outer function
23LL | extern "C" {
24LL | static a: [u8; N];
25 | ^ use of generic parameter from outer function
26
27error[E0401]: can't use generic parameters from outer function
28 --> $DIR/issue-65035-static-with-parent-generics.rs:24:20
29 |
30LL | fn i<const N: usize>() {
31 | - const parameter from outer function
32LL | static a: [u8; N] = [0; N];
33 | ^ use of generic parameter from outer function
34
35error[E0401]: can't use generic parameters from outer function
36 --> $DIR/issue-65035-static-with-parent-generics.rs:24:29
37 |
38LL | fn i<const N: usize>() {
39 | - const parameter from outer function
40LL | static a: [u8; N] = [0; N];
41 | ^ use of generic parameter from outer function
42
43warning: the feature `const_generics` is incomplete and may cause the compiler to crash
44 --> $DIR/issue-65035-static-with-parent-generics.rs:1:12
45 |
46LL | #![feature(const_generics)]
47 | ^^^^^^^^^^^^^^
48 |
49 = note: `#[warn(incomplete_features)]` on by default
50
ba9703b0 51error: aborting due to 5 previous errors; 1 warning emitted
e74abb32
XL
52
53For more information about this error, try `rustc --explain E0401`.