defmt
defmt::println!("{:?}", 1 as *const u8);
output:
1
└─ hello::__cortex_m_rt_main @ src/bin/hello.rs:8
core::fmt
println!("{:?}", 1 as *const u8);
output:
defmt should also include the 0x prefix.
The current format makes it hard to tell that the number is a hexadecimal value. For example,
defmt::trace!(256 as *const u8);
produces:
TRACE 256 as * const u8 = 100
100 looks like one-hundred
defmtoutput:
core::fmtoutput:
0x1defmtshould also include the0xprefix.The current format makes it hard to tell that the number is a hexadecimal value. For example,
produces:
TRACE 256 as * const u8 = 100100looks like one-hundred