Skip to content

Commit 4f40dba

Browse files
committed
Add unsafe block around DEVICE_PERIPHERALS
1 parent 87c2fc4 commit 4f40dba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/generate/device.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ pub fn render(d: &Device, config: &Config, device_x: &mut String) -> Result<Toke
339339
/// Each of the returned peripherals must be used at most once.
340340
#[inline]
341341
pub unsafe fn steal() -> Self {
342-
DEVICE_PERIPHERALS = true;
342+
unsafe { DEVICE_PERIPHERALS = true };
343343

344344
Peripherals {
345345
#exprs

0 commit comments

Comments
 (0)