Reduce warnings

This commit is contained in:
Jeremy Soller
2019-01-14 19:26:18 -07:00
parent b3dda7519d
commit c57ac53d28
2 changed files with 6 additions and 0 deletions
+4
View File
@@ -77,13 +77,17 @@ macro_rules! trace_expr {
trace!("{}", format_args!($($arg)*));
#[allow(unused_unsafe)]
let old_errno = unsafe { platform::errno };
#[allow(unused_unsafe)]
unsafe { platform::errno = 0; }
let ret = $expr;
#[allow(unused_unsafe)]
let errno = unsafe { platform::errno } as isize;
if errno == 0 {
#[allow(unused_unsafe)]
unsafe { platform::errno = old_errno; }
}
+2
View File
@@ -1,3 +1,5 @@
#![allow(non_snake_case)]
use alloc::boxed::Box;
use alloc::collections::BTreeMap;
use core::{intrinsics, ptr};