Skip to content

Commit

Permalink
Fix impl Gpio -> impl GpioConfig`
Browse files Browse the repository at this point in the history
In the two sections "Peripherals as State Machines" and "Design
Contracts" of the "Static Guarantees" chapter, `impl Gpio` was
incorrectly used in place of `impl GpioConfig` at one place in each
section.

This commit fixes that.
  • Loading branch information
andebjor committed Dec 7, 2019
1 parent 5ca585c commit 5e19398
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/static-guarantees/design-contracts.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ struct GpioConfig {
periph: GPIO_CONFIG,
}
impl Gpio {
impl GpioConfig {
pub fn set_enable(&mut self, is_enabled: bool) {
self.periph.modify(|_r, w| {
w.enable().set_bit(is_enabled)
Expand Down
2 changes: 1 addition & 1 deletion src/static-guarantees/state-machines.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ struct GpioConfig {
periph: GPIO_CONFIG,
}
impl Gpio {
impl GpioConfig {
pub fn set_enable(&mut self, is_enabled: bool) {
self.periph.modify(|_r, w| {
w.enable().set_bit(is_enabled)
Expand Down

0 comments on commit 5e19398

Please sign in to comment.