forked from M-Labs/artiq-zynq
fix warnings
This commit is contained in:
parent
ee03879620
commit
15f9d1a9e5
|
@ -1,7 +1,7 @@
|
|||
#![no_std]
|
||||
#![feature(never_type)]
|
||||
#![feature(naked_functions)]
|
||||
#![feature(asm)]
|
||||
#![allow(unexpected_cfgs)]
|
||||
|
||||
extern crate crc;
|
||||
extern crate embedded_hal;
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
#![allow(unexpected_cfgs)]
|
||||
|
||||
use std::{env,
|
||||
fs::File,
|
||||
io::{BufRead, BufReader, Write},
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#![no_std]
|
||||
#![feature(never_type)]
|
||||
#![allow(unexpected_cfgs)]
|
||||
|
||||
#[cfg(feature = "alloc")]
|
||||
extern crate alloc;
|
||||
|
|
|
@ -15,9 +15,9 @@
|
|||
// By design, this personality function is only ever called in the search phase, although
|
||||
// to keep things simple and close to upstream, it is not modified
|
||||
use unwind as uw;
|
||||
use libc::{c_int, uintptr_t};
|
||||
use libc::c_int;
|
||||
|
||||
use dwarf::eh::{self, EHAction, EHContext};
|
||||
use dwarf::eh::{EHAction, EHContext};
|
||||
|
||||
// Register ids were lifted from LLVM's TargetLowering::getExceptionPointerRegister()
|
||||
// and TargetLowering::getExceptionSelectorRegister() for each architecture,
|
||||
|
|
|
@ -2,9 +2,8 @@
|
|||
#![feature(c_variadic)]
|
||||
#![feature(const_btree_len)]
|
||||
#![feature(lang_items)]
|
||||
#![feature(generic_const_exprs)]
|
||||
#![feature(naked_functions)]
|
||||
#![feature(asm)]
|
||||
#![allow(unexpected_cfgs)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate alloc;
|
||||
|
|
|
@ -57,7 +57,6 @@ where
|
|||
let ptr = storage as *mut u32;
|
||||
let dest = core::slice::from_raw_parts_mut(ptr as *mut u8, length * 4);
|
||||
reader.read_exact(dest)?;
|
||||
drop(dest);
|
||||
let dest = core::slice::from_raw_parts_mut(ptr, length);
|
||||
NativeEndian::from_slice_u32(dest);
|
||||
}
|
||||
|
@ -65,7 +64,6 @@ where
|
|||
let ptr = storage as *mut u64;
|
||||
let dest = core::slice::from_raw_parts_mut(ptr as *mut u8, length * 8);
|
||||
reader.read_exact(dest)?;
|
||||
drop(dest);
|
||||
let dest = core::slice::from_raw_parts_mut(ptr, length);
|
||||
NativeEndian::from_slice_u64(dest);
|
||||
}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
#![allow(unexpected_cfgs)]
|
||||
extern crate build_zynq;
|
||||
|
||||
fn main() {
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
#![no_std]
|
||||
#![no_main]
|
||||
#![recursion_limit = "1024"] // for futures_util::select!
|
||||
#![allow(unexpected_cfgs)]
|
||||
#![feature(alloc_error_handler)]
|
||||
#![feature(const_btree_new)]
|
||||
#![feature(panic_info_message)]
|
||||
#![feature(const_btree_len)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate alloc;
|
||||
|
|
|
@ -38,7 +38,6 @@ where
|
|||
let ptr = storage as *mut u32;
|
||||
let dest = core::slice::from_raw_parts_mut(ptr as *mut u8, length * 4);
|
||||
proto_async::read_chunk(stream, dest).await?;
|
||||
drop(dest);
|
||||
let dest = core::slice::from_raw_parts_mut(ptr, length);
|
||||
NativeEndian::from_slice_u32(dest);
|
||||
}
|
||||
|
@ -46,7 +45,6 @@ where
|
|||
let ptr = storage as *mut u64;
|
||||
let dest = core::slice::from_raw_parts_mut(ptr as *mut u8, length * 8);
|
||||
proto_async::read_chunk(stream, dest).await?;
|
||||
drop(dest);
|
||||
let dest = core::slice::from_raw_parts_mut(ptr, length);
|
||||
NativeEndian::from_slice_u64(dest);
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#![no_std]
|
||||
#![no_main]
|
||||
#![feature(alloc_error_handler, never_type)]
|
||||
#![allow(unexpected_cfgs)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate log;
|
||||
|
@ -1457,7 +1458,7 @@ pub fn panic_fmt(info: &core::panic::PanicInfo) -> ! {
|
|||
} else {
|
||||
print!("unknown location");
|
||||
}
|
||||
if let Some(message) = info.message() {
|
||||
if let Some(message) = info.message().as_str() {
|
||||
println!(": {}", message);
|
||||
} else {
|
||||
println!("");
|
||||
|
|
Loading…
Reference in New Issue