Skip to content

Commit 6250005

Browse files
committed
---
yaml --- r: 11727 b: refs/heads/master c: 2975bcd h: refs/heads/master i: 11725: 0050d4e 11723: 746a8b8 11719: 072567f 11711: 348c8dc v: v3
1 parent 95b7b79 commit 6250005

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 92ed73d0bd0a5d0871658c379a3f547d08f42b95
2+
refs/heads/master: 2975bcdd7d9ee0772f1d0a106898eca26fa0a5c4
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
55
refs/heads/try: 2898dcc5d97da9427ac367542382b6239d9c0bbf

trunk/src/rustc/util/ppaux.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,13 @@ fn ty_to_str(cx: ctxt, typ: t) -> str {
6868
base
6969
}
7070
}
71+
fn region_to_str(_cx: ctxt, r: region) -> str {
72+
alt r {
73+
re_named(_) { "<name>." } // TODO: include name
74+
re_caller(_) { "<caller>." }
75+
re_block(_) { "<block>." } // TODO: include line number
76+
}
77+
}
7178

7279
// if there is an id, print that instead of the structural type:
7380
alt ty::type_def_id(typ) {
@@ -101,6 +108,7 @@ fn ty_to_str(cx: ctxt, typ: t) -> str {
101108
ty_box(tm) { "@" + mt_to_str(cx, tm) }
102109
ty_uniq(tm) { "~" + mt_to_str(cx, tm) }
103110
ty_ptr(tm) { "*" + mt_to_str(cx, tm) }
111+
ty_rptr(r, tm) { "&" + region_to_str(cx, r) + mt_to_str(cx, tm) }
104112
ty_vec(tm) { "[" + mt_to_str(cx, tm) + "]" }
105113
ty_type { "type" }
106114
ty_rec(elems) {

0 commit comments

Comments
 (0)