mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-30 22:12:15 +00:00
Fix compilation errors.
This commit is contained in:
parent
9c11113b4f
commit
950f569c91
@ -5090,14 +5090,6 @@ dependencies = [
|
|||||||
"serde_json",
|
"serde_json",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "term"
|
|
||||||
version = "0.0.0"
|
|
||||||
dependencies = [
|
|
||||||
"core",
|
|
||||||
"std",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "term"
|
name = "term"
|
||||||
version = "0.6.1"
|
version = "0.6.1"
|
||||||
@ -5150,7 +5142,6 @@ dependencies = [
|
|||||||
"panic_unwind",
|
"panic_unwind",
|
||||||
"proc_macro",
|
"proc_macro",
|
||||||
"std",
|
"std",
|
||||||
"term 0.0.0",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
|
@ -13,7 +13,7 @@ use super::{
|
|||||||
formatters::{JsonFormatter, JunitFormatter, OutputFormatter, PrettyFormatter, TerseFormatter},
|
formatters::{JsonFormatter, JunitFormatter, OutputFormatter, PrettyFormatter, TerseFormatter},
|
||||||
helpers::{concurrency::get_concurrency, metrics::MetricMap},
|
helpers::{concurrency::get_concurrency, metrics::MetricMap},
|
||||||
options::{Options, OutputFormat},
|
options::{Options, OutputFormat},
|
||||||
run_tests,
|
run_tests, term,
|
||||||
test_result::TestResult,
|
test_result::TestResult,
|
||||||
time::{TestExecTime, TestSuiteExecTime},
|
time::{TestExecTime, TestSuiteExecTime},
|
||||||
types::{NamePadding, TestDesc, TestDescAndFn},
|
types::{NamePadding, TestDesc, TestDescAndFn},
|
||||||
|
@ -4,6 +4,7 @@ use super::OutputFormatter;
|
|||||||
use crate::{
|
use crate::{
|
||||||
bench::fmt_bench_samples,
|
bench::fmt_bench_samples,
|
||||||
console::{ConsoleTestState, OutputLocation},
|
console::{ConsoleTestState, OutputLocation},
|
||||||
|
term,
|
||||||
test_result::TestResult,
|
test_result::TestResult,
|
||||||
time,
|
time,
|
||||||
types::TestDesc,
|
types::TestDesc,
|
||||||
|
@ -4,6 +4,7 @@ use super::OutputFormatter;
|
|||||||
use crate::{
|
use crate::{
|
||||||
bench::fmt_bench_samples,
|
bench::fmt_bench_samples,
|
||||||
console::{ConsoleTestState, OutputLocation},
|
console::{ConsoleTestState, OutputLocation},
|
||||||
|
term,
|
||||||
test_result::TestResult,
|
test_result::TestResult,
|
||||||
time,
|
time,
|
||||||
types::NamePadding,
|
types::NamePadding,
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
#![crate_name = "test"]
|
#![crate_name = "test"]
|
||||||
#![unstable(feature = "test", issue = "50297")]
|
#![unstable(feature = "test", issue = "50297")]
|
||||||
#![doc(test(attr(deny(warnings))))]
|
#![doc(test(attr(deny(warnings))))]
|
||||||
#![cfg_attr(unix, feature(libc))]
|
#![feature(libc)]
|
||||||
#![feature(rustc_private)]
|
#![feature(rustc_private)]
|
||||||
#![feature(nll)]
|
#![feature(nll)]
|
||||||
#![feature(available_concurrency)]
|
#![feature(available_concurrency)]
|
||||||
@ -80,6 +80,7 @@ mod formatters;
|
|||||||
mod helpers;
|
mod helpers;
|
||||||
mod options;
|
mod options;
|
||||||
pub mod stats;
|
pub mod stats;
|
||||||
|
mod term;
|
||||||
mod test_result;
|
mod test_result;
|
||||||
mod time;
|
mod time;
|
||||||
mod types;
|
mod types;
|
||||||
|
@ -1,38 +1,18 @@
|
|||||||
//! Terminal formatting library.
|
//! Terminal formatting module.
|
||||||
//!
|
//!
|
||||||
//! This crate provides the `Terminal` trait, which abstracts over an [ANSI
|
//! This module provides the `Terminal` trait, which abstracts over an [ANSI
|
||||||
//! Terminal][ansi] to provide color printing, among other things. There are two
|
//! Terminal][ansi] to provide color printing, among other things. There are two
|
||||||
//! implementations, the `TerminfoTerminal`, which uses control characters from
|
//! implementations, the `TerminfoTerminal`, which uses control characters from
|
||||||
//! a [terminfo][ti] database, and `WinConsole`, which uses the [Win32 Console
|
//! a [terminfo][ti] database, and `WinConsole`, which uses the [Win32 Console
|
||||||
//! API][win].
|
//! API][win].
|
||||||
//!
|
//!
|
||||||
//! # Examples
|
|
||||||
//!
|
|
||||||
//! ```no_run
|
|
||||||
//! # #![feature(rustc_private)]
|
|
||||||
//! extern crate term;
|
|
||||||
//! use std::io::prelude::*;
|
|
||||||
//!
|
|
||||||
//! fn main() {
|
|
||||||
//! let mut t = term::stdout().unwrap();
|
|
||||||
//!
|
|
||||||
//! t.fg(term::color::GREEN).unwrap();
|
|
||||||
//! write!(t, "hello, ").unwrap();
|
|
||||||
//!
|
|
||||||
//! t.fg(term::color::RED).unwrap();
|
|
||||||
//! writeln!(t, "world!").unwrap();
|
|
||||||
//!
|
|
||||||
//! assert!(t.reset().unwrap());
|
|
||||||
//! }
|
|
||||||
//! ```
|
//! ```
|
||||||
//!
|
//!
|
||||||
//! [ansi]: https://en.wikipedia.org/wiki/ANSI_escape_code
|
//! [ansi]: https://en.wikipedia.org/wiki/ANSI_escape_code
|
||||||
//! [win]: https://docs.microsoft.com/en-us/windows/console/character-mode-applications
|
//! [win]: https://docs.microsoft.com/en-us/windows/console/character-mode-applications
|
||||||
//! [ti]: https://en.wikipedia.org/wiki/Terminfo
|
//! [ti]: https://en.wikipedia.org/wiki/Terminfo
|
||||||
|
|
||||||
#![doc(html_playground_url = "https://play.rust-lang.org/", test(attr(deny(warnings))))]
|
|
||||||
#![deny(missing_docs)]
|
#![deny(missing_docs)]
|
||||||
#![cfg_attr(windows, feature(libc))]
|
|
||||||
|
|
||||||
use std::io::prelude::*;
|
use std::io::prelude::*;
|
||||||
use std::io::{self, Stderr, Stdout};
|
use std::io::{self, Stderr, Stdout};
|
@ -8,9 +8,9 @@ use std::fs::File;
|
|||||||
use std::io::{self, prelude::*, BufReader};
|
use std::io::{self, prelude::*, BufReader};
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
|
|
||||||
use crate::color;
|
use super::color;
|
||||||
use crate::Attr;
|
use super::Attr;
|
||||||
use crate::Terminal;
|
use super::Terminal;
|
||||||
|
|
||||||
use parm::{expand, Param, Variables};
|
use parm::{expand, Param, Variables};
|
||||||
use parser::compiled::{msys_terminfo, parse};
|
use parser::compiled::{msys_terminfo, parse};
|
||||||
|
@ -5,9 +5,9 @@
|
|||||||
use std::io;
|
use std::io;
|
||||||
use std::io::prelude::*;
|
use std::io::prelude::*;
|
||||||
|
|
||||||
use crate::color;
|
use super::color;
|
||||||
use crate::Attr;
|
use super::Attr;
|
||||||
use crate::Terminal;
|
use super::Terminal;
|
||||||
|
|
||||||
/// A Terminal implementation that uses the Win32 Console API.
|
/// A Terminal implementation that uses the Win32 Console API.
|
||||||
pub struct WinConsole<T> {
|
pub struct WinConsole<T> {
|
||||||
|
Loading…
Reference in New Issue
Block a user