summaryrefslogtreecommitdiffstats
path: root/src/test/ui/numbers-arithmetic/issue-8460-const.opt.stderr
blob: e2eee1ccdc98cf753eb72dec0614620ac7d056e6 (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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:13:36
   |
LL |     assert!(thread::spawn(move|| { isize::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^^^ attempt to compute `isize::MIN / -1_isize`, which would overflow
   |
   = note: `#[deny(unconditional_panic)]` on by default

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:15:36
   |
LL |     assert!(thread::spawn(move|| { i8::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^ attempt to compute `i8::MIN / -1_i8`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:17:36
   |
LL |     assert!(thread::spawn(move|| { i16::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute `i16::MIN / -1_i16`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:19:36
   |
LL |     assert!(thread::spawn(move|| { i32::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute `i32::MIN / -1_i32`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:21:36
   |
LL |     assert!(thread::spawn(move|| { i64::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute `i64::MIN / -1_i64`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:23:36
   |
LL |     assert!(thread::spawn(move|| { i128::MIN / -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^^ attempt to compute `i128::MIN / -1_i128`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:25:36
   |
LL |     assert!(thread::spawn(move|| { 1isize / 0; }).join().is_err());
   |                                    ^^^^^^^^^^ attempt to divide `1_isize` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:27:36
   |
LL |     assert!(thread::spawn(move|| { 1i8 / 0; }).join().is_err());
   |                                    ^^^^^^^ attempt to divide `1_i8` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:29:36
   |
LL |     assert!(thread::spawn(move|| { 1i16 / 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to divide `1_i16` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:31:36
   |
LL |     assert!(thread::spawn(move|| { 1i32 / 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to divide `1_i32` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:33:36
   |
LL |     assert!(thread::spawn(move|| { 1i64 / 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to divide `1_i64` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:35:36
   |
LL |     assert!(thread::spawn(move|| { 1i128 / 0; }).join().is_err());
   |                                    ^^^^^^^^^ attempt to divide `1_i128` by zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:37:36
   |
LL |     assert!(thread::spawn(move|| { isize::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^^^ attempt to compute the remainder of `isize::MIN % -1_isize`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:39:36
   |
LL |     assert!(thread::spawn(move|| { i8::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^ attempt to compute the remainder of `i8::MIN % -1_i8`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:41:36
   |
LL |     assert!(thread::spawn(move|| { i16::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute the remainder of `i16::MIN % -1_i16`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:43:36
   |
LL |     assert!(thread::spawn(move|| { i32::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute the remainder of `i32::MIN % -1_i32`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:45:36
   |
LL |     assert!(thread::spawn(move|| { i64::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^ attempt to compute the remainder of `i64::MIN % -1_i64`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:47:36
   |
LL |     assert!(thread::spawn(move|| { i128::MIN % -1; }).join().is_err());
   |                                    ^^^^^^^^^^^^^^ attempt to compute the remainder of `i128::MIN % -1_i128`, which would overflow

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:49:36
   |
LL |     assert!(thread::spawn(move|| { 1isize % 0; }).join().is_err());
   |                                    ^^^^^^^^^^ attempt to calculate the remainder of `1_isize` with a divisor of zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:51:36
   |
LL |     assert!(thread::spawn(move|| { 1i8 % 0; }).join().is_err());
   |                                    ^^^^^^^ attempt to calculate the remainder of `1_i8` with a divisor of zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:53:36
   |
LL |     assert!(thread::spawn(move|| { 1i16 % 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to calculate the remainder of `1_i16` with a divisor of zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:55:36
   |
LL |     assert!(thread::spawn(move|| { 1i32 % 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to calculate the remainder of `1_i32` with a divisor of zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:57:36
   |
LL |     assert!(thread::spawn(move|| { 1i64 % 0; }).join().is_err());
   |                                    ^^^^^^^^ attempt to calculate the remainder of `1_i64` with a divisor of zero

error: this operation will panic at runtime
  --> $DIR/issue-8460-const.rs:59:36
   |
LL |     assert!(thread::spawn(move|| { 1i128 % 0; }).join().is_err());
   |                                    ^^^^^^^^^ attempt to calculate the remainder of `1_i128` with a divisor of zero

error: aborting due to 24 previous errors