Skip to content

Commit

Permalink
skip reserved registers/clusters
Browse files Browse the repository at this point in the history
  • Loading branch information
burrbull committed Feb 15, 2024
1 parent d571f5c commit c28977f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/generate/peripheral.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,8 @@ pub fn render(p_original: &Peripheral, index: &Index, config: &Config) -> Result
// erc: *E*ither *R*egister or *C*luster
let mut ercs = p.registers.take().unwrap_or_default();

ercs.retain(|rc| rc.name() != "_reserved");

// No `struct RegisterBlock` can be generated
if ercs.is_empty() {
// Drop the definition of the peripheral
Expand Down

0 comments on commit c28977f

Please sign in to comment.