Skip to content

Commit 4057c1a

Browse files
committed
---
yaml --- r: 150178 b: refs/heads/try2 c: 6a7fd8c h: refs/heads/master v: v3
1 parent 8fe3e76 commit 4057c1a

File tree

3 files changed

+6
-8
lines changed

3 files changed

+6
-8
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 0dbb909bf7cf557e46748ddcf3cdea916f2734c9
8+
refs/heads/try2: 6a7fd8cfa59506d70c43b93256c7eeeb79133ca5
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/src/librustdoc/clean.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1229,16 +1229,15 @@ fn resolve_type(path: Path, tpbs: Option<Vec<TyParamBound> >,
12291229
core::NotTyped(_) => return Bool
12301230
};
12311231
debug!("searching for {:?} in defmap", id);
1232-
let def_map = tycx.def_map.borrow();
1233-
let d = match def_map.get().find(&id) {
1234-
Some(k) => k,
1232+
let d = match tycx.def_map.borrow().find(&id) {
1233+
Some(&k) => k,
12351234
None => {
12361235
debug!("could not find {:?} in defmap (`{}`)", id, tycx.map.node_to_str(id));
12371236
fail!("Unexpected failure: unresolved id not in defmap (this is a bug!)")
12381237
}
12391238
};
12401239

1241-
let (def_id, kind) = match *d {
1240+
let (def_id, kind) = match d {
12421241
ast::DefFn(i, _) => (i, TypeFunction),
12431242
ast::DefSelfTy(i) => return Self(i),
12441243
ast::DefTy(i) => (i, TypeEnum),
@@ -1285,8 +1284,7 @@ fn resolve_def(id: ast::NodeId) -> Option<ast::DefId> {
12851284
let cx = local_data::get(super::ctxtkey, |x| *x.unwrap());
12861285
match cx.maybe_typed {
12871286
core::Typed(ref tcx) => {
1288-
let def_map = tcx.def_map.borrow();
1289-
def_map.get().find(&id).map(|&d| ast_util::def_id_of_def(d))
1287+
tcx.def_map.borrow().find(&id).map(|&d| ast_util::def_id_of_def(d))
12901288
}
12911289
core::NotTyped(_) => None
12921290
}

branches/try2/src/librustdoc/visit_ast.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ impl<'a> RustdocVisitor<'a> {
186186
core::Typed(ref tcx) => tcx,
187187
core::NotTyped(_) => return false
188188
};
189-
let def = ast_util::def_id_of_def(*tcx.def_map.borrow().get().get(&id));
189+
let def = ast_util::def_id_of_def(*tcx.def_map.borrow().get(&id));
190190
if !ast_util::is_local(def) { return false }
191191
let analysis = match self.analysis {
192192
Some(analysis) => analysis, None => return false

0 commit comments

Comments
 (0)