Skip to content

Commit 4db9367

Browse files
committed
Declare const ptr() method as const and remove explcit types in casts
Signed-off-by: Daniel Egger <[email protected]>
1 parent fbaaa28 commit 4db9367

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/generate/peripheral.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ pub fn render(
5454

5555
impl #name_pc {
5656
/// Returns a pointer to the register block
57-
pub fn ptr() -> *const #base::RegisterBlock {
57+
pub const fn ptr() -> *const #base::RegisterBlock {
5858
#address as *const _
5959
}
6060
}

0 commit comments

Comments
 (0)