From 8008870bc150b4ba5719ae84dea04c437ffc67f8 Mon Sep 17 00:00:00 2001 From: atse Date: Fri, 12 Jan 2024 17:26:40 +0800 Subject: [PATCH] Switch panic_handler to panic_halt Move away from panic_abort as it uses intrinsics, which is nightly only. --- Cargo.lock | 8 ++++---- Cargo.toml | 2 +- src/main.rs | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b27f15f..877ce74 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -327,10 +327,10 @@ dependencies = [ ] [[package]] -name = "panic-abort" -version = "0.3.2" +name = "panic-halt" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e20e6499bbbc412f280b04a42346b356c6fa0753d5fd22b7bd752ff34c778ee" +checksum = "de96540e0ebde571dc55c73d60ef407c653844e6f9a1e2fdbd40c07b9252d812" [[package]] name = "panic-semihosting" @@ -563,7 +563,7 @@ dependencies = [ "nb 1.0.0", "nom", "num-traits", - "panic-abort", + "panic-halt", "panic-semihosting", "serde", "serde-json-core", diff --git a/Cargo.toml b/Cargo.toml index 0a95263..b001d49 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,7 +14,7 @@ features = [] default-target = "thumbv7em-none-eabihf" [dependencies] -panic-abort = "0.3" +panic-halt = "0.2" panic-semihosting = { version = "0.5", optional = true } log = "0.4" bare-metal = "1" diff --git a/src/main.rs b/src/main.rs index 4d6fd05..7271a32 100644 --- a/src/main.rs +++ b/src/main.rs @@ -5,7 +5,7 @@ // TODO: #![deny(warnings, unused)] #[cfg(not(any(feature = "semihosting", test)))] -use panic_abort as _; +use panic_halt as _; #[cfg(all(feature = "semihosting", not(test)))] use panic_semihosting as _;