Skip to content

add defmt impls for core::ptr::NonNull and fn(...) -> Ret#753

Merged
bors[bot] merged 3 commits intoknurling-rs:mainfrom
Crzyrndm:ptr-nonnull
May 8, 2023
Merged

add defmt impls for core::ptr::NonNull and fn(...) -> Ret#753
bors[bot] merged 3 commits intoknurling-rs:mainfrom
Crzyrndm:ptr-nonnull

Conversation

@Crzyrndm
Copy link
Copy Markdown
Contributor

@Crzyrndm Crzyrndm commented May 5, 2023

Fixes #752

NonNull and fn pointers formatted like a raw pointer. This matches the behaviour of Debug for these types

Copy link
Copy Markdown
Member

@Urhengulas Urhengulas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution @Crzyrndm.

Note: not quite sure where to add tests for the output?

Please add some log statements just before following line line and run cargo xtask test-snapshot --overwrite from the repository root:

defmt::info!("QEMU test finished!");

Please also add this PR to the CHANGELOG.md.

@Crzyrndm
Copy link
Copy Markdown
Contributor Author

Crzyrndm commented May 6, 2023

Test prints added for NonNull, and fn pointers of 0/1/5 parameters for Rust/C/unsafe (formatting makes 12 a bit much, it's already noisy enough as is and the limit is about as arbitrary as it gets).

@Urhengulas
Copy link
Copy Markdown
Member

Thank you!

bors r+

@bors
Copy link
Copy Markdown
Contributor

bors Bot commented May 8, 2023

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here.
For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.

@bors bors Bot merged commit f6e86bc into knurling-rs:main May 8, 2023
@Crzyrndm Crzyrndm deleted the ptr-nonnull branch May 8, 2023 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

derive support for C-like fn pointers and core::ptr::NonNull

2 participants