Skip to content

Commit 1153f55

Browse files
committed
---
yaml --- r: 78688 b: refs/heads/try c: 320ccbe h: refs/heads/master v: v3
1 parent f6daa20 commit 1153f55

File tree

2 files changed

+21
-1
lines changed

2 files changed

+21
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 25ed29a0edb3d48fef843a0b818ee68faf2252da
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 60fba4d7d677ec098e6a43014132fe99f7547363
5-
refs/heads/try: c0fba3c4acc52dba67461e485a3798cfa236761b
5+
refs/heads/try: 320ccbeb53b711282be6a11623df45c789925059
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/src/libstd/rt/uv/uvio.rs

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1734,3 +1734,23 @@ fn file_test_uvio_full_simple() {
17341734
file_test_uvio_full_simple_impl();
17351735
}
17361736
}
1737+
1738+
fn uvio_naive_print(input: &str) {
1739+
use str::StrSlice;
1740+
unsafe {
1741+
use libc::{STDOUT_FILENO};
1742+
let io = Local::unsafe_borrow::<IoFactoryObject>();
1743+
{
1744+
let mut fd = (*io).fs_from_raw_fd(STDOUT_FILENO, false);
1745+
let write_buf = input.as_bytes();
1746+
fd.write(write_buf);
1747+
}
1748+
}
1749+
}
1750+
1751+
#[test]
1752+
fn file_test_uvio_write_to_stdout() {
1753+
do run_in_newsched_task {
1754+
uvio_naive_print("jubilation\n");
1755+
}
1756+
}

0 commit comments

Comments
 (0)