Skip to content

Commit

Permalink
Address comments by reviewers.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelwoerister committed Aug 9, 2016
1 parent 71fe770 commit 26fd699
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions src/librustc/session/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -258,13 +258,11 @@ top_level_options!(
lint_cap: Option<lint::Level> [TRACKED],
describe_lints: bool [UNTRACKED],
output_types: OutputTypes [TRACKED],
// FIXME(mw): I'm not entirely sure if this can have any influence on
// incremental compilation apart from what is already handled
// by crate metadata hashes. Better track it.
// FIXME(mw): We track this for now but it actually doesn't make too
// much sense: The search path can stay the same while the
// things discovered there might have changed on disk.
search_paths: SearchPaths [TRACKED],
// FIXME(mw): Might not need to do dep-tracking for `libs`?
libs: Vec<(String, cstore::NativeLibraryKind)> [TRACKED],
// FIXME(mw): Might not need to do dep-tracking for `maybe_sysroot`?
maybe_sysroot: Option<PathBuf> [TRACKED],

target_triple: String [TRACKED],
Expand All @@ -280,8 +278,9 @@ top_level_options!(
debugging_opts: DebuggingOptions [TRACKED],
prints: Vec<PrintRequest> [UNTRACKED],
cg: CodegenOptions [TRACKED],
// FIXME(mw): `externs` might not need to be tracked but let's err on
// the side of caution for now.
// FIXME(mw): We track this for now but it actually doesn't make too
// much sense: The value of this option can stay the same
// while the files they refer to might have changed on disk.
externs: Externs [TRACKED],
crate_name: Option<String> [TRACKED],
// An optional name to use as the crate for std during std injection,
Expand Down Expand Up @@ -1692,11 +1691,12 @@ mod dep_tracking {
($t:ty) => (
impl DepTrackingHash for Vec<$t> {
fn hash(&self, hasher: &mut SipHasher, error_format: ErrorOutputType) {
let mut elems = self.clone();
let mut elems: Vec<&$t> = self.iter().collect();
elems.sort();
for (i, e) in elems.iter().enumerate() {
Hash::hash(&i, hasher);
DepTrackingHash::hash(e, hasher, error_format);
Hash::hash(&elems.len(), hasher);
for (index, elem) in elems.iter().enumerate() {
Hash::hash(&index, hasher);
DepTrackingHash::hash(*elem, hasher, error_format);
}
}
}
Expand Down

0 comments on commit 26fd699

Please sign in to comment.