Merge pull request #3193 from taaki2311/main
Reduced the definition for 'unreachable!' to a single macro rule
This commit is contained in:
commit
5236df97c6
23 changed files with 138 additions and 230 deletions
cyw43/src
embassy-boot-nrf/src
embassy-boot-rp/src
embassy-boot-stm32/src
embassy-boot/src
embassy-executor/src
embassy-futures/src
embassy-hal-internal/src
embassy-net-adin1110/src
embassy-net-driver-channel/src
embassy-net-enc28j60/src
embassy-net-esp-hosted/src
embassy-net-ppp/src
embassy-net/src
embassy-nrf/src
embassy-rp/src
embassy-stm32-wpan/src
embassy-stm32/src
embassy-sync/src
embassy-time/src
embassy-usb-dfu/src
embassy-usb-synopsys-otg/src
embassy-usb/src
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,19 +90,15 @@ macro_rules! todo {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "defmt"))]
|
|
||||||
#[collapse_debuginfo(yes)]
|
#[collapse_debuginfo(yes)]
|
||||||
macro_rules! unreachable {
|
macro_rules! unreachable {
|
||||||
($($x:tt)*) => {
|
($($x:tt)*) => {
|
||||||
::core::unreachable!($($x)*)
|
{
|
||||||
};
|
#[cfg(not(feature = "defmt"))]
|
||||||
}
|
::core::unreachable!($($x)*);
|
||||||
|
#[cfg(feature = "defmt")]
|
||||||
#[cfg(feature = "defmt")]
|
::defmt::unreachable!($($x)*);
|
||||||
#[collapse_debuginfo(yes)]
|
}
|
||||||
macro_rules! unreachable {
|
|
||||||
($($x:tt)*) => {
|
|
||||||
::defmt::unreachable!($($x)*)
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue