]> git.lizzy.rs Git - rust.git/blobdiff - src/libterm/lib.rs
Auto merge of #67112 - Centril:expr-polish, r=estebank
[rust.git] / src / libterm / lib.rs
index ad1a83316be7c316cc78d8c71d8532595f4f695b..d2e3b07ab855d369f4fa1fdae9ef4e4188cd7532 100644 (file)
 //! ```
 //!
 //! [ansi]: https://en.wikipedia.org/wiki/ANSI_escape_code
-//! [win]: http://msdn.microsoft.com/en-us/library/windows/desktop/ms682010%28v=vs.85%29.aspx
+//! [win]: https://docs.microsoft.com/en-us/windows/console/character-mode-applications
 //! [ti]: https://en.wikipedia.org/wiki/Terminfo
 
-#![doc(html_root_url = "https://doc.rust-lang.org/nightly/",
-       html_playground_url = "https://play.rust-lang.org/",
-       test(attr(deny(warnings))))]
+#![doc(
+    html_root_url = "https://doc.rust-lang.org/nightly/",
+    html_playground_url = "https://play.rust-lang.org/",
+    test(attr(deny(warnings)))
+)]
 #![deny(missing_docs)]
-
 #![cfg_attr(windows, feature(libc))]
 
 use std::io::prelude::*;
-use std::io::{self, Stdout, Stderr};
+use std::io::{self, Stderr, Stdout};
 
 pub use terminfo::TerminfoTerminal;
 #[cfg(windows)]
@@ -86,7 +87,6 @@ pub fn stderr() -> Option<Box<StderrTerminal>> {
         .or_else(|| WinConsole::new(io::stderr()).ok().map(|t| Box::new(t) as Box<StderrTerminal>))
 }
 
-
 /// Terminal color definitions
 #[allow(missing_docs)]
 pub mod color {
@@ -192,5 +192,7 @@ pub trait Terminal: Write {
     fn get_mut(&mut self) -> &mut Self::Output;
 
     /// Returns the contained stream, destroying the `Terminal`
-    fn into_inner(self) -> Self::Output where Self: Sized;
+    fn into_inner(self) -> Self::Output
+    where
+        Self: Sized;
 }