Bug 1336646 - Move opts check for statistics into should_dump. r=emilio

This makes things more consistent between the parallel and sequential traversal drivers.
This commit is contained in:
Bobby Holley 2017-02-06 13:31:09 -08:00
parent e7a8f5ec30
commit 37b8d5231d
2 changed files with 3 additions and 3 deletions

View file

@ -15,6 +15,7 @@ use euclid::Size2D;
use matching::StyleSharingCandidateCache;
use parking_lot::RwLock;
use properties::ComputedValues;
use servo_config::opts;
use std::collections::HashMap;
use std::env;
use std::fmt;
@ -160,7 +161,7 @@ lazy_static! {
impl TraversalStatistics {
/// Returns whether statistics dumping is enabled.
pub fn should_dump() -> bool {
*DUMP_STYLE_STATISTICS
*DUMP_STYLE_STATISTICS || opts::get().style_sharing_stats
}
}