Skip to content

Commit 1dce1b6

Browse files
committed
---
yaml --- r: 188103 b: refs/heads/auto c: f9bbef7 h: refs/heads/master i: 188101: e5751f7 188099: a674bfc 188095: 3bb9240 v: v3
1 parent 10a09ac commit 1dce1b6

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1010
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1111
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1212
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
13-
refs/heads/auto: f1ea2b3094b1c28e64af30e187e31aa82f5ff004
13+
refs/heads/auto: f9bbef7f448ba843052eb88733c79aa36c35d5ab
1414
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1515
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1616
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336

branches/auto/src/librustc_typeck/astconv.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1233,17 +1233,18 @@ pub fn finish_resolving_def_to_ty<'tcx>(this: &AstConv<'tcx>,
12331233
if segments.is_empty() {
12341234
opt_self_ty.expect("missing T in <T>::a::b::c")
12351235
} else {
1236-
tcx.sess.span_bug(span,
1237-
&format!("found module name used as a type: {}",
1238-
tcx.map.node_to_string(id.node)));
1236+
span_err!(tcx.sess, span, E0247, "found module name used as a type: {}",
1237+
tcx.map.node_to_string(id.node));
1238+
return this.tcx().types.err;
12391239
}
12401240
}
12411241
def::DefPrimTy(prim_ty) => {
12421242
prim_ty_to_ty(tcx, segments, prim_ty)
12431243
}
12441244
_ => {
1245-
span_fatal!(tcx.sess, span, E0248,
1246-
"found value name used as a type: {:?}", *def);
1245+
span_err!(tcx.sess, span, E0248,
1246+
"found value name used as a type: {:?}", *def);
1247+
return this.tcx().types.err;
12471248
}
12481249
};
12491250

@@ -1278,10 +1279,11 @@ pub fn ast_ty_to_ty<'tcx>(this: &AstConv<'tcx>,
12781279
match ast_ty_to_ty_cache.get(&ast_ty.id) {
12791280
Some(&ty::atttce_resolved(ty)) => return ty,
12801281
Some(&ty::atttce_unresolved) => {
1281-
span_fatal!(tcx.sess, ast_ty.span, E0246,
1282+
span_err!(tcx.sess, ast_ty.span, E0246,
12821283
"illegal recursive type; insert an enum \
12831284
or struct in the cycle, if this is \
12841285
desired");
1286+
return this.tcx().types.err;
12851287
}
12861288
None => { /* go on */ }
12871289
}

0 commit comments

Comments
 (0)