Disallow type parameters to self. Closes #2422.
This commit is contained in:
parent
f2ad7c3426
commit
8d7f3bd1ca
1 changed files with 1 additions and 0 deletions
|
@ -302,6 +302,7 @@ fn ast_ty_to_ty<AC: ast_conv, RS: region_scope copy>(
|
||||||
// n.b.: resolve guarantees that the self type only appears in an
|
// n.b.: resolve guarantees that the self type only appears in an
|
||||||
// iface, which we rely upon in various places when creating
|
// iface, which we rely upon in various places when creating
|
||||||
// substs
|
// substs
|
||||||
|
check_path_args(tcx, path, NO_TPS | NO_REGIONS);
|
||||||
ty::mk_self(tcx)
|
ty::mk_self(tcx)
|
||||||
}
|
}
|
||||||
_ {
|
_ {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue