Skip to content

Commit b9a9240

Browse files
committed
---
yaml --- r: 163655 b: refs/heads/snap-stage3 c: 89922e5 h: refs/heads/master i: 163653: 84cd2a7 163651: d2a8038 163647: adaac22 v: v3
1 parent 68f5c01 commit b9a9240

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
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: 1085012cd2f587bed0eb64a547d03d671d3a5c6f
4+
refs/heads/snap-stage3: 89922e52b06fbe1af74983cf2f936c5bf9e6d91e
55
refs/heads/try: 20cbbffeefc1f35e2ea63afce7b42fbd79611d42
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d

branches/snap-stage3/src/librustc/middle/ty.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1368,12 +1368,13 @@ impl<'tcx> PolyTraitRef<'tcx> {
13681368
}
13691369
}
13701370

1371-
/// Binder serves as a synthetic binder for lifetimes. It is used when
1372-
/// we wish to replace the escaping higher-ranked lifetimes in a type
1373-
/// or something else that is not itself a binder (this is because the
1374-
/// `replace_late_bound_regions` function replaces all lifetimes bound
1375-
/// by the binder supplied to it; but a type is not a binder, so you
1376-
/// must introduce an artificial one).
1371+
/// Binder is a binder for higher-ranked lifetimes. It is part of the
1372+
/// compiler's representation for things like `for<'a> Fn(&'a int)`
1373+
/// (which would be represented by the type `PolyTraitRef ==
1374+
/// Binder<TraitRef>`). Note that when we skolemize, instantiate,
1375+
/// erase, or otherwise "discharge" these bound reons, we change the
1376+
/// type from `Binder<T>` to just `T` (see
1377+
/// e.g. `liberate_late_bound_regions`).
13771378
#[deriving(Clone, PartialEq, Eq, Hash, Show)]
13781379
pub struct Binder<T>(pub T);
13791380

0 commit comments

Comments
 (0)