Skip to content

Commit

Permalink
compiletest: Derive Default for EarlyProps
Browse files Browse the repository at this point in the history
  • Loading branch information
tmiasko committed Jan 27, 2020
1 parent 9a154a9 commit db7ee95
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/tools/compiletest/src/header.rs
Expand Up @@ -24,6 +24,7 @@ enum ParsedNameDirective {

/// Properties which must be known very early, before actually running
/// the test.
#[derive(Default)]
pub struct EarlyProps {
pub ignore: bool,
pub should_fail: bool,
Expand All @@ -39,14 +40,7 @@ impl EarlyProps {
}

pub fn from_reader<R: Read>(config: &Config, testfile: &Path, rdr: R) -> Self {
let mut props = EarlyProps {
ignore: false,
should_fail: false,
aux: Vec::new(),
aux_crate: Vec::new(),
revisions: vec![],
};

let mut props = EarlyProps::default();
let rustc_has_profiler_support = env::var_os("RUSTC_PROFILER_SUPPORT").is_some();
let rustc_has_sanitizer_support = env::var_os("RUSTC_SANITIZER_SUPPORT").is_some();

Expand Down

0 comments on commit db7ee95

Please sign in to comment.