Skip to content

Commit

Permalink
Merge pull request #897 from robamu/field-writer-lifetime-ellision
Browse files Browse the repository at this point in the history
lifetime ellision for FieldWriter to fix clippy warning
  • Loading branch information
burrbull authored Jan 14, 2025
2 parents 0e2aa42 + 2ad6e0c commit 07406a8
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
## [Unreleased]

- Force using rust edition 2021 in CI
- Added lifetime ellision for `FieldWriter` where the explicit lifetimes are not necessary, which
fixes the `clippy::needless_lifetimes` warning on rustc 1.84

## [v0.35.0] - 2024-11-12

Expand Down
2 changes: 1 addition & 1 deletion ci/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ main() {
test_patched_stm32 stm32f103
test_patched_stm32 stm32f411
test_patched_stm32 stm32f469
test_patched_stm32 stm32f7x3
test_patched_stm32 stm32f723
test_patched_stm32 stm32g070
test_patched_stm32 stm32g473
test_patched_stm32 stm32h743
Expand Down
4 changes: 2 additions & 2 deletions ci/svd2rust-regress/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1863,8 +1863,8 @@
svd_url: https://stm32-rs.github.io/stm32-rs/stm32f469.svd.patched
- arch: cortex-m
mfgr: STMicro
chip: STM32F7x3
svd_url: https://stm32-rs.github.io/stm32-rs/stm32f7x3.svd.patched
chip: STM32F723
svd_url: https://stm32-rs.github.io/stm32-rs/stm32f723.svd.patched
- arch: cortex-m
mfgr: STMicro
chip: STM32G070
Expand Down
2 changes: 1 addition & 1 deletion src/generate/generic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ pub struct RangeTo<const MAX: u64>;
/// Write field Proxy
pub type FieldWriter<'a, REG, const WI: u8, FI = u8, Safety = Unsafe> = raw::FieldWriter<'a, REG, WI, FI, Safety>;

impl<'a, REG, const WI: u8, FI, Safety> FieldWriter<'a, REG, WI, FI, Safety>
impl<REG, const WI: u8, FI, Safety> FieldWriter<'_, REG, WI, FI, Safety>
where
REG: Writable + RegisterSpec,
FI: FieldSpec,
Expand Down

0 comments on commit 07406a8

Please sign in to comment.