Skip to content

Commit 14ff40e

Browse files
committed
---
yaml --- r: 163355 b: refs/heads/snap-stage3 c: d8e51ea h: refs/heads/master i: 163353: 0d66051 163351: 15ce5d6 v: v3
1 parent 9c69505 commit 14ff40e

File tree

3 files changed

+28
-4
lines changed

3 files changed

+28
-4
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 9146a919b616e39e528e4d7100d16eef52f1f852
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: d258d68db6ae5ad81e4b8b4f5fcc1e4d89624f97
4+
refs/heads/snap-stage3: d8e51ea0e2e0c7d363a4202c0ae395f320a19f3d
55
refs/heads/try: 20cbbffeefc1f35e2ea63afce7b42fbd79611d42
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d

branches/snap-stage3/src/librustdoc/clean/mod.rs

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1165,12 +1165,19 @@ pub enum Type {
11651165
mutability: Mutability,
11661166
type_: Box<Type>,
11671167
},
1168+
1169+
// <Type as Trait>::Name
11681170
QPath {
11691171
name: String,
11701172
self_type: Box<Type>,
11711173
trait_: Box<Type>
11721174
},
1173-
// region, raw, other boxes, mutable
1175+
1176+
// _
1177+
Infer,
1178+
1179+
// for<'a> Foo(&'a)
1180+
PolyTraitRef(Vec<TyParamBound>),
11741181
}
11751182

11761183
#[deriving(Clone, Encodable, Decodable, PartialEq, Eq, Hash)]
@@ -1307,11 +1314,18 @@ impl Clean<Type> for ast::Ty {
13071314
}
13081315
}
13091316
TyClosure(ref c) => Closure(box c.clean(cx)),
1310-
TyProc(ref c) => Proc(box c.clean(cx)),
13111317
TyBareFn(ref barefn) => BareFunction(box barefn.clean(cx)),
13121318
TyParen(ref ty) => ty.clean(cx),
13131319
TyQPath(ref qp) => qp.clean(cx),
1314-
ref x => panic!("Unimplemented type {}", x),
1320+
TyPolyTraitRef(ref bounds) => {
1321+
PolyTraitRef(bounds.clean(cx))
1322+
},
1323+
TyInfer(..) => {
1324+
Infer
1325+
},
1326+
TyTypeof(..) => {
1327+
panic!("Unimplemented type {}", self.node)
1328+
},
13151329
}
13161330
}
13171331
}

branches/snap-stage3/src/librustdoc/html/format.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -390,6 +390,16 @@ impl fmt::Show for clean::Type {
390390
try!(resolved_path(f, did, path, false));
391391
tybounds(f, typarams)
392392
}
393+
clean::PolyTraitRef(ref bounds) => {
394+
for (i, bound) in bounds.iter().enumerate() {
395+
if i != 0 {
396+
try!(write!(f, " + "));
397+
}
398+
try!(write!(f, "{}", *bound));
399+
}
400+
Ok(())
401+
}
402+
clean::Infer => write!(f, "_"),
393403
clean::Self(..) => f.write("Self".as_bytes()),
394404
clean::Primitive(prim) => primitive_link(f, prim, prim.to_string()),
395405
clean::Closure(ref decl) => {

0 commit comments

Comments
 (0)