Skip to content

Commit a09b1f1

Browse files
committed
---
yaml --- r: 14847 b: refs/heads/try c: 0cd72d2 h: refs/heads/master i: 14845: 5a7de30 14843: 0080504 14839: 7f8a50e 14831: 2012b5e 14815: adb5c0a 14783: 5ff19c0 14719: 6a5b057 14591: b754f0a 14335: 4cc2ad4 v: v3
1 parent 6da7140 commit a09b1f1

File tree

4 files changed

+7
-3
lines changed

4 files changed

+7
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5-
refs/heads/try: 45d0b5f0b9bbcf97bc985fd26d64564273b7547a
5+
refs/heads/try: 0cd72d24dcf39376a4c4f74520ae614d9fb90058
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105

branches/try/src/rustc/middle/trans/base.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1849,6 +1849,10 @@ fn autoderef(cx: block, v: ValueRef, t: ty::t) -> result_t {
18491849
t1 = derefed.t;
18501850
v1 = derefed.v;
18511851
}
1852+
ty::ty_rptr(_, mt) {
1853+
t1 = mt.ty;
1854+
v1 = v;
1855+
}
18521856
ty::ty_res(did, inner, tps) {
18531857
t1 = ty::substitute_type_params(ccx.tcx, tps, inner);
18541858
v1 = GEPi(cx, v1, [0, 1]);

branches/try/src/rustc/middle/ty.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1119,7 +1119,7 @@ fn type_autoderef(cx: ctxt, t: t) -> t {
11191119
let t1 = t;
11201120
loop {
11211121
alt get(t1).struct {
1122-
ty_box(mt) | ty_uniq(mt) { t1 = mt.ty; }
1122+
ty_box(mt) | ty_uniq(mt) | ty::ty_rptr(_, mt) { t1 = mt.ty; }
11231123
ty_res(_, inner, tps) {
11241124
t1 = substitute_type_params(cx, tps, inner);
11251125
}

branches/try/src/rustc/middle/typeck.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1058,7 +1058,7 @@ fn do_autoderef(fcx: @fn_ctxt, sp: span, t: ty::t) -> ty::t {
10581058
let t1 = t;
10591059
loop {
10601060
alt structure_of(fcx, sp, t1) {
1061-
ty::ty_box(inner) | ty::ty_uniq(inner) {
1061+
ty::ty_box(inner) | ty::ty_uniq(inner) | ty::ty_rptr(_, inner) {
10621062
alt ty::get(t1).struct {
10631063
ty::ty_var(v1) {
10641064
ty::occurs_check(fcx.ccx.tcx, sp, v1,

0 commit comments

Comments
 (0)