Skip to content

Commit 851a213

Browse files
committed
---
yaml --- r: 274129 b: refs/heads/stable c: 9884ff1 h: refs/heads/master i: 274127: 3f19108
1 parent fee7896 commit 851a213

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: e06d2ad9fcd5027bcaac5b08fc9aa39a49d0ecd3
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: c0221c8897db309a79990367476177b1230bb264
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: d31027d3bf9003f376d7f73df90cb4592d81084a
32+
refs/heads/stable: 9884ff1dfbcb776c909ba575a90736326416fa22
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/src/librustc/mir/repr.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -891,13 +891,20 @@ pub struct Constant<'tcx> {
891891
pub literal: Literal<'tcx>,
892892
}
893893

894-
#[derive(Clone, Debug, RustcEncodable, RustcDecodable)]
894+
#[derive(Clone, RustcEncodable, RustcDecodable)]
895895
pub struct TypedConstVal<'tcx> {
896896
pub ty: Ty<'tcx>,
897897
pub span: Span,
898898
pub value: ConstVal
899899
}
900900

901+
impl<'tcx> Debug for TypedConstVal<'tcx> {
902+
fn fmt(&self, fmt: &mut Formatter) -> fmt::Result {
903+
try!(write!(fmt, "const "));
904+
fmt_const_val(fmt, &self.value)
905+
}
906+
}
907+
901908
#[derive(Clone, Copy, Debug, PartialEq, RustcEncodable, RustcDecodable)]
902909
pub enum ItemKind {
903910
Constant,

branches/stable/src/librustc_mir/transform/erase_regions.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,9 @@ impl<'a, 'tcx> EraseRegions<'a, 'tcx> {
143143
Rvalue::Use(ref mut operand) => {
144144
self.erase_regions_operand(operand)
145145
}
146-
Rvalue::Repeat(ref mut operand, _) => {
146+
Rvalue::Repeat(ref mut operand, ref mut value) => {
147147
self.erase_regions_operand(operand);
148+
value.ty = self.tcx.erase_regions(&value.ty);
148149
}
149150
Rvalue::Ref(ref mut region, _, ref mut lvalue) => {
150151
*region = ty::ReStatic;

0 commit comments

Comments
 (0)