Skip to content

Commit

Permalink
unsafe write_with_zero
Browse files Browse the repository at this point in the history
  • Loading branch information
burrbull committed Apr 16, 2021
1 parent 26baf2c commit 9a59425
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).

### Changed

- [breaking-change] make `write_with_zero` method `unsafe` because the way it is

- [breaking-change] remove `Variant<U, ENUM_A>`, use `Option<ENUM_A>` instead

- split out register size type (`RawType`) from `ResetValue` trait
Expand Down
2 changes: 1 addition & 1 deletion src/generate/generic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ where
///
/// Similar to `write`, but unused bits will contain 0.
#[inline(always)]
pub fn write_with_zero<F>(&self, f: F)
pub unsafe fn write_with_zero<F>(&self, f: F)
where
F: FnOnce(&mut REG::Writer) -> &mut W<REG>
{
Expand Down

0 comments on commit 9a59425

Please sign in to comment.