blob: 12a458db807e1f84e011a33b28339e22cbb74213 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
error: this function allocates a large amount of stack space
--> $DIR/large_stack_frames.rs:25:1
|
LL | / fn many_small_arrays() {
LL | |
LL | |
LL | | let x = [0u8; 500_000];
... |
LL | | black_box((&x, &x2, &x3, &x4, &x5));
LL | | }
| |_^
|
= note: allocating large amounts of stack space can overflow the stack
= note: `-D clippy::large-stack-frames` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::large_stack_frames)]`
error: this function allocates a large amount of stack space
--> $DIR/large_stack_frames.rs:36:1
|
LL | / fn large_return_value() -> ArrayDefault<1_000_000> {
LL | |
LL | |
LL | | Default::default()
LL | | }
| |_^
|
= note: allocating large amounts of stack space can overflow the stack
error: this function allocates a large amount of stack space
--> $DIR/large_stack_frames.rs:42:1
|
LL | / fn large_fn_arg(x: ArrayDefault<1_000_000>) {
LL | |
LL | |
LL | | black_box(&x);
LL | | }
| |_^
|
= note: allocating large amounts of stack space can overflow the stack
error: aborting due to 3 previous errors
|