]> git.lizzy.rs Git - rust.git/commitdiff
Use in-band-lifetimes instead of unused explicit lifetimes
authorOliver Schneider <github35764891676564198441@oli-obk.de>
Thu, 24 May 2018 12:11:56 +0000 (14:11 +0200)
committerOliver Schneider <github35764891676564198441@oli-obk.de>
Thu, 24 May 2018 18:49:38 +0000 (20:49 +0200)
src/librustc/lib.rs
src/librustc/ty/layout.rs

index 1d53a305193fae50cb8e05d735b4985076ce3fd9..ddbd3d7caf32050c5ffb4c560fa6ebd8d5283ec3 100644 (file)
@@ -68,6 +68,7 @@
 #![feature(trusted_len)]
 #![feature(catch_expr)]
 #![feature(test)]
+#![feature(in_band_lifetimes)]
 
 #![recursion_limit="512"]
 
index 98df4b150fa6ac7e5fc716b415c5d04323fcf454..6169b3bc33fcd0be6b75a2a3da6d20541d1372b6 100644 (file)
@@ -1513,7 +1513,7 @@ fn layout_of(self, ty: Ty<'tcx>) -> Self::TyLayout {
 }
 
 // Helper (inherent) `layout_of` methods to avoid pushing `LayoutCx` to users.
-impl<'a, 'tcx, 'empty> TyCtxt<'a, 'tcx, 'empty> {
+impl TyCtxt<'a, 'tcx, '_> {
     /// Computes the layout of a type. Note that this implicitly
     /// executes in "reveal all" mode.
     #[inline]
@@ -1527,7 +1527,7 @@ pub fn layout_of(self, param_env_and_ty: ty::ParamEnvAnd<'tcx, Ty<'tcx>>)
     }
 }
 
-impl<'a, 'tcx, 'empty> ty::maps::TyCtxtAt<'a, 'tcx, 'empty> {
+impl ty::maps::TyCtxtAt<'a, 'tcx, '_> {
     /// Computes the layout of a type. Note that this implicitly
     /// executes in "reveal all" mode.
     #[inline]