X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Flibrustc_passes%2Fhir_stats.rs;h=604b31e7167a971dd6b13fe7b10e1860c0c70fa5;hb=f2b92174e3c25e54156efcbdc105a48d50afb6be;hp=b65a2e3f0e5306f3033f71269c2e0db136a5c07c;hpb=70073ec61d0d56bca45b9bd40659bb75799cd273;p=rust.git diff --git a/src/librustc_passes/hir_stats.rs b/src/librustc_passes/hir_stats.rs index b65a2e3f0e5..604b31e7167 100644 --- a/src/librustc_passes/hir_stats.rs +++ b/src/librustc_passes/hir_stats.rs @@ -1,13 +1,3 @@ -// Copyright 2016 The Rust Project Developers. See the COPYRIGHT -// file at the top-level directory of this distribution and at -// http://rust-lang.org/COPYRIGHT. -// -// Licensed under the Apache License, Version 2.0 or the MIT license -// , at your -// option. This file may not be copied, modified, or distributed -// except according to those terms. - // The visitors in this module collect sizes and counts of the most important // pieces of AST and HIR. The resulting numbers are good approximations but not // completely accurate (some things might be counted twice, others missed). @@ -41,8 +31,8 @@ struct StatCollector<'k> { pub fn print_hir_stats(krate: &hir::Crate) { let mut collector = StatCollector { krate: Some(krate), - data: FxHashMap(), - seen: FxHashSet(), + data: FxHashMap::default(), + seen: FxHashSet::default(), }; hir_visit::walk_crate(&mut collector, krate); collector.print("HIR STATS"); @@ -51,8 +41,8 @@ pub fn print_hir_stats(krate: &hir::Crate) { pub fn print_ast_stats<'v>(krate: &'v ast::Crate, title: &str) { let mut collector = StatCollector { krate: None, - data: FxHashMap(), - seen: FxHashSet(), + data: FxHashMap::default(), + seen: FxHashSet::default(), }; ast_visit::walk_crate(&mut collector, krate); collector.print(title);