1 error: unsafe block missing a safety comment
2 --> $DIR/undocumented_unsafe_blocks.rs:215:5
7 = note: `-D clippy::undocumented-unsafe-blocks` implied by `-D warnings`
8 help: consider adding a safety comment
14 error: unsafe block missing a safety comment
15 --> $DIR/undocumented_unsafe_blocks.rs:219:5
17 LL | let _ = [unsafe { 14 }, unsafe { 15 }, 42, unsafe { 16 }];
18 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20 help: consider adding a safety comment
23 LL + let _ = [unsafe { 14 }, unsafe { 15 }, 42, unsafe { 16 }];
26 error: unsafe block missing a safety comment
27 --> $DIR/undocumented_unsafe_blocks.rs:223:5
29 LL | let _ = (42, unsafe {}, "test", unsafe {});
30 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
32 help: consider adding a safety comment
35 LL + let _ = (42, unsafe {}, "test", unsafe {});
38 error: unsafe block missing a safety comment
39 --> $DIR/undocumented_unsafe_blocks.rs:227:5
41 LL | let _ = *unsafe { &42 };
42 | ^^^^^^^^^^^^^^^^^^^^^^^^
44 help: consider adding a safety comment
47 LL + let _ = *unsafe { &42 };
50 error: unsafe block missing a safety comment
51 --> $DIR/undocumented_unsafe_blocks.rs:232:5
53 LL | let _ = match unsafe {} {
54 | ^^^^^^^^^^^^^^^^^^^^^^^^^
56 help: consider adding a safety comment
59 LL + let _ = match unsafe {} {
62 error: unsafe block missing a safety comment
63 --> $DIR/undocumented_unsafe_blocks.rs:238:5
65 LL | let _ = &unsafe {};
68 help: consider adding a safety comment
71 LL + let _ = &unsafe {};
74 error: unsafe block missing a safety comment
75 --> $DIR/undocumented_unsafe_blocks.rs:242:5
77 LL | let _ = [unsafe {}; 5];
78 | ^^^^^^^^^^^^^^^^^^^^^^^
80 help: consider adding a safety comment
83 LL + let _ = [unsafe {}; 5];
86 error: unsafe block missing a safety comment
87 --> $DIR/undocumented_unsafe_blocks.rs:246:5
89 LL | let _ = unsafe {};
92 help: consider adding a safety comment
95 LL + let _ = unsafe {};
98 error: unsafe block missing a safety comment
99 --> $DIR/undocumented_unsafe_blocks.rs:256:8
104 help: consider adding a safety comment
106 LL ~ t!(// Safety: ...
110 error: unsafe block in macro expansion missing a safety comment
111 --> $DIR/undocumented_unsafe_blocks.rs:262:13
117 | ---- in this macro invocation
119 = help: consider adding a safety comment in the macro definition
120 = note: this error originates in the macro `t` (in Nightly builds, run with -Z macro-backtrace for more info)
122 error: unsafe block missing a safety comment
123 --> $DIR/undocumented_unsafe_blocks.rs:270:5
125 LL | unsafe {} // Safety:
128 help: consider adding a safety comment
131 LL ~ unsafe {} // Safety:
134 error: unsafe block missing a safety comment
135 --> $DIR/undocumented_unsafe_blocks.rs:274:5
140 help: consider adding a safety comment
146 error: unsafe block missing a safety comment
147 --> $DIR/undocumented_unsafe_blocks.rs:284:5
152 help: consider adding a safety comment
158 error: unsafe block missing a safety comment
159 --> $DIR/undocumented_unsafe_blocks.rs:288:20
161 LL | println!("{}", unsafe { String::from_utf8_unchecked(vec![]) });
162 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
164 help: consider adding a safety comment
166 LL ~ println!("{}", // Safety: ...
167 LL ~ unsafe { String::from_utf8_unchecked(vec![]) });
170 error: aborting due to 14 previous errors