Skip to content

Commit 08c8d07

Browse files
bors[bot]Brandon Matthews
andcommitted
Merge #238
238: Remove debug assert from Peripherals::steal r=therealprof a=thenewwazoo Very simple PR! :) This permits actually-unsafe use of the steal method, and avoids divergent behavior between debug and release modes. Co-authored-by: Brandon Matthews <[email protected]>
2 parents 2f237d0 + efd3d93 commit 08c8d07

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/generate/device.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,8 +211,6 @@ pub fn render(
211211

212212
/// Unchecked version of `Peripherals::take`
213213
pub unsafe fn steal() -> Self {
214-
debug_assert!(!DEVICE_PERIPHERALS);
215-
216214
DEVICE_PERIPHERALS = true;
217215

218216
Peripherals {

0 commit comments

Comments
 (0)