Skip to content

Commit f4f192d

Browse files
TiwalunDirbaio
authored andcommitted
Fix Nordic svd parsing again
1 parent 6d38138 commit f4f192d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

svd-rs/src/access.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,12 @@ impl Default for Access {
4848
impl Access {
4949
/// Parse a string into an [`Access`] value, returning [`Option::None`] if the string is not valid.
5050
pub fn parse_str(s: &str) -> Option<Self> {
51-
match s {
51+
match s.to_lowercase().as_str() {
5252
"read-only" => Some(Self::ReadOnly),
5353
"read-write" => Some(Self::ReadWrite),
54-
"read-writeOnce" => Some(Self::ReadWriteOnce),
54+
"read-writeonce" => Some(Self::ReadWriteOnce),
5555
"write-only" => Some(Self::WriteOnly),
56-
"writeOnce" => Some(Self::WriteOnce),
56+
"writeonce" => Some(Self::WriteOnce),
5757
_ => None,
5858
}
5959
}

0 commit comments

Comments
 (0)