Fixed Win64 build
This commit is contained in:
parent
6619134d49
commit
f686e5ebff
7 changed files with 105 additions and 44 deletions
|
|
@ -52,20 +52,9 @@ macro_rules! rtabort (
|
|||
|
||||
pub fn dumb_println(args: &fmt::Arguments) {
|
||||
use std::io;
|
||||
use libc;
|
||||
use std::rt;
|
||||
|
||||
struct Stderr;
|
||||
impl io::Writer for Stderr {
|
||||
fn write(&mut self, data: &[u8]) -> io::IoResult<()> {
|
||||
unsafe {
|
||||
libc::write(libc::STDERR_FILENO,
|
||||
data.as_ptr() as *libc::c_void,
|
||||
data.len() as libc::size_t);
|
||||
}
|
||||
Ok(()) // just ignore the result
|
||||
}
|
||||
}
|
||||
let mut w = Stderr;
|
||||
let mut w = rt::Stderr;
|
||||
let _ = fmt::writeln(&mut w as &mut io::Writer, args);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue