Skip to content

Commit d385f05

Browse files
committed
Allow unsafe code, but deny undocumented blocks
1 parent a99ec40 commit d385f05

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@
9090
#![deny(
9191
anonymous_parameters,
9292
clippy::all,
93+
clippy::undocumented_unsafe_blocks,
9394
const_err,
9495
illegal_floating_point_literal_pattern,
9596
late_bound_lifetime_arguments,
@@ -99,7 +100,6 @@
99100
trivial_casts,
100101
trivial_numeric_casts,
101102
unreachable_pub,
102-
unsafe_code,
103103
unsafe_op_in_unsafe_fn,
104104
unused_extern_crates
105105
)]

src/parsing/parsed.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,6 @@ macro_rules! getters {
288288
None
289289
} else {
290290
// SAFETY: We just checked if the field is present.
291-
#[allow(unsafe_code)]
292291
Some(unsafe { self.$name.assume_init() })
293292
}
294293
}
@@ -330,7 +329,6 @@ impl Parsed {
330329
None
331330
} else {
332331
// SAFETY: We just checked if the field is present.
333-
#[allow(unsafe_code)]
334332
Some(unsafe { self.offset_minute.assume_init() })
335333
}
336334
}
@@ -347,7 +345,6 @@ impl Parsed {
347345
None
348346
} else {
349347
// SAFETY: We just checked if the field is present.
350-
#[allow(unsafe_code)]
351348
Some(unsafe { self.offset_second.assume_init() })
352349
}
353350
}

0 commit comments

Comments
 (0)