File tree Expand file tree Collapse file tree 4 files changed +8
-10
lines changed Expand file tree Collapse file tree 4 files changed +8
-10
lines changed Original file line number Diff line number Diff line change 8484 - { rust: stable, vendor: Toshiba, options: all }
8585 - { rust: stable, vendor: Toshiba, options: "" }
8686 # Test MSRV
87- - { rust: 1.74 .0, vendor: Nordic, options: "" }
87+ - { rust: 1.76 .0, vendor: Nordic, options: "" }
8888 # Use nightly for architectures which don't support stable
8989 - { rust: nightly, vendor: MSP430, options: "--atomics" }
9090 - { rust: nightly, vendor: MSP430, options: "" }
Original file line number Diff line number Diff line change @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
77
88## [ Unreleased]
99
10+ - Bump MSRV of generated code to 1.76
11+
1012## [ v0.33.3] - 2024-05-10
1113
1214- Yet more clean field & register ` Debug `
@@ -891,11 +893,7 @@ peripheral.register.write(|w| w.field().set());
891893
892894- Initial version of the ` svd2rust ` tool
893895
894- [ Unreleased ] : https://github.com/rust-embedded/svd2rust/compare/v0.33.3...HEAD
895- [ v0.33.3 ] : https://github.com/rust-embedded/svd2rust/compare/v0.33.2...v0.33.3
896- [ v0.33.2 ] : https://github.com/rust-embedded/svd2rust/compare/v0.33.1...v0.33.2
897- [ v0.33.1 ] : https://github.com/rust-embedded/svd2rust/compare/v0.33.0...v0.33.1
898- [ v0.33.0 ] : https://github.com/rust-embedded/svd2rust/compare/v0.32.0...v0.33.0
896+ [ Unreleased ] : https://github.com/rust-embedded/svd2rust/compare/v0.32.0...HEAD
899897[ v0.32.0 ] : https://github.com/rust-embedded/svd2rust/compare/v0.31.5...v0.32.0
900898[ v0.31.5 ] : https://github.com/rust-embedded/svd2rust/compare/v0.31.4...v0.31.5
901899[ v0.31.4 ] : https://github.com/rust-embedded/svd2rust/compare/v0.31.3...v0.31.4
Original file line number Diff line number Diff line change @@ -17,9 +17,9 @@ This project is developed and maintained by the [Tools team][team].
1717
1818## Minimum Supported Rust Version (MSRV)
1919
20- The ** generated code** is guaranteed to compile on stable Rust 1.65 .0 and up.
20+ The ** generated code** is guaranteed to compile on stable Rust 1.76 .0 and up.
2121
22- If you encounter compilation errors on any stable version newer than 1.65 .0, please open an issue.
22+ If you encounter compilation errors on any stable version newer than 1.76 .0, please open an issue.
2323
2424# Testing Locally
2525
Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ impl ToTokens for RawRegAccessor {
118118 #[ doc = #doc]
119119 #[ inline( always) ]
120120 pub const fn #name( & self ) -> & #ty {
121- unsafe { & * ( self as * const Self ) . cast:: <u8 >( ) . add( #offset) . cast( ) }
121+ unsafe { & * core :: ptr :: from_ref ( self ) . cast:: <u8 >( ) . add( #offset) . cast( ) }
122122 }
123123 }
124124 . to_tokens ( tokens) ;
@@ -177,7 +177,7 @@ impl ToTokens for RawArrayAccessor {
177177 increment,
178178 } = self ;
179179 let name_iter = Ident :: new ( & format ! ( "{name}_iter" ) , Span :: call_site ( ) ) ;
180- let cast = quote ! { unsafe { & * ( self as * const Self ) . cast:: <u8 >( ) . add( #offset) . add( #increment * n) . cast( ) } } ;
180+ let cast = quote ! { unsafe { & * core :: ptr :: from_ref ( self ) . cast:: <u8 >( ) . add( #offset) . add( #increment * n) . cast( ) } } ;
181181 quote ! {
182182 #[ doc = #doc]
183183 #[ inline( always) ]
You can’t perform that action at this time.
0 commit comments