Skip to content

Commit 902c6a0

Browse files
committed
---
yaml --- r: 3320 b: refs/heads/master c: 14c31c2 h: refs/heads/master v: v3
1 parent fd9c989 commit 902c6a0

File tree

2 files changed

+20
-5
lines changed

2 files changed

+20
-5
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: f3798fd2134ce3b47d69e452dfe9aa926b66e859
2+
refs/heads/master: 14c31c26c29cba36b336898f1c760e2b61c74d4c

trunk/src/comp/pretty/pprust.rs

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,7 @@ fn print_type(&ps s, &ast::ty ty) {
206206
case (ast::ty_machine(?tm)) { word(s.s, common::ty_mach_to_str(tm)); }
207207
case (ast::ty_char) { word(s.s, "char"); }
208208
case (ast::ty_str) { word(s.s, "str"); }
209+
case (ast::ty_istr) { word(s.s, "istr"); }
209210
case (ast::ty_box(?mt)) { word(s.s, "@"); print_mt(s, mt); }
210211
case (ast::ty_vec(?mt)) {
211212
word(s.s, "vec[");
@@ -218,6 +219,13 @@ fn print_type(&ps s, &ast::ty ty) {
218219
print_mutability(s, mt.mut);
219220
word(s.s, "]");
220221
}
222+
case (ast::ty_ptr(?mt)) {
223+
word(s.s, "*");
224+
print_mt(s, mt);
225+
}
226+
case (ast::ty_task) {
227+
word(s.s, "task");
228+
}
221229
case (ast::ty_port(?t)) {
222230
word(s.s, "port[");
223231
print_type(s, *t);
@@ -228,7 +236,6 @@ fn print_type(&ps s, &ast::ty ty) {
228236
print_type(s, *t);
229237
word(s.s, "]");
230238
}
231-
case (ast::ty_type) { word(s.s, "type"); }
232239
case (ast::ty_tup(?elts)) {
233240
word(s.s, "tup");
234241
popen(s);
@@ -249,6 +256,9 @@ fn print_type(&ps s, &ast::ty ty) {
249256
commasep_cmnt(s, consistent, fields, print_field, get_span);
250257
pclose(s);
251258
}
259+
case (ast::ty_fn(?proto, ?inputs, ?output, ?cf, ?constrs)) {
260+
print_ty_fn(s, proto, none[str], inputs, output, cf, constrs);
261+
}
252262
case (ast::ty_obj(?methods)) {
253263
head(s, "obj");
254264
bopen(s);
@@ -264,10 +274,15 @@ fn print_type(&ps s, &ast::ty ty) {
264274
}
265275
bclose(s, ty.span);
266276
}
267-
case (ast::ty_fn(?proto, ?inputs, ?output, ?cf, ?constrs)) {
268-
print_ty_fn(s, proto, none[str], inputs, output, cf, constrs);
269-
}
270277
case (ast::ty_path(?path, _)) { print_path(s, path); }
278+
case (ast::ty_type) { word(s.s, "type"); }
279+
case (ast::ty_constr(?t, ?cs)) {
280+
print_type(s, *t);
281+
space(s.s);
282+
word(s.s, ":");
283+
space(s.s);
284+
word(s.s, ast_constrs_str(cs));
285+
}
271286
}
272287
end(s);
273288
}

0 commit comments

Comments
 (0)