mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-30 06:43:20 +03:00
xous: fix unwinding and unused symbol errors
The unwinding feature is called `panic-unwind` and not `panic_unwind`. Adjust the feature gate to look for these values. Additionally, the `abort_internal()` call is no longer used. Signed-off-by: Sean Cross <sean@xobs.io>
This commit is contained in:
@@ -1,14 +1,8 @@
|
||||
#![forbid(unsafe_op_in_unsafe_fn)]
|
||||
|
||||
use crate::os::xous::ffi::exit;
|
||||
|
||||
pub mod os;
|
||||
pub mod time;
|
||||
|
||||
#[path = "../unsupported/common.rs"]
|
||||
mod common;
|
||||
pub use common::*;
|
||||
|
||||
pub fn abort_internal() -> ! {
|
||||
exit(101);
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
static PARAMS_ADDRESS: Atomic<*mut u8> = AtomicPtr::new(core::ptr::null_mut());
|
||||
|
||||
#[cfg(not(test))]
|
||||
#[cfg(feature = "panic_unwind")]
|
||||
#[cfg(feature = "panic-unwind")]
|
||||
mod eh_unwinding {
|
||||
pub(crate) struct EhFrameFinder;
|
||||
pub(crate) static mut EH_FRAME_ADDRESS: usize = 0;
|
||||
@@ -45,7 +45,7 @@ pub extern "C" fn abort() {
|
||||
|
||||
#[unsafe(no_mangle)]
|
||||
pub extern "C" fn _start(eh_frame: usize, params_address: usize) {
|
||||
#[cfg(feature = "panic_unwind")]
|
||||
#[cfg(feature = "panic-unwind")]
|
||||
{
|
||||
unsafe { super::eh_unwinding::EH_FRAME_ADDRESS = eh_frame };
|
||||
unwind::set_custom_eh_frame_finder(&super::eh_unwinding::EH_FRAME_SETTINGS).ok();
|
||||
|
||||
Reference in New Issue
Block a user