Skip to content

Commit c60a6b9

Browse files
committed
Remove superfluous rets (purely style)
1 parent 74d60a6 commit c60a6b9

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/libcore/io.rs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -371,10 +371,8 @@ impl of writer for *libc::FILE {
371371
fn flush() -> int { libc::fflush(self) as int }
372372
fn get_type() -> writer_type {
373373
let fd = libc::fileno(self);
374-
if libc::isatty(fd) == 0 {
375-
ret file;
376-
}
377-
ret screen;
374+
if libc::isatty(fd) == 0 { file }
375+
else { screen }
378376
}
379377
}
380378

@@ -661,7 +659,7 @@ impl of writer for mem_buffer {
661659
}
662660
fn tell() -> uint { self.pos }
663661
fn flush() -> int { 0 }
664-
fn get_type() -> writer_type { ret file }
662+
fn get_type() -> writer_type { file }
665663
}
666664
667665
fn mem_buffer() -> mem_buffer {

0 commit comments

Comments
 (0)