Fit new rust nightly. Update dependencies.

master
WangRunji 7 years ago
parent 932e2fc290
commit f707d7e757

@ -20,18 +20,17 @@ opt-level = 1
debug = true
[dependencies]
bit_field = "0.7.0"
bit_field = "0.9.0"
rlibc = "1.0"
volatile = "0.1.0"
spin = "0.4.5"
multiboot2 = "0.5"
spin = "0.4.8"
multiboot2 = "0.6"
bitflags = "1.0"
x86_64 = "0.2.3"
x86_64 = "0.2.6"
once = "0.3.3"
linked_list_allocator = "0.5.0"
linked_list_allocator = "0.6"
redox_syscall = "0.1"
xmas-elf = "0.6"
arrayvec = { version = "0.4.7", default-features = false }
log = "0.4"
lazy_static = { version = "1.0.0", features = ["spin_no_std"] }
simple-filesystem = { git = "https://github.com/wangrunji0408/SimpleFileSystem-Rust" }

@ -1,19 +1,27 @@
// Rust language features implementions
use core;
use core::panic::PanicInfo;
use arch::cpu;
#[lang = "eh_personality"]
extern fn eh_personality() {
}
#[lang = "panic_fmt"]
#[panic_implementation]
#[no_mangle]
pub extern fn panic_fmt(fmt: core::fmt::Arguments, file: &'static str, line: u32) -> ! {
error!("\n\nPANIC in {} at line {}\n {}", file, line, fmt);
pub fn panic(info: &PanicInfo) -> ! {
let location = info.location().unwrap();
let message = info.message().unwrap();
error!("\n\nPANIC in {} at line {}\n {}", location.file(), location.line(), message);
if cfg!(feature = "qemu_auto_exit") {
unsafe{ cpu::exit_in_qemu(3) }
} else {
loop { }
}
}
#[lang = "oom"]
#[no_mangle]
fn oom() -> ! {
panic!("out of memory");
}

@ -12,12 +12,13 @@
#![feature(naked_functions)]
#![feature(asm)]
#![feature(optin_builtin_traits)]
#![feature(panic_implementation)]
#![feature(panic_info_message)]
#![no_std]
#[macro_use]
extern crate alloc;
extern crate arrayvec;
extern crate bit_allocator;
extern crate bit_field;
#[macro_use]

Loading…
Cancel
Save