Auto merge of #57355 - arielb1:correct-subst, r=nikomatsakis

use the correct supertrait substitution in `object_ty_for_trait`

beta-nominating because regression.

Fixes #57156.
diff --git a/.gitignore b/.gitignore
index e18acfd..67e0dd8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,6 +13,7 @@
 .settings/
 .valgrindrc
 .vscode/
+.favorites.json
 /*-*-*-*/
 /*-*-*/
 /Makefile
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
index d70b2b5..ece8ded 100644
--- a/CODE_OF_CONDUCT.md
+++ b/CODE_OF_CONDUCT.md
@@ -35,6 +35,6 @@
 
 The enforcement policies listed above apply to all official Rust venues; including official IRC channels (#rust, #rust-internals, #rust-tools, #rust-libs, #rustc, #rust-beginners, #rust-docs, #rust-community, #rust-lang, and #cargo); GitHub repositories under rust-lang, rust-lang-nursery, and rust-lang-deprecated; and all forums under rust-lang.org (users.rust-lang.org, internals.rust-lang.org). For other projects adopting the Rust Code of Conduct, please contact the maintainers of those projects for enforcement. If you wish to use this code of conduct for your own project, consider explicitly mentioning your moderation policy or making a copy with your own moderation policy so as to avoid confusion.
 
-*Adapted from the [Node.js Policy on Trolling](http://blog.izs.me/post/30036893703/policy-on-trolling) as well as the [Contributor Covenant v1.3.0](https://www.contributor-covenant.org/version/1/3/0/).*
+*Adapted from the [Node.js Policy on Trolling](https://blog.izs.me/2012/08/policy-on-trolling) as well as the [Contributor Covenant v1.3.0](https://www.contributor-covenant.org/version/1/3/0/).*
 
 [mod_team]: https://www.rust-lang.org/team.html#Moderation-team
diff --git a/COPYRIGHT b/COPYRIGHT
index e2d0ed7..6596c5a 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -229,35 +229,3 @@
     NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
     USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
     OF SUCH DAMAGE.  */
-
-* jemalloc, under src/jemalloc:
-
-    Copyright (C) 2002-2014 Jason Evans
-    <jasone@canonware.com>. All rights reserved.
-    Copyright (C) 2007-2012 Mozilla Foundation.
-    All rights reserved.
-    Copyright (C) 2009-2014 Facebook, Inc.
-    All rights reserved.
-
-    Redistribution and use in source and binary forms, with or without
-    modification, are permitted provided that the following conditions are met:
-    1. Redistributions of source code must retain the above copyright notice(s),
-       this list of conditions and the following disclaimer.
-    2. Redistributions in binary form must reproduce the above copyright notice(s),
-       this list of conditions and the following disclaimer in the documentation
-       and/or other materials provided with the distribution.
-
-    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S)
-    ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
-    INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-    MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-    DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT HOLDER(S)
-    BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-    EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-    LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-    LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-    HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
-    IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-    NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
-    USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
-    OF SUCH DAMAGE.
diff --git a/Cargo.lock b/Cargo.lock
index 6f24f8d..1fde5ac 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -15,7 +15,7 @@
 name = "alloc"
 version = "0.0.0"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
  "rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand_xorshift 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -75,7 +75,7 @@
 version = "0.2.11"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "termion 1.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -87,7 +87,7 @@
 dependencies = [
  "backtrace-sys 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-demangle 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -98,8 +98,8 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-std-workspace-core 1.0.0",
 ]
 
@@ -136,7 +136,7 @@
  "filetime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "petgraph 0.4.13 (registry+https://github.com/rust-lang/crates.io-index)",
  "pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -219,13 +219,13 @@
  "jobserver 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazycell 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libgit2-sys 0.7.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "miow 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "opener 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl 0.10.15 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl 0.10.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "pretty_env_logger 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "proptest 0.8.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-workspace-hack 1.0.0",
@@ -322,12 +322,12 @@
  "clippy-mini-macro-test 0.2.0",
  "clippy_dev 0.0.1",
  "clippy_lints 0.0.212",
- "compiletest_rs 0.3.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiletest_rs 0.3.18 (registry+https://github.com/rust-lang/crates.io-index)",
  "derive-new 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-workspace-hack 1.0.0",
- "rustc_tools_util 0.1.0",
+ "rustc_tools_util 0.1.1",
  "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_derive 1.0.81 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -406,12 +406,12 @@
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "compiler_builtins"
-version = "0.1.2"
+version = "0.1.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -427,7 +427,7 @@
  "filetime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "miow 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -441,16 +441,17 @@
 
 [[package]]
 name = "compiletest_rs"
-version = "0.3.17"
+version = "0.3.18"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "diff 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "filetime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "miow 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "regex 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "rustfix 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_derive 1.0.81 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -471,7 +472,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -583,7 +584,7 @@
 dependencies = [
  "commoncrypto 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "hex 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl 0.10.15 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl 0.10.16 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -594,9 +595,9 @@
 dependencies = [
  "curl-sys 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "schannel 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "socket2 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -608,10 +609,10 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libnghttp2-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "libz-sys 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "vcpkg 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -658,7 +659,7 @@
 version = "1.0.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -667,8 +668,8 @@
 version = "0.1.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-std-workspace-core 1.0.0",
 ]
 
@@ -777,7 +778,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -792,7 +793,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "crc32fast 1.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libz-sys 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "miniz-sys 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "miniz_oxide_c_api 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -825,7 +826,7 @@
 version = "0.3.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-std-workspace-core 1.0.0",
 ]
 
@@ -834,7 +835,7 @@
 version = "0.4.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -899,11 +900,11 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libgit2-sys 0.7.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1078,7 +1079,7 @@
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "fs_extra 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1086,7 +1087,7 @@
 version = "0.1.12"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1149,7 +1150,7 @@
 
 [[package]]
 name = "libc"
-version = "0.2.45"
+version = "0.2.46"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "rustc-std-workspace-core 1.0.0",
@@ -1162,10 +1163,10 @@
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "curl-sys 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libssh2-sys 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
  "libz-sys 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1175,7 +1176,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1184,9 +1185,9 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "libz-sys 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "vcpkg 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1197,7 +1198,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "vcpkg 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1238,7 +1239,7 @@
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "filetime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1311,7 +1312,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1320,7 +1321,7 @@
 version = "0.6.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1343,7 +1344,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1361,7 +1362,7 @@
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "crc 1.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "miniz_oxide 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1381,7 +1382,7 @@
  "byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "cargo_metadata 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "colored 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiletest_rs 0.3.17 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiletest_rs 0.3.18 (registry+https://github.com/rust-lang/crates.io-index)",
  "directories 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "env_logger 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1432,7 +1433,7 @@
 version = "1.8.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1452,15 +1453,15 @@
 
 [[package]]
 name = "openssl"
-version = "0.10.15"
+version = "0.10.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "foreign-types 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
- "openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
+ "openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1478,11 +1479,11 @@
 
 [[package]]
 name = "openssl-sys"
-version = "0.9.39"
+version = "0.9.40"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "openssl-src 111.1.0+1.1.1a (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.14 (registry+https://github.com/rust-lang/crates.io-index)",
  "vcpkg 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1518,9 +1519,9 @@
 name = "panic_abort"
 version = "0.0.0"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -1528,9 +1529,9 @@
 version = "0.0.0"
 dependencies = [
  "alloc 0.0.0",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "unwind 0.0.0",
 ]
 
@@ -1548,7 +1549,7 @@
 version = "0.3.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1681,7 +1682,7 @@
 version = "0.0.0"
 dependencies = [
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
 ]
 
@@ -1773,7 +1774,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
@@ -1784,7 +1785,7 @@
 dependencies = [
  "cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand_core 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1796,7 +1797,7 @@
 dependencies = [
  "cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand_chacha 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand_core 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand_hc 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1878,7 +1879,7 @@
 dependencies = [
  "crossbeam-deque 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -1983,7 +1984,7 @@
  "rls-vfs 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-workspace-hack 1.0.0",
- "rustc_tools_util 0.1.0",
+ "rustc_tools_util 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustfmt-nightly 1.0.1",
  "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_derive 1.0.81 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2200,7 +2201,7 @@
 version = "0.1.10"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "rustc-std-workspace-core 1.0.0",
 ]
 
@@ -2238,7 +2239,7 @@
 dependencies = [
  "crossbeam-deque 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -2259,8 +2260,10 @@
 name = "rustc-workspace-hack"
 version = "1.0.0"
 dependencies = [
+ "byteorder 1.2.7 (registry+https://github.com/rust-lang/crates.io-index)",
  "parking_lot 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)",
+ "scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.82 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_json 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
  "smallvec 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2298,7 +2301,7 @@
  "alloc 0.0.0",
  "build_helper 0.1.0",
  "cmake 0.1.33 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
 ]
 
@@ -2334,7 +2337,7 @@
  "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
  "jobserver 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "memmap 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -2492,7 +2495,7 @@
  "alloc 0.0.0",
  "build_helper 0.1.0",
  "cmake 0.1.33 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
 ]
 
@@ -2544,7 +2547,7 @@
  "alloc 0.0.0",
  "build_helper 0.1.0",
  "cmake 0.1.33 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
 ]
 
@@ -2632,7 +2635,12 @@
 
 [[package]]
 name = "rustc_tools_util"
-version = "0.1.0"
+version = "0.1.1"
+
+[[package]]
+name = "rustc_tools_util"
+version = "0.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "rustc_traits"
@@ -2657,7 +2665,7 @@
  "alloc 0.0.0",
  "build_helper 0.1.0",
  "cmake 0.1.33 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
 ]
 
@@ -2876,7 +2884,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -2893,11 +2901,11 @@
  "alloc 0.0.0",
  "backtrace-sys 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)",
  "cc 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)",
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
  "dlmalloc 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "fortanix-sgx-abi 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "panic_abort 0.0.0",
  "panic_unwind 0.0.0",
  "profiler_builtins 0.0.0",
@@ -3048,7 +3056,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "filetime 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "xattr 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -3059,7 +3067,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "rand 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "remove_dir_all 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -3102,7 +3110,7 @@
 version = "1.5.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_termios 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -3146,7 +3154,7 @@
 version = "0.1.40"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
  "redox_syscall 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
@@ -3234,9 +3242,9 @@
 name = "unwind"
 version = "0.0.0"
 dependencies = [
- "compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
+ "compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core 0.0.0",
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -3303,7 +3311,7 @@
 version = "0.1.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -3367,7 +3375,7 @@
 version = "0.2.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)",
+ "libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -3414,8 +3422,8 @@
 "checksum colored 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b0aa3473e85a3161b59845d6096b289bb577874cafeaf75ea1b1beaa6572c7fc"
 "checksum commoncrypto 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d056a8586ba25a1e4d61cb090900e495952c7886786fc55f909ab2f819b69007"
 "checksum commoncrypto-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1fed34f46747aa73dfaa578069fd8279d2818ade2b55f38f22a9401c7f4083e2"
-"checksum compiler_builtins 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "8ad611263b9f31bdb66e66227d3b781600fd1e68d5deee29b23f5e2ac9cb4892"
-"checksum compiletest_rs 0.3.17 (registry+https://github.com/rust-lang/crates.io-index)" = "89747fe073b7838343bd2c2445e7a7c2e0d415598f8925f0fa9205b9cdfc48cb"
+"checksum compiler_builtins 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "bd14d75a16b6c836c62350e2e8c85495ed8e13df30a7298c574cb1ee4cdac7bc"
+"checksum compiletest_rs 0.3.18 (registry+https://github.com/rust-lang/crates.io-index)" = "0d76d4322a40f6b0db7259d4f2c8a65ed8b0d84fce0bbc61b98cf47f8ec6eec3"
 "checksum core-foundation 0.6.3 (registry+https://github.com/rust-lang/crates.io-index)" = "4e2640d6d0bf22e82bed1b73c6aef8d5dd31e5abe6666c57e6d45e2649f4f887"
 "checksum core-foundation-sys 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e7ca8a5221364ef15ce201e8ed2f609fc312682a8f4e0e3d4aa5879764e0fa3b"
 "checksum crc 1.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d663548de7f5cca343f1e0a48d14dcfb0e9eb4e079ec58883b7251539fa10aeb"
@@ -3489,7 +3497,7 @@
 "checksum lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "76f033c7ad61445c5b347c7382dd1237847eb1bce590fe50365dcb33d546be73"
 "checksum lazy_static 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a374c89b9db55895453a74c1e38861d9deec0b01b405a82516e9d5de4820dea1"
 "checksum lazycell 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b294d6fa9ee409a054354afc4352b0b9ef7ca222c69b8812cbea9e7d2bf3783f"
-"checksum libc 0.2.45 (registry+https://github.com/rust-lang/crates.io-index)" = "2d2857ec59fadc0773853c664d2d18e7198e83883e7060b63c924cb077bd5c74"
+"checksum libc 0.2.46 (registry+https://github.com/rust-lang/crates.io-index)" = "023a4cd09b2ff695f9734c1934145a315594b7986398496841c7031a5a1bbdbd"
 "checksum libgit2-sys 0.7.11 (registry+https://github.com/rust-lang/crates.io-index)" = "48441cb35dc255da8ae72825689a95368bf510659ae1ad55dc4aa88cb1789bf1"
 "checksum libnghttp2-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d75d7966bda4730b722d1eab8e668df445368a24394bae9fc1e8dc0ab3dbe4f4"
 "checksum libssh2-sys 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "126a1f4078368b163bfdee65fbab072af08a1b374a5551b21e87ade27b1fbf9d"
@@ -3520,10 +3528,10 @@
 "checksum num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c51a3322e4bca9d212ad9a158a02abc6934d005490c054a2778df73a70aa0a30"
 "checksum open 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c281318d992e4432cfa799969467003d05921582a7489a8325e37f8a450d5113"
 "checksum opener 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "04b1d6b086d9b3009550f9b6f81b10ad9428cf14f404b8e1a3a06f6f012c8ec9"
-"checksum openssl 0.10.15 (registry+https://github.com/rust-lang/crates.io-index)" = "5e1309181cdcbdb51bc3b6bedb33dfac2a83b3d585033d3f6d9e22e8c1928613"
+"checksum openssl 0.10.16 (registry+https://github.com/rust-lang/crates.io-index)" = "ec7bd7ca4cce6dbdc77e7c1230682740d307d1218a87fb0349a571272be749f9"
 "checksum openssl-probe 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "77af24da69f9d9341038eba93a073b1fdaaa1b788221b00a69bce9e762cb32de"
 "checksum openssl-src 111.1.0+1.1.1a (registry+https://github.com/rust-lang/crates.io-index)" = "26bb632127731bf4ac49bf86a5dde12d2ca0918c2234fc39d79d4da2ccbc6da7"
-"checksum openssl-sys 0.9.39 (registry+https://github.com/rust-lang/crates.io-index)" = "278c1ad40a89aa1e741a1eed089a2f60b18fab8089c3139b542140fc7d674106"
+"checksum openssl-sys 0.9.40 (registry+https://github.com/rust-lang/crates.io-index)" = "1bb974e77de925ef426b6bc82fce15fd45bdcbeb5728bffcfc7cdeeb7ce1c2d6"
 "checksum ordermap 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)" = "a86ed3f5f244b372d6b1a00b72ef7f8876d0bc6a78a4c9985c53614041512063"
 "checksum ordslice 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "dd20eec3dbe4376829cb7d80ae6ac45e0a766831dca50202ff2d40db46a8a024"
 "checksum owning_ref 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "cdf84f41639e037b484f93433aa3897863b561ed65c6e59c7073d7c561710f37"
@@ -3593,6 +3601,7 @@
 "checksum rustc-rayon 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8c6d5a683c6ba4ed37959097e88d71c9e8e26659a3cb5be8b389078e7ad45306"
 "checksum rustc-rayon-core 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "40f06724db71e18d68b3b946fdf890ca8c921d9edccc1404fdfdb537b0d12649"
 "checksum rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)" = "dcf128d1287d2ea9d80910b5f1120d0b8eede3fbf1abe91c40d39ea7d51e6fda"
+"checksum rustc_tools_util 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b3c5a95edfa0c893236ae4778bb7c4752760e4c0d245e19b5eff33c5aa5eb9dc"
 "checksum rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a"
 "checksum rustfix 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "af7c21531a91512a4a51b490be6ba1c8eff34fdda0dc5bf87dc28d86748aac56"
 "checksum rusty-fork 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9591f190d2852720b679c21f66ad929f9f1d7bb09d1193c26167586029d8489c"
diff --git a/Cargo.toml b/Cargo.toml
index c693985..cb3c0ee 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -70,4 +70,3 @@
 
 [patch."https://github.com/rust-lang/rust-clippy"]
 clippy_lints = { path = "src/tools/clippy/clippy_lints" }
-rustc_tools_util = { path = "src/tools/clippy/rustc_tools_util" }
diff --git a/RELEASES.md b/RELEASES.md
index 7022a86..aae25ab 100644
--- a/RELEASES.md
+++ b/RELEASES.md
@@ -1,3 +1,277 @@
+Version 1.32.0 (2019-01-17)
+==========================
+
+Language
+--------
+#### 2018 edition
+- [You can now use the `?` operator in macro definitions.][56245] The `?`
+  operator allows you to specify zero or one repetitions similar to the `*` and
+  `+` operators.
+- [Module paths with no leading keyword like `super`, `self`, or `crate`, will
+  now always resolve to the item (`enum`, `struct`, etc.) available in the
+  module if present, before resolving to a external crate or an item the prelude.][56759]
+  E.g.
+  ```rust
+  enum Color { Red, Green, Blue }
+
+  use Color::*;
+  ```
+
+#### All editions
+- [You can now match against `PhantomData<T>` types.][55837]
+- [You can now match against literals in macros with the `literal`
+  specifier.][56072] This will match against a literal of any type.
+  E.g. `1`, `'A'`, `"Hello World"`
+- [Self can now be used as a constructor and pattern for unit and tuple structs.][56365] E.g. 
+  ```rust
+  struct Point(i32, i32);
+
+  impl Point {
+      pub fn new(x: i32, y: i32) -> Self {
+          Self(x, y)
+      }
+
+      pub fn is_origin(&self) -> bool {
+          match self {
+              Self(0, 0) => true,
+              _ => false,
+          }
+      }
+  }
+  ```
+- [Self can also now be used in type definitions.][56366] E.g.
+  ```rust
+  enum List<T>
+  where
+      Self: PartialOrd<Self> // can write `Self` instead of `List<T>`
+  {
+      Nil,
+      Cons(T, Box<Self>) // likewise here
+  }
+  ```
+- [You can now mark traits with `#[must_use]`.][55663] This provides a warning if
+  a `impl Trait` or `dyn Trait` is returned and unused in the program.
+
+Compiler
+--------
+- [The default allocator has changed from jemalloc to the default allocator on
+  your system.][55238] The compiler itself on Linux & macOS will still use
+  jemalloc, but programs compiled with it will use the system allocator.
+- [Added the `aarch64-pc-windows-msvc` target.][55702]
+
+Libraries
+---------
+- [`PathBuf` now implements `FromStr`.][55148]
+- [`Box<[T]>` now implements `FromIterator<T>`.][55843]
+- [The `dbg!` macro has been stabilized.][56395] This macro enables you to
+  easily debug expressions in your rust program. E.g.
+  ```rust
+  let a = 2;
+  let b = dbg!(a * 2) + 1;
+  //      ^-- prints: [src/main.rs:4] a * 2 = 4
+  assert_eq!(b, 5);
+  ```
+
+The following APIs are now `const` functions and can be used in a
+`const` context.
+
+- [`Cell::as_ptr`]
+- [`UnsafeCell::get`]
+- [`char::is_ascii`]
+- [`iter::empty`]
+- [`ManuallyDrop::new`]
+- [`ManuallyDrop::into_inner`]
+- [`RangeInclusive::start`]
+- [`RangeInclusive::end`]
+- [`NonNull::as_ptr`]
+- [`slice::as_ptr`]
+- [`str::as_ptr`]
+- [`Duration::as_secs`]
+- [`Duration::subsec_millis`]
+- [`Duration::subsec_micros`]
+- [`Duration::subsec_nanos`]
+- [`CStr::as_ptr`]
+- [`Ipv4Addr::is_unspecified`]
+- [`Ipv6Addr::new`]
+- [`Ipv6Addr::octets`]
+
+Stabilized APIs
+---------------
+- [`i8::to_be_bytes`]
+- [`i8::to_le_bytes`]
+- [`i8::to_ne_bytes`]
+- [`i8::from_be_bytes`]
+- [`i8::from_le_bytes`]
+- [`i8::from_ne_bytes`]
+- [`i16::to_be_bytes`]
+- [`i16::to_le_bytes`]
+- [`i16::to_ne_bytes`]
+- [`i16::from_be_bytes`]
+- [`i16::from_le_bytes`]
+- [`i16::from_ne_bytes`]
+- [`i32::to_be_bytes`]
+- [`i32::to_le_bytes`]
+- [`i32::to_ne_bytes`]
+- [`i32::from_be_bytes`]
+- [`i32::from_le_bytes`]
+- [`i32::from_ne_bytes`]
+- [`i64::to_be_bytes`]
+- [`i64::to_le_bytes`]
+- [`i64::to_ne_bytes`]
+- [`i64::from_be_bytes`]
+- [`i64::from_le_bytes`]
+- [`i64::from_ne_bytes`]
+- [`isize::to_be_bytes`]
+- [`isize::to_le_bytes`]
+- [`isize::to_ne_bytes`]
+- [`isize::from_be_bytes`]
+- [`isize::from_le_bytes`]
+- [`isize::from_ne_bytes`]
+- [`u8::to_be_bytes`]
+- [`u8::to_le_bytes`]
+- [`u8::to_ne_bytes`]
+- [`u8::from_be_bytes`]
+- [`u8::from_le_bytes`]
+- [`u8::from_ne_bytes`]
+- [`u16::to_be_bytes`]
+- [`u16::to_le_bytes`]
+- [`u16::to_ne_bytes`]
+- [`u16::from_be_bytes`]
+- [`u16::from_le_bytes`]
+- [`u16::from_ne_bytes`]
+- [`u32::to_be_bytes`]
+- [`u32::to_le_bytes`]
+- [`u32::to_ne_bytes`]
+- [`u32::from_be_bytes`]
+- [`u32::from_le_bytes`]
+- [`u32::from_ne_bytes`]
+- [`u64::to_be_bytes`]
+- [`u64::to_le_bytes`]
+- [`u64::to_ne_bytes`]
+- [`u64::from_be_bytes`]
+- [`u64::from_le_bytes`]
+- [`u64::from_ne_bytes`]
+- [`usize::to_be_bytes`]
+- [`usize::to_le_bytes`]
+- [`usize::to_ne_bytes`]
+- [`usize::from_be_bytes`]
+- [`usize::from_le_bytes`]
+- [`usize::from_ne_bytes`]
+
+Cargo
+-----
+- [You can now run `cargo c` as an alias for `cargo check`.][cargo/6218]
+- [Usernames are now allowed in alt registry URLs.][cargo/6242]
+
+Misc
+----
+- [`libproc_macro` has been added to the `rust-src` distribution.][55280]
+
+Compatibility Notes
+-------------------
+- [The argument types for AVX's
+  `_mm256_stream_si256`, `_mm256_stream_pd`, `_mm256_stream_ps`][55610] have
+  been changed from `*const` to `*mut` as the previous implementation
+  was unsound.
+
+
+[55148]: https://github.com/rust-lang/rust/pull/55148/
+[55238]: https://github.com/rust-lang/rust/pull/55238/
+[55280]: https://github.com/rust-lang/rust/pull/55280/
+[55610]: https://github.com/rust-lang/rust/pull/55610/
+[55663]: https://github.com/rust-lang/rust/pull/55663/
+[55702]: https://github.com/rust-lang/rust/pull/55702/
+[55837]: https://github.com/rust-lang/rust/pull/55837/
+[55843]: https://github.com/rust-lang/rust/pull/55843/
+[56072]: https://github.com/rust-lang/rust/pull/56072/
+[56245]: https://github.com/rust-lang/rust/pull/56245/
+[56365]: https://github.com/rust-lang/rust/pull/56365/
+[56366]: https://github.com/rust-lang/rust/pull/56366/
+[56395]: https://github.com/rust-lang/rust/pull/56395/
+[56759]: https://github.com/rust-lang/rust/pull/56759/
+[cargo/6218]: https://github.com/rust-lang/cargo/pull/6218/
+[cargo/6242]: https://github.com/rust-lang/cargo/pull/6242/
+[`CStr::as_ptr`]: https://doc.rust-lang.org/std/ffi/struct.CStr.html#method.as_ptr
+[`Cell::as_ptr`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.as_ptr
+[`Duration::as_secs`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs
+[`Duration::subsec_micros`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_micros
+[`Duration::subsec_millis`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_millis
+[`Duration::subsec_nanos`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_nanos
+[`Ipv4Addr::is_unspecified`]: https://doc.rust-lang.org/std/net/struct.Ipv4Addr.html#method.is_unspecified
+[`Ipv6Addr::new`]: https://doc.rust-lang.org/std/net/struct.Ipv6Addr.html#method.new
+[`Ipv6Addr::octets`]: https://doc.rust-lang.org/std/net/struct.Ipv6Addr.html#method.octets
+[`ManuallyDrop::into_inner`]: https://doc.rust-lang.org/std/mem/struct.ManuallyDrop.html#method.into_inner
+[`ManuallyDrop::new`]: https://doc.rust-lang.org/std/mem/struct.ManuallyDrop.html#method.new
+[`NonNull::as_ptr`]: https://doc.rust-lang.org/std/ptr/struct.NonNull.html#method.as_ptr
+[`RangeInclusive::end`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html#method.end
+[`RangeInclusive::start`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html#method.start
+[`UnsafeCell::get`]: https://doc.rust-lang.org/std/cell/struct.UnsafeCell.html#method.get
+[`slice::as_ptr`]: https://doc.rust-lang.org/std/primitive.slice.html#method.as_ptr
+[`char::is_ascii`]: https://doc.rust-lang.org/std/primitive.char.html#method.is_ascii
+[`i16::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_be_bytes
+[`i16::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_le_bytes
+[`i16::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_ne_bytes
+[`i16::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_be_bytes
+[`i16::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_le_bytes
+[`i16::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_ne_bytes
+[`i32::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_be_bytes
+[`i32::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_le_bytes
+[`i32::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_ne_bytes
+[`i32::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_be_bytes
+[`i32::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_le_bytes
+[`i32::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_ne_bytes
+[`i64::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_be_bytes
+[`i64::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_le_bytes
+[`i64::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_ne_bytes
+[`i64::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_be_bytes
+[`i64::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_le_bytes
+[`i64::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_ne_bytes
+[`i8::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_be_bytes
+[`i8::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_le_bytes
+[`i8::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_ne_bytes
+[`i8::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_be_bytes
+[`i8::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_le_bytes
+[`i8::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_ne_bytes
+[`isize::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_be_bytes
+[`isize::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_le_bytes
+[`isize::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_ne_bytes
+[`isize::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_be_bytes
+[`isize::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_le_bytes
+[`isize::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_ne_bytes
+[`iter::empty`]: https://doc.rust-lang.org/std/iter/fn.empty.html
+[`str::as_ptr`]: https://doc.rust-lang.org/std/primitive.str.html#method.as_ptr
+[`u16::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_be_bytes
+[`u16::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_le_bytes
+[`u16::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_ne_bytes
+[`u16::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_be_bytes
+[`u16::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_le_bytes
+[`u16::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_ne_bytes
+[`u32::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_be_bytes
+[`u32::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_le_bytes
+[`u32::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_ne_bytes
+[`u32::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_be_bytes
+[`u32::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_le_bytes
+[`u32::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_ne_bytes
+[`u64::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_be_bytes
+[`u64::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_le_bytes
+[`u64::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_ne_bytes
+[`u64::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_be_bytes
+[`u64::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_le_bytes
+[`u64::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_ne_bytes
+[`u8::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_be_bytes
+[`u8::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_le_bytes
+[`u8::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_ne_bytes
+[`u8::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_be_bytes
+[`u8::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_le_bytes
+[`u8::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_ne_bytes
+[`usize::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_be_bytes
+[`usize::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_le_bytes
+[`usize::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_ne_bytes
+[`usize::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_be_bytes
+[`usize::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_le_bytes
+[`usize::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_ne_bytes
+
+
 Version 1.31.1 (2018-12-20)
 ===========================
 
diff --git a/config.toml.example b/config.toml.example
index f75e220..c68d358 100644
--- a/config.toml.example
+++ b/config.toml.example
@@ -90,6 +90,12 @@
 # with clang-cl, so this is special in that it only compiles LLVM with clang-cl
 #clang-cl = '/path/to/clang-cl.exe'
 
+# Use libc++ when building LLVM instead of libstdc++. This is the default on
+# platforms already use libc++ as the default C++ library, but this option
+# allows you to use libc++ even on platforms when it's not. You need to ensure
+# that your host compiler ships with libc++.
+#use-libcxx = true
+
 # =============================================================================
 # General build configuration options
 # =============================================================================
@@ -171,7 +177,7 @@
 
 # Installs chosen set of extended tools if enables. By default builds all.
 # If chosen tool failed to build the installation fails.
-#tools = ["cargo", "rls", "rustfmt", "analysis", "src"]
+#tools = ["cargo", "rls", "clippy", "rustfmt", "analysis", "src"]
 
 # Verbosity level: 0 == not verbose, 1 == verbose, 2 == very verbose
 #verbose = 0
diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs
index 117ff0e..9c58f5b 100644
--- a/src/bootstrap/builder.rs
+++ b/src/bootstrap/builder.rs
@@ -449,6 +449,7 @@
                 dist::Rls,
                 dist::Rustfmt,
                 dist::Clippy,
+                dist::Miri,
                 dist::LlvmTools,
                 dist::Lldb,
                 dist::Extended,
@@ -461,6 +462,7 @@
                 install::Rls,
                 install::Rustfmt,
                 install::Clippy,
+                install::Miri,
                 install::Analysis,
                 install::Src,
                 install::Rustc
diff --git a/src/bootstrap/check.rs b/src/bootstrap/check.rs
index 050db93..cc539d4 100644
--- a/src/bootstrap/check.rs
+++ b/src/bootstrap/check.rs
@@ -38,7 +38,6 @@
         builder.info(&format!("Checking std artifacts ({} -> {})", &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &libstd_stamp(builder, compiler, target),
                   true);
 
@@ -85,7 +84,6 @@
         builder.info(&format!("Checking compiler artifacts ({} -> {})", &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &librustc_stamp(builder, compiler, target),
                   true);
 
@@ -136,7 +134,6 @@
         let _folder = builder.fold_output(|| format!("stage{}-rustc_codegen_llvm", compiler.stage));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &codegen_backend_stamp(builder, compiler, target, backend),
                   true);
     }
@@ -174,7 +171,6 @@
         builder.info(&format!("Checking test artifacts ({} -> {})", &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &libtest_stamp(builder, compiler, target),
                   true);
 
@@ -222,7 +218,6 @@
         println!("Checking rustdoc artifacts ({} -> {})", &compiler.host, target);
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &rustdoc_stamp(builder, compiler, target),
                   true);
 
diff --git a/src/bootstrap/compile.rs b/src/bootstrap/compile.rs
index 821bd00..8bc7c58 100644
--- a/src/bootstrap/compile.rs
+++ b/src/bootstrap/compile.rs
@@ -19,6 +19,7 @@
 use filetime::FileTime;
 use serde_json;
 
+use crate::dist;
 use crate::util::{exe, libdir, is_dylib};
 use crate::{Compiler, Mode, GitRepo};
 use crate::native;
@@ -104,7 +105,6 @@
                 &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &libstd_stamp(builder, compiler, target),
                   false);
 
@@ -365,7 +365,6 @@
                 &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &libtest_stamp(builder, compiler, target),
                   false);
 
@@ -493,7 +492,6 @@
                  compiler.stage, &compiler.host, target));
         run_cargo(builder,
                   &mut cargo,
-                  vec![],
                   &librustc_stamp(builder, compiler, target),
                   false);
 
@@ -636,47 +634,18 @@
 
         let out_dir = builder.cargo_out(compiler, Mode::Codegen, target);
 
-        let mut cargo = builder.cargo(compiler, Mode::Codegen, target, "rustc");
+        let mut cargo = builder.cargo(compiler, Mode::Codegen, target, "build");
         cargo.arg("--manifest-path")
             .arg(builder.src.join("src/librustc_codegen_llvm/Cargo.toml"));
         rustc_cargo_env(builder, &mut cargo);
 
         let features = build_codegen_backend(&builder, &mut cargo, &compiler, target, backend);
 
-        let mut cargo_tails_args = vec![];
-
-        if builder.config.llvm_thin_lto {
-            cargo_tails_args.push("--".to_string());
-
-            let num_jobs = builder.jobs();
-
-            if !target.contains("msvc") {
-                // Here we assume that the linker is clang. If it's not, there'll
-                // be linker errors.
-                cargo_tails_args.push("-Clink-arg=-fuse-ld=lld".to_string());
-                cargo_tails_args.push("-Clink-arg=-flto=thin".to_string());
-
-                if builder.config.llvm_optimize {
-                    cargo_tails_args.push("-Clink-arg=-O2".to_string());
-                }
-
-                // Let's make LLD respect the `-j` option.
-                let num_jobs_arg = format!("-Clink-arg=-Wl,--thinlto-jobs={}", num_jobs);
-                cargo_tails_args.push(num_jobs_arg);
-            } else {
-                // Here we assume that the linker is lld-link.exe. lld-link.exe
-                // does not need the extra arguments except for num_jobs
-                let num_jobs_arg = format!("-Clink-arg=/opt:lldltojobs={}", num_jobs);
-                cargo_tails_args.push(num_jobs_arg);
-            }
-        }
-
         let tmp_stamp = out_dir.join(".tmp.stamp");
 
         let _folder = builder.fold_output(|| format!("stage{}-rustc_codegen_llvm", compiler.stage));
         let files = run_cargo(builder,
                               cargo.arg("--features").arg(features),
-                              cargo_tails_args,
                               &tmp_stamp,
                               false);
         if builder.config.dry_run {
@@ -749,9 +718,14 @@
                                          "libstdc++.a");
                 cargo.env("LLVM_STATIC_STDCPP", file);
             }
-            if builder.config.llvm_link_shared {
+            if builder.config.llvm_link_shared ||
+                (builder.config.llvm_thin_lto && backend != "emscripten")
+            {
                 cargo.env("LLVM_LINK_SHARED", "1");
             }
+            if builder.config.llvm_use_libcxx {
+                cargo.env("LLVM_USE_LIBCXX", "1");
+            }
         }
         _ => panic!("unknown backend: {}", backend),
     }
@@ -989,6 +963,8 @@
             copy_lld_to_sysroot(builder, target_compiler, &lld_install);
         }
 
+        dist::maybe_install_llvm_dylib(builder, target_compiler.host, &sysroot);
+
         // Link the compiler binary itself into place
         let out_dir = builder.cargo_out(build_compiler, Mode::Rustc, host);
         let rustc = out_dir.join(exe("rustc_binary", &*host));
@@ -1015,7 +991,6 @@
 
 pub fn run_cargo(builder: &Builder,
                  cargo: &mut Command,
-                 tail_args: Vec<String>,
                  stamp: &Path,
                  is_check: bool)
     -> Vec<PathBuf>
@@ -1038,7 +1013,7 @@
     // files we need to probe for later.
     let mut deps = Vec::new();
     let mut toplevel = Vec::new();
-    let ok = stream_cargo(builder, cargo, tail_args, &mut |msg| {
+    let ok = stream_cargo(builder, cargo, &mut |msg| {
         let filenames = match msg {
             CargoMessage::CompilerArtifact { filenames, .. } => filenames,
             _ => return,
@@ -1163,7 +1138,6 @@
 pub fn stream_cargo(
     builder: &Builder,
     cargo: &mut Command,
-    tail_args: Vec<String>,
     cb: &mut dyn FnMut(CargoMessage),
 ) -> bool {
     if builder.config.dry_run {
@@ -1174,10 +1148,6 @@
     cargo.arg("--message-format").arg("json")
          .stdout(Stdio::piped());
 
-    for arg in tail_args {
-        cargo.arg(arg);
-    }
-
     builder.verbose(&format!("running: {:?}", cargo));
     let mut child = match cargo.spawn() {
         Ok(child) => child,
diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs
index 8655cf0..9421817 100644
--- a/src/bootstrap/config.rs
+++ b/src/bootstrap/config.rs
@@ -82,6 +82,8 @@
     pub lldb_enabled: bool,
     pub llvm_tools_enabled: bool,
 
+    pub llvm_use_libcxx: bool,
+
     // rust codegen options
     pub rust_optimize: bool,
     pub rust_codegen_units: Option<u32>,
@@ -252,6 +254,7 @@
     link_shared: Option<bool>,
     version_suffix: Option<String>,
     clang_cl: Option<String>,
+    use_libcxx: Option<bool>,
 }
 
 #[derive(Deserialize, Default, Clone)]
@@ -513,6 +516,7 @@
             config.llvm_link_jobs = llvm.link_jobs;
             config.llvm_version_suffix = llvm.version_suffix.clone();
             config.llvm_clang_cl = llvm.clang_cl.clone();
+            set(&mut config.llvm_use_libcxx, llvm.use_libcxx);
         }
 
         if let Some(ref rust) = toml.rust {
diff --git a/src/bootstrap/configure.py b/src/bootstrap/configure.py
index d13a3dc..b0c3c970 100755
--- a/src/bootstrap/configure.py
+++ b/src/bootstrap/configure.py
@@ -62,6 +62,7 @@
 o("lld", "rust.lld", "build lld")
 o("lldb", "rust.lldb", "build lldb")
 o("missing-tools", "dist.missing-tools", "allow failures when building tools")
+o("use-libcxx", "llvm.use_libcxx", "build LLVM with libc++")
 
 # Optimization and debugging options. These may be overridden by the release
 # channel, etc.
diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs
index 9f97e57..df34dfe 100644
--- a/src/bootstrap/dist.rs
+++ b/src/bootstrap/dist.rs
@@ -32,6 +32,8 @@
         format!("{}-{}", component, builder.rls_package_vers())
     } else if component == "clippy" {
         format!("{}-{}", component, builder.clippy_package_vers())
+    } else if component == "miri" {
+        format!("{}-{}", component, builder.miri_package_vers())
     } else if component == "rustfmt" {
         format!("{}-{}", component, builder.rustfmt_package_vers())
     } else if component == "llvm-tools" {
@@ -671,10 +673,18 @@
         let mut src = builder.sysroot_libdir(compiler, target).to_path_buf();
         src.pop(); // Remove the trailing /lib folder from the sysroot_libdir
         builder.cp_filtered(&src, &dst, &|path| {
-            let name = path.file_name().and_then(|s| s.to_str());
-            name != Some(builder.config.rust_codegen_backends_dir.as_str()) &&
-                name != Some("bin")
-
+            if let Some(name) = path.file_name().and_then(|s| s.to_str()) {
+                if name == builder.config.rust_codegen_backends_dir.as_str() {
+                    return false
+                }
+                if name == "bin" {
+                    return false
+                }
+                if name.contains("LLVM") {
+                    return false
+                }
+            }
+            true
         });
 
         let mut cmd = rust_installer(builder);
@@ -1268,6 +1278,90 @@
 }
 
 #[derive(Debug, PartialOrd, Ord, Copy, Clone, Hash, PartialEq, Eq)]
+pub struct Miri {
+    pub stage: u32,
+    pub target: Interned<String>,
+}
+
+impl Step for Miri {
+    type Output = Option<PathBuf>;
+    const ONLY_HOSTS: bool = true;
+
+    fn should_run(run: ShouldRun) -> ShouldRun {
+        run.path("miri")
+    }
+
+    fn make_run(run: RunConfig) {
+        run.builder.ensure(Miri {
+            stage: run.builder.top_stage,
+            target: run.target,
+        });
+    }
+
+    fn run(self, builder: &Builder) -> Option<PathBuf> {
+        let stage = self.stage;
+        let target = self.target;
+        assert!(builder.config.extended);
+
+        builder.info(&format!("Dist miri stage{} ({})", stage, target));
+        let src = builder.src.join("src/tools/miri");
+        let release_num = builder.release_num("miri");
+        let name = pkgname(builder, "miri");
+        let version = builder.miri_info.version(builder, &release_num);
+
+        let tmp = tmpdir(builder);
+        let image = tmp.join("miri-image");
+        drop(fs::remove_dir_all(&image));
+        builder.create_dir(&image);
+
+        // Prepare the image directory
+        // We expect miri to build, because we've exited this step above if tool
+        // state for miri isn't testing.
+        let miri = builder.ensure(tool::Miri {
+            compiler: builder.compiler(stage, builder.config.build),
+            target, extra_features: Vec::new()
+        }).or_else(|| { missing_tool("miri", builder.build.config.missing_tools); None })?;
+        let cargomiri = builder.ensure(tool::CargoMiri {
+            compiler: builder.compiler(stage, builder.config.build),
+            target, extra_features: Vec::new()
+        }).or_else(|| { missing_tool("cargo miri", builder.build.config.missing_tools); None })?;
+
+        builder.install(&miri, &image.join("bin"), 0o755);
+        builder.install(&cargomiri, &image.join("bin"), 0o755);
+        let doc = image.join("share/doc/miri");
+        builder.install(&src.join("README.md"), &doc, 0o644);
+        builder.install(&src.join("LICENSE-APACHE"), &doc, 0o644);
+        builder.install(&src.join("LICENSE-MIT"), &doc, 0o644);
+
+        // Prepare the overlay
+        let overlay = tmp.join("miri-overlay");
+        drop(fs::remove_dir_all(&overlay));
+        t!(fs::create_dir_all(&overlay));
+        builder.install(&src.join("README.md"), &overlay, 0o644);
+        builder.install(&src.join("LICENSE-APACHE"), &doc, 0o644);
+        builder.install(&src.join("LICENSE-MIT"), &doc, 0o644);
+        builder.create(&overlay.join("version"), &version);
+
+        // Generate the installer tarball
+        let mut cmd = rust_installer(builder);
+        cmd.arg("generate")
+           .arg("--product-name=Rust")
+           .arg("--rel-manifest-dir=rustlib")
+           .arg("--success-message=miri-ready-to-serve.")
+           .arg("--image-dir").arg(&image)
+           .arg("--work-dir").arg(&tmpdir(builder))
+           .arg("--output-dir").arg(&distdir(builder))
+           .arg("--non-installed-overlay").arg(&overlay)
+           .arg(format!("--package-name={}-{}", name, target))
+           .arg("--legacy-manifest-dirs=rustlib,cargo")
+           .arg("--component-name=miri-preview");
+
+        builder.run(&mut cmd);
+        Some(distdir(builder).join(format!("{}-{}.tar.gz", name, target)))
+    }
+}
+
+#[derive(Debug, PartialOrd, Ord, Copy, Clone, Hash, PartialEq, Eq)]
 pub struct Rustfmt {
     pub stage: u32,
     pub target: Interned<String>,
@@ -1388,6 +1482,7 @@
         let rls_installer = builder.ensure(Rls { stage, target });
         let llvm_tools_installer = builder.ensure(LlvmTools { stage, target });
         let clippy_installer = builder.ensure(Clippy { stage, target });
+        let miri_installer = builder.ensure(Miri { stage, target });
         let lldb_installer = builder.ensure(Lldb { target });
         let mingw_installer = builder.ensure(Mingw { host: target });
         let analysis_installer = builder.ensure(Analysis {
@@ -1426,6 +1521,7 @@
         tarballs.push(cargo_installer);
         tarballs.extend(rls_installer.clone());
         tarballs.extend(clippy_installer.clone());
+        tarballs.extend(miri_installer.clone());
         tarballs.extend(rustfmt_installer.clone());
         tarballs.extend(llvm_tools_installer);
         tarballs.extend(lldb_installer);
@@ -1498,6 +1594,9 @@
             if clippy_installer.is_none() {
                 contents = filter(&contents, "clippy");
             }
+            if miri_installer.is_none() {
+                contents = filter(&contents, "miri");
+            }
             if rustfmt_installer.is_none() {
                 contents = filter(&contents, "rustfmt");
             }
@@ -1538,6 +1637,9 @@
             if clippy_installer.is_some() {
                 prepare("clippy");
             }
+            if miri_installer.is_some() {
+                prepare("miri");
+            }
 
             // create an 'uninstall' package
             builder.install(&etc.join("pkg/postinstall"), &pkg.join("uninstall"), 0o755);
@@ -1568,6 +1670,8 @@
                     "rls-preview".to_string()
                 } else if name == "clippy" {
                     "clippy-preview".to_string()
+                } else if name == "miri" {
+                    "miri-preview".to_string()
                 } else {
                     name.to_string()
                 };
@@ -1587,6 +1691,9 @@
             if clippy_installer.is_some() {
                 prepare("clippy");
             }
+            if miri_installer.is_some() {
+                prepare("miri");
+            }
             if target.contains("windows-gnu") {
                 prepare("rust-mingw");
             }
@@ -1679,6 +1786,18 @@
                                 .arg("-out").arg(exe.join("ClippyGroup.wxs"))
                                 .arg("-t").arg(etc.join("msi/remove-duplicates.xsl")));
             }
+            if miri_installer.is_some() {
+                builder.run(Command::new(&heat)
+                                .current_dir(&exe)
+                                .arg("dir")
+                                .arg("miri")
+                                .args(&heat_flags)
+                                .arg("-cg").arg("MiriGroup")
+                                .arg("-dr").arg("Miri")
+                                .arg("-var").arg("var.MiriDir")
+                                .arg("-out").arg(exe.join("MiriGroup.wxs"))
+                                .arg("-t").arg(etc.join("msi/remove-duplicates.xsl")));
+            }
             builder.run(Command::new(&heat)
                             .current_dir(&exe)
                             .arg("dir")
@@ -1724,6 +1843,9 @@
                 if clippy_installer.is_some() {
                     cmd.arg("-dClippyDir=clippy");
                 }
+                if miri_installer.is_some() {
+                    cmd.arg("-dMiriDir=miri");
+                }
                 if target.contains("windows-gnu") {
                     cmd.arg("-dGccDir=rust-mingw");
                 }
@@ -1742,6 +1864,9 @@
             if clippy_installer.is_some() {
                 candle("ClippyGroup.wxs".as_ref());
             }
+            if miri_installer.is_some() {
+                candle("MiriGroup.wxs".as_ref());
+            }
             candle("AnalysisGroup.wxs".as_ref());
 
             if target.contains("windows-gnu") {
@@ -1774,6 +1899,9 @@
             if clippy_installer.is_some() {
                 cmd.arg("ClippyGroup.wixobj");
             }
+            if miri_installer.is_some() {
+                cmd.arg("MiriGroup.wixobj");
+            }
 
             if target.contains("windows-gnu") {
                 cmd.arg("GccGroup.wixobj");
@@ -1856,13 +1984,14 @@
         cmd.arg(distdir(builder));
         cmd.arg(today.trim());
         cmd.arg(builder.rust_package_vers());
+        cmd.arg(addr);
         cmd.arg(builder.package_vers(&builder.release_num("cargo")));
         cmd.arg(builder.package_vers(&builder.release_num("rls")));
         cmd.arg(builder.package_vers(&builder.release_num("clippy")));
+        cmd.arg(builder.package_vers(&builder.release_num("miri")));
         cmd.arg(builder.package_vers(&builder.release_num("rustfmt")));
         cmd.arg(builder.llvm_tools_package_vers());
         cmd.arg(builder.lldb_package_vers());
-        cmd.arg(addr);
 
         builder.create_dir(&distdir(builder));
 
@@ -1877,13 +2006,13 @@
 // LLVM tools are linked dynamically.
 // Note: This function does no yet support Windows but we also don't support
 //       linking LLVM tools dynamically on Windows yet.
-fn maybe_install_llvm_dylib(builder: &Builder,
-                            target: Interned<String>,
-                            image: &Path) {
+pub fn maybe_install_llvm_dylib(builder: &Builder,
+                                target: Interned<String>,
+                                sysroot: &Path) {
     let src_libdir = builder
         .llvm_out(target)
         .join("lib");
-    let dst_libdir = image.join("lib/rustlib").join(&*target).join("lib");
+    let dst_libdir = sysroot.join("lib/rustlib").join(&*target).join("lib");
     t!(fs::create_dir_all(&dst_libdir));
 
     if target.contains("apple-darwin") {
diff --git a/src/bootstrap/install.rs b/src/bootstrap/install.rs
index 669aae6..1265fa9 100644
--- a/src/bootstrap/install.rs
+++ b/src/bootstrap/install.rs
@@ -32,6 +32,9 @@
 pub fn install_clippy(builder: &Builder, stage: u32, host: Interned<String>) {
     install_sh(builder, "clippy", "clippy", stage, Some(host));
 }
+pub fn install_miri(builder: &Builder, stage: u32, host: Interned<String>) {
+    install_sh(builder, "miri", "miri", stage, Some(host));
+}
 
 pub fn install_rustfmt(builder: &Builder, stage: u32, host: Interned<String>) {
     install_sh(builder, "rustfmt", "rustfmt", stage, Some(host));
@@ -217,6 +220,14 @@
             builder.info(&format!("skipping Install clippy stage{} ({})", self.stage, self.target));
         }
     };
+    Miri, "miri", Self::should_build(_config), only_hosts: true, {
+        if builder.ensure(dist::Miri { stage: self.stage, target: self.target }).is_some() ||
+            Self::should_install(builder) {
+            install_miri(builder, self.stage, self.target);
+        } else {
+            builder.info(&format!("skipping Install miri stage{} ({})", self.stage, self.target));
+        }
+    };
     Rustfmt, "rustfmt", Self::should_build(_config), only_hosts: true, {
         if builder.ensure(dist::Rustfmt { stage: self.stage, target: self.target }).is_some() ||
             Self::should_install(builder) {
diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs
index e460ef5..bddc636 100644
--- a/src/bootstrap/lib.rs
+++ b/src/bootstrap/lib.rs
@@ -253,6 +253,7 @@
     cargo_info: channel::GitInfo,
     rls_info: channel::GitInfo,
     clippy_info: channel::GitInfo,
+    miri_info: channel::GitInfo,
     rustfmt_info: channel::GitInfo,
     local_rebuild: bool,
     fail_fast: bool,
@@ -374,6 +375,7 @@
         let cargo_info = channel::GitInfo::new(&config, &src.join("src/tools/cargo"));
         let rls_info = channel::GitInfo::new(&config, &src.join("src/tools/rls"));
         let clippy_info = channel::GitInfo::new(&config, &src.join("src/tools/clippy"));
+        let miri_info = channel::GitInfo::new(&config, &src.join("src/tools/miri"));
         let rustfmt_info = channel::GitInfo::new(&config, &src.join("src/tools/rustfmt"));
 
         let mut build = Build {
@@ -396,6 +398,7 @@
             cargo_info,
             rls_info,
             clippy_info,
+            miri_info,
             rustfmt_info,
             cc: HashMap::new(),
             cxx: HashMap::new(),
@@ -1016,6 +1019,11 @@
         self.package_vers(&self.release_num("clippy"))
     }
 
+    /// Returns the value of `package_vers` above for miri
+    fn miri_package_vers(&self) -> String {
+        self.package_vers(&self.release_num("miri"))
+    }
+
     /// Returns the value of `package_vers` above for rustfmt
     fn rustfmt_package_vers(&self) -> String {
         self.package_vers(&self.release_num("rustfmt"))
diff --git a/src/bootstrap/native.rs b/src/bootstrap/native.rs
index c548d7f..7ddfc38 100644
--- a/src/bootstrap/native.rs
+++ b/src/bootstrap/native.rs
@@ -235,7 +235,7 @@
             cfg.define("PYTHON_EXECUTABLE", python);
         }
 
-        configure_cmake(builder, target, &mut cfg, false);
+        configure_cmake(builder, target, &mut cfg);
 
         // FIXME: we don't actually need to build all LLVM tools and all LLVM
         //        libraries here, e.g., we just want a few components and a few
@@ -277,8 +277,7 @@
 
 fn configure_cmake(builder: &Builder,
                    target: Interned<String>,
-                   cfg: &mut cmake::Config,
-                   building_dist_binaries: bool) {
+                   cfg: &mut cmake::Config) {
     if builder.config.ninja {
         cfg.generator("Ninja");
     }
@@ -363,10 +362,11 @@
     cfg.build_arg("-j").build_arg(builder.jobs().to_string());
     cfg.define("CMAKE_C_FLAGS", builder.cflags(target, GitRepo::Llvm).join(" "));
     let mut cxxflags = builder.cflags(target, GitRepo::Llvm).join(" ");
-    if building_dist_binaries {
-        if builder.config.llvm_static_stdcpp && !target.contains("windows") {
-            cxxflags.push_str(" -static-libstdc++");
-        }
+    if builder.config.llvm_static_stdcpp &&
+        !target.contains("windows") &&
+        !target.contains("netbsd")
+    {
+        cxxflags.push_str(" -static-libstdc++");
     }
     cfg.define("CMAKE_CXX_FLAGS", cxxflags);
     if let Some(ar) = builder.ar(target) {
@@ -431,7 +431,7 @@
         t!(fs::create_dir_all(&out_dir));
 
         let mut cfg = cmake::Config::new(builder.src.join("src/tools/lld"));
-        configure_cmake(builder, target, &mut cfg, true);
+        configure_cmake(builder, target, &mut cfg);
 
         // This is an awful, awful hack. Discovered when we migrated to using
         // clang-cl to compile LLVM/LLD it turns out that LLD, when built out of
diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs
index 7782351..9f6db73 100644
--- a/src/bootstrap/tool.rs
+++ b/src/bootstrap/tool.rs
@@ -77,12 +77,13 @@
         let _folder = builder.fold_output(|| format!("stage{}-{}", compiler.stage, tool));
         builder.info(&format!("Building stage{} tool {} ({})", compiler.stage, tool, target));
         let mut duplicates = Vec::new();
-        let is_expected = compile::stream_cargo(builder, &mut cargo, vec![], &mut |msg| {
+        let is_expected = compile::stream_cargo(builder, &mut cargo, &mut |msg| {
             // Only care about big things like the RLS/Cargo for now
             match tool {
                 | "rls"
                 | "cargo"
                 | "clippy-driver"
+                | "miri"
                 => {}
 
                 _ => return,
@@ -218,6 +219,7 @@
         if path.ends_with("cargo") ||
             path.ends_with("rls") ||
             path.ends_with("clippy") ||
+            path.ends_with("miri") ||
             path.ends_with("rustfmt")
         {
             cargo.env("LIBZ_SYS_STATIC", "1");
@@ -592,6 +594,14 @@
         });
     };
     Miri, miri, "src/tools/miri", "miri", {};
+    CargoMiri, miri, "src/tools/miri", "cargo-miri", {
+        // Miri depends on procedural macros (serde), which requires a full host
+        // compiler to be available, so we need to depend on that.
+        builder.ensure(compile::Rustc {
+            compiler: self.compiler,
+            target: builder.config.build,
+        });
+    };
     Rls, rls, "src/tools/rls", "rls", {
         let clippy = builder.ensure(Clippy {
             compiler: self.compiler,
diff --git a/src/doc/rustc/src/lints/listing/warn-by-default.md b/src/doc/rustc/src/lints/listing/warn-by-default.md
index b01aed0..7fbbe68 100644
--- a/src/doc/rustc/src/lints/listing/warn-by-default.md
+++ b/src/doc/rustc/src/lints/listing/warn-by-default.md
@@ -24,7 +24,7 @@
 
 ## dead-code
 
-This lint detects detect unused, unexported items. Some
+This lint detects unused, unexported items. Some
 example code that triggers this lint:
 
 ```rust
@@ -44,7 +44,7 @@
 
 ## deprecated
 
-This lint detects detects use of deprecated items. Some
+This lint detects use of deprecated items. Some
 example code that triggers this lint:
 
 ```rust
@@ -119,7 +119,7 @@
 
 ## late-bound-lifetime-arguments
 
-This lint detects detects generic lifetime arguments in path segments with
+This lint detects generic lifetime arguments in path segments with
 late bound lifetime parameters. Some example code that triggers this lint:
 
 ```rust
@@ -381,7 +381,7 @@
 
 ## private-in-public
 
-This lint detects detect private items in public interfaces not caught by the old implementation. Some
+This lint detects private items in public interfaces not caught by the old implementation. Some
 example code that triggers this lint:
 
 ```rust,ignore
@@ -659,7 +659,7 @@
 
 ## unreachable-code
 
-This lint detects detects unreachable code paths. Some example code that
+This lint detects unreachable code paths. Some example code that
 triggers this lint:
 
 ```rust,no_run
@@ -681,7 +681,7 @@
 
 ## unreachable-patterns
 
-This lint detects detects unreachable patterns. Some
+This lint detects unreachable patterns. Some
 example code that triggers this lint:
 
 ```rust
@@ -716,11 +716,11 @@
 
 ## unused-allocation
 
-This lint detects detects unnecessary allocations that can be eliminated.
+This lint detects unnecessary allocations that can be eliminated.
 
 ## unused-assignments
 
-This lint detects detect assignments that will never be read. Some
+This lint detects assignments that will never be read. Some
 example code that triggers this lint:
 
 ```rust
@@ -741,7 +741,7 @@
 
 ## unused-attributes
 
-This lint detects detects attributes that were not used by the compiler. Some
+This lint detects attributes that were not used by the compiler. Some
 example code that triggers this lint:
 
 ```rust
@@ -785,7 +785,7 @@
 
 ## unused-doc-comment
 
-This lint detects detects doc comments that aren't used by rustdoc. Some
+This lint detects doc comments that aren't used by rustdoc. Some
 example code that triggers this lint:
 
 ```rust
@@ -831,7 +831,7 @@
 
 ## unused-macros
 
-This lint detects detects macros that were not used. Some example code that
+This lint detects macros that were not used. Some example code that
 triggers this lint:
 
 ```rust
@@ -884,7 +884,7 @@
 
 ## unused-mut
 
-This lint detects detect mut variables which don't need to be mutable. Some
+This lint detects mut variables which don't need to be mutable. Some
 example code that triggers this lint:
 
 ```rust
@@ -946,7 +946,7 @@
 
 ## unused-variables
 
-This lint detects detect variables which are not used in any way. Some
+This lint detects variables which are not used in any way. Some
 example code that triggers this lint:
 
 ```rust
diff --git a/src/doc/rustdoc/src/documentation-tests.md b/src/doc/rustdoc/src/documentation-tests.md
index dd8dcb7..dcc13f5 100644
--- a/src/doc/rustdoc/src/documentation-tests.md
+++ b/src/doc/rustdoc/src/documentation-tests.md
@@ -171,7 +171,7 @@
 explanation.
 
 The `#`-hiding of lines can be prevented by using two consecutive hashes
-`##`. This only needs to be done with with the first `#` which would've
+`##`. This only needs to be done with the first `#` which would've
 otherwise caused hiding. If we have a string literal like the following,
 which has a line that starts with a `#`:
 
diff --git a/src/doc/unstable-book/src/language-features/cfg-attr-multi.md b/src/doc/unstable-book/src/language-features/cfg-attr-multi.md
deleted file mode 100644
index 6365d3e..0000000
--- a/src/doc/unstable-book/src/language-features/cfg-attr-multi.md
+++ /dev/null
@@ -1,20 +0,0 @@
-# `cfg_attr_multi`
-
-The tracking issue for this feature is: [#54881]
-The RFC for this feature is: [#2539]
-
-[#54881]: https://github.com/rust-lang/rust/issues/54881
-[#2539]: https://github.com/rust-lang/rfcs/pull/2539
-
-------------------------
-
-This feature flag lets you put multiple attributes into a `cfg_attr` attribute.
-
-Example:
-
-```rust,ignore
-#[cfg_attr(all(), must_use, optimize)]
-```
-
-Because `cfg_attr` resolves before procedural macros, this does not affect
-macro resolution at all.
\ No newline at end of file
diff --git a/src/etc/generate-keyword-tests.py b/src/etc/generate-keyword-tests.py
index 99d11c8..9936ce7 100755
--- a/src/etc/generate-keyword-tests.py
+++ b/src/etc/generate-keyword-tests.py
@@ -16,8 +16,6 @@
 
 
 template = """
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py %s'
 
 fn main() {
diff --git a/src/etc/htmldocck.py b/src/etc/htmldocck.py
index ef41e42..e8be2b9 100644
--- a/src/etc/htmldocck.py
+++ b/src/etc/htmldocck.py
@@ -1,3 +1,6 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
 r"""
 htmldocck.py is a custom checker script for Rustdoc HTML outputs.
 
@@ -98,7 +101,10 @@
 
 """
 
-from __future__ import print_function
+from __future__ import absolute_import, print_function, unicode_literals
+
+import codecs
+import io
 import sys
 import os.path
 import re
@@ -110,14 +116,10 @@
     from HTMLParser import HTMLParser
 from xml.etree import cElementTree as ET
 
-# &larrb;/&rarrb; are not in HTML 4 but are in HTML 5
 try:
-    from html.entities import entitydefs
+    from html.entities import name2codepoint
 except ImportError:
-    from htmlentitydefs import entitydefs
-entitydefs['larrb'] = u'\u21e4'
-entitydefs['rarrb'] = u'\u21e5'
-entitydefs['nbsp'] = ' '
+    from htmlentitydefs import name2codepoint
 
 # "void elements" (no closing tag) from the HTML Standard section 12.1.2
 VOID_ELEMENTS = set(['area', 'base', 'br', 'col', 'embed', 'hr', 'img', 'input', 'keygen',
@@ -157,11 +159,11 @@
         self.__builder.data(data)
 
     def handle_entityref(self, name):
-        self.__builder.data(entitydefs[name])
+        self.__builder.data(unichr(name2codepoint[name]))
 
     def handle_charref(self, name):
         code = int(name[1:], 16) if name.startswith(('x', 'X')) else int(name, 10)
-        self.__builder.data(unichr(code).encode('utf-8'))
+        self.__builder.data(unichr(code))
 
     def close(self):
         HTMLParser.close(self)
@@ -210,11 +212,11 @@
     (?<=(?<!\S)@)(?P<negated>!?)
     (?P<cmd>[A-Za-z]+(?:-[A-Za-z]+)*)
     (?P<args>.*)$
-''', re.X)
+''', re.X | re.UNICODE)
 
 
 def get_commands(template):
-    with open(template, 'rU') as f:
+    with io.open(template, encoding='utf-8') as f:
         for lineno, line in concat_multi_lines(f):
             m = LINE_PATTERN.search(line)
             if not m:
@@ -226,7 +228,10 @@
             if args and not args[:1].isspace():
                 print_err(lineno, line, 'Invalid template syntax')
                 continue
-            args = shlex.split(args)
+            try:
+                args = shlex.split(args)
+            except UnicodeEncodeError:
+                args = [arg.decode('utf-8') for arg in shlex.split(args.encode('utf-8'))]
             yield Command(negated=negated, cmd=cmd, args=args, lineno=lineno+1, context=line)
 
 
@@ -280,7 +285,7 @@
         if not(os.path.exists(abspath) and os.path.isfile(abspath)):
             raise FailedCheck('File does not exist {!r}'.format(path))
 
-        with open(abspath) as f:
+        with io.open(abspath, encoding='utf-8') as f:
             data = f.read()
             self.files[path] = data
             return data
@@ -294,9 +299,9 @@
         if not(os.path.exists(abspath) and os.path.isfile(abspath)):
             raise FailedCheck('File does not exist {!r}'.format(path))
 
-        with open(abspath) as f:
+        with io.open(abspath, encoding='utf-8') as f:
             try:
-                tree = ET.parse(f, CustomHTMLParser())
+                tree = ET.fromstringlist(f.readlines(), CustomHTMLParser())
             except Exception as e:
                 raise RuntimeError('Cannot parse an HTML file {!r}: {}'.format(path, e))
             self.trees[path] = tree
@@ -313,7 +318,7 @@
     if not pat:
         return True # special case a presence testing
     elif regexp:
-        return re.search(pat, data) is not None
+        return re.search(pat, data, flags=re.UNICODE) is not None
     else:
         data = ' '.join(data.split())
         pat = ' '.join(pat.split())
@@ -350,7 +355,7 @@
                     break
     except Exception as e:
         print('Failed to get path "{}"'.format(path))
-        raise e
+        raise
     return ret
 
 
@@ -359,7 +364,12 @@
     return len(tree.findall(path))
 
 def stderr(*args):
-    print(*args, file=sys.stderr)
+    if sys.version_info.major < 3:
+        file = codecs.getwriter('utf-8')(sys.stderr)
+    else:
+        file = sys.stderr
+
+    print(*args, file=file)
 
 def print_err(lineno, context, err, message=None):
     global ERR_COUNT
diff --git a/src/liballoc/boxed.rs b/src/liballoc/boxed.rs
index fbd0b94..1c459f5 100644
--- a/src/liballoc/boxed.rs
+++ b/src/liballoc/boxed.rs
@@ -257,6 +257,19 @@
     {
         unsafe { &mut *Box::into_raw(b) }
     }
+
+    /// Converts a `Box<T>` into a `Pin<Box<T>>`
+    ///
+    /// This conversion does not allocate on the heap and happens in place.
+    ///
+    /// This is also available via [`From`].
+    #[unstable(feature = "box_into_pin", issue = "0")]
+    pub fn into_pin(boxed: Box<T>) -> Pin<Box<T>> {
+        // It's not possible to move or replace the insides of a `Pin<Box<T>>`
+        // when `T: !Unpin`,  so it's safe to pin it directly without any
+        // additional requirements.
+        unsafe { Pin::new_unchecked(boxed) }
+    }
 }
 
 #[stable(feature = "rust1", since = "1.0.0")]
@@ -451,15 +464,12 @@
 }
 
 #[stable(feature = "pin", since = "1.33.0")]
-impl<T> From<Box<T>> for Pin<Box<T>> {
+impl<T: ?Sized> From<Box<T>> for Pin<Box<T>> {
     /// Converts a `Box<T>` into a `Pin<Box<T>>`
     ///
     /// This conversion does not allocate on the heap and happens in place.
     fn from(boxed: Box<T>) -> Self {
-        // It's not possible to move or replace the insides of a `Pin<Box<T>>`
-        // when `T: !Unpin`,  so it's safe to pin it directly without any
-        // additional requirements.
-        unsafe { Pin::new_unchecked(boxed) }
+        Box::into_pin(boxed)
     }
 }
 
diff --git a/src/libcore/ffi.rs b/src/libcore/ffi.rs
index 899fae9..0717a88 100644
--- a/src/libcore/ffi.rs
+++ b/src/libcore/ffi.rs
@@ -186,7 +186,7 @@
                reason = "the `c_variadic` feature has not been properly tested on \
                          all supported platforms",
                issue = "27745")]
-    pub unsafe fn copy<F, R>(&mut self, f: F) -> R
+    pub unsafe fn copy<F, R>(&self, f: F) -> R
             where F: for<'copy> FnOnce(VaList<'copy>) -> R {
         #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"),
                       not(target_arch = "x86_64")),
diff --git a/src/libcore/intrinsics.rs b/src/libcore/intrinsics.rs
index 7508257..4f5310f 100644
--- a/src/libcore/intrinsics.rs
+++ b/src/libcore/intrinsics.rs
@@ -690,6 +690,11 @@
     /// crate it is invoked in.
     pub fn type_id<T: ?Sized + 'static>() -> u64;
 
+    /// A guard for unsafe functions that cannot ever be executed if `T` is uninhabited:
+    /// This will statically either panic, or do nothing.
+    #[cfg(not(stage0))]
+    pub fn panic_if_uninhabited<T>();
+
     /// Creates a value initialized to zero.
     ///
     /// `init` is unsafe because it returns a zeroed-out datum,
diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs
index 5ea765d..b2cafc4 100644
--- a/src/libcore/lib.rs
+++ b/src/libcore/lib.rs
@@ -110,6 +110,7 @@
 #![feature(aarch64_target_feature)]
 #![feature(wasm_target_feature)]
 #![feature(avx512_target_feature)]
+#![cfg_attr(not(stage0), feature(cmpxchg16b_target_feature))]
 #![feature(const_slice_len)]
 #![feature(const_str_as_bytes)]
 #![feature(const_str_len)]
@@ -121,6 +122,8 @@
 #![feature(reverse_bits)]
 #![feature(non_exhaustive)]
 #![feature(structural_match)]
+#![feature(abi_unadjusted)]
+#![cfg_attr(not(stage0), feature(adx_target_feature))]
 
 #[prelude_import]
 #[allow(unused)]
diff --git a/src/libcore/marker.rs b/src/libcore/marker.rs
index 53af924..65752ba 100644
--- a/src/libcore/marker.rs
+++ b/src/libcore/marker.rs
@@ -85,7 +85,7 @@
     on(parent_trait="std::path::Path", label="borrow the `Path` instead"),
     message="the size for values of type `{Self}` cannot be known at compilation time",
     label="doesn't have a size known at compile-time",
-    note="to learn more, visit <https://doc.rust-lang.org/book/second-edition/\
+    note="to learn more, visit <https://doc.rust-lang.org/book/\
           ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>",
 )]
 #[fundamental] // for Default, for example, which requires that `[T]: !Default` be evaluatable
diff --git a/src/libcore/mem.rs b/src/libcore/mem.rs
index c024868..8fcbb73 100644
--- a/src/libcore/mem.rs
+++ b/src/libcore/mem.rs
@@ -492,6 +492,8 @@
 #[rustc_deprecated(since = "2.0.0", reason = "use `mem::MaybeUninit::zeroed` instead")]
 #[stable(feature = "rust1", since = "1.0.0")]
 pub unsafe fn zeroed<T>() -> T {
+    #[cfg(not(stage0))]
+    intrinsics::panic_if_uninhabited::<T>();
     intrinsics::init()
 }
 
@@ -624,6 +626,8 @@
 #[rustc_deprecated(since = "2.0.0", reason = "use `mem::MaybeUninit::uninitialized` instead")]
 #[stable(feature = "rust1", since = "1.0.0")]
 pub unsafe fn uninitialized<T>() -> T {
+    #[cfg(not(stage0))]
+    intrinsics::panic_if_uninhabited::<T>();
     intrinsics::uninit()
 }
 
@@ -1128,6 +1132,8 @@
     #[unstable(feature = "maybe_uninit", issue = "53491")]
     #[inline(always)]
     pub unsafe fn into_inner(self) -> T {
+        #[cfg(not(stage0))]
+        intrinsics::panic_if_uninhabited::<T>();
         ManuallyDrop::into_inner(self.value)
     }
 
diff --git a/src/libcore/ops/deref.rs b/src/libcore/ops/deref.rs
index f2187bd..075c3a0 100644
--- a/src/libcore/ops/deref.rs
+++ b/src/libcore/ops/deref.rs
@@ -27,7 +27,7 @@
 /// [book] as well as the reference sections on [the dereference operator]
 /// [ref-deref-op], [method resolution] and [type coercions].
 ///
-/// [book]: ../../book/second-edition/ch15-02-deref.html
+/// [book]: ../../book/ch15-02-deref.html
 /// [`DerefMut`]: trait.DerefMut.html
 /// [more]: #more-on-deref-coercion
 /// [ref-deref-op]: ../../reference/expressions/operator-expr.html#the-dereference-operator
@@ -117,7 +117,7 @@
 /// [book] as well as the reference sections on [the dereference operator]
 /// [ref-deref-op], [method resolution] and [type coercions].
 ///
-/// [book]: ../../book/second-edition/ch15-02-deref.html
+/// [book]: ../../book/ch15-02-deref.html
 /// [`Deref`]: trait.Deref.html
 /// [more]: #more-on-deref-coercion
 /// [ref-deref-op]: ../../reference/expressions/operator-expr.html#the-dereference-operator
diff --git a/src/libcore/ops/drop.rs b/src/libcore/ops/drop.rs
index 8d16fde..eae63ea 100644
--- a/src/libcore/ops/drop.rs
+++ b/src/libcore/ops/drop.rs
@@ -11,7 +11,7 @@
 /// Refer to [the chapter on `Drop` in *The Rust Programming Language*][book]
 /// for some more elaboration.
 ///
-/// [book]: ../../book/second-edition/ch15-03-drop.html
+/// [book]: ../../book/ch15-03-drop.html
 ///
 /// # Examples
 ///
diff --git a/src/libcore/ops/function.rs b/src/libcore/ops/function.rs
index ec2e534..3a1d765 100644
--- a/src/libcore/ops/function.rs
+++ b/src/libcore/ops/function.rs
@@ -27,7 +27,7 @@
 /// `Fn(usize, bool) -> usize`). Those interested in the technical details of
 /// this can refer to [the relevant section in the *Rustonomicon*][nomicon].
 ///
-/// [book]: ../../book/second-edition/ch13-01-closures.html
+/// [book]: ../../book/ch13-01-closures.html
 /// [`FnMut`]: trait.FnMut.html
 /// [`FnOnce`]: trait.FnOnce.html
 /// [function pointers]: ../../std/primitive.fn.html
@@ -95,7 +95,7 @@
 /// `Fn(usize, bool) -> usize`). Those interested in the technical details of
 /// this can refer to [the relevant section in the *Rustonomicon*][nomicon].
 ///
-/// [book]: ../../book/second-edition/ch13-01-closures.html
+/// [book]: ../../book/ch13-01-closures.html
 /// [`Fn`]: trait.Fn.html
 /// [`FnOnce`]: trait.FnOnce.html
 /// [function pointers]: ../../std/primitive.fn.html
@@ -173,7 +173,7 @@
 /// `Fn(usize, bool) -> usize`). Those interested in the technical details of
 /// this can refer to [the relevant section in the *Rustonomicon*][nomicon].
 ///
-/// [book]: ../../book/second-edition/ch13-01-closures.html
+/// [book]: ../../book/ch13-01-closures.html
 /// [`Fn`]: trait.Fn.html
 /// [`FnMut`]: trait.FnMut.html
 /// [function pointers]: ../../std/primitive.fn.html
diff --git a/src/libcore/pin.rs b/src/libcore/pin.rs
index e31ac69..762e075 100644
--- a/src/libcore/pin.rs
+++ b/src/libcore/pin.rs
@@ -175,11 +175,11 @@
     /// Assign a new value to the memory behind the pinned reference.
     #[stable(feature = "pin", since = "1.33.0")]
     #[inline(always)]
-    pub fn set(mut self: Pin<P>, value: P::Target)
+    pub fn set(self: &mut Pin<P>, value: P::Target)
     where
         P::Target: Sized,
     {
-        *self.pointer = value;
+        *(self.pointer) = value;
     }
 }
 
diff --git a/src/libcore/time.rs b/src/libcore/time.rs
index b12ee04..a751965 100644
--- a/src/libcore/time.rs
+++ b/src/libcore/time.rs
@@ -23,6 +23,22 @@
 const MICROS_PER_SEC: u64 = 1_000_000;
 const MAX_NANOS_F64: f64 = ((u64::MAX as u128 + 1)*(NANOS_PER_SEC as u128)) as f64;
 
+/// The duration of one second.
+#[unstable(feature = "duration_constants", issue = "57391")]
+pub const SECOND: Duration = Duration::from_secs(1);
+
+/// The duration of one millisecond.
+#[unstable(feature = "duration_constants", issue = "57391")]
+pub const MILLISECOND: Duration = Duration::from_millis(1);
+
+/// The duration of one microsecond.
+#[unstable(feature = "duration_constants", issue = "57391")]
+pub const MICROSECOND: Duration = Duration::from_micros(1);
+
+/// The duration of one nanosecond.
+#[unstable(feature = "duration_constants", issue = "57391")]
+pub const NANOSECOND: Duration = Duration::from_nanos(1);
+
 /// A `Duration` type to represent a span of time, typically used for system
 /// timeouts.
 ///
diff --git a/src/librustc/dep_graph/graph.rs b/src/librustc/dep_graph/graph.rs
index 9616381..71cacfe 100644
--- a/src/librustc/dep_graph/graph.rs
+++ b/src/librustc/dep_graph/graph.rs
@@ -122,12 +122,7 @@
         if let Some(..) = self.data {
             ty::tls::with_context_opt(|icx| {
                 let icx = if let Some(icx) = icx { icx } else { return };
-                match *icx.task {
-                    OpenTask::Ignore => {
-                        // ignored
-                    }
-                    _ => panic!("expected an ignore context")
-                }
+                assert!(icx.task_deps.is_none(), "expected no task dependency tracking");
             })
         }
     }
@@ -137,7 +132,7 @@
     {
         ty::tls::with_context(|icx| {
             let icx = ty::tls::ImplicitCtxt {
-                task: &OpenTask::Ignore,
+                task_deps: None,
                 ..icx.clone()
             };
 
@@ -184,12 +179,15 @@
               R: HashStable<StableHashingContext<'gcx>>,
     {
         self.with_task_impl(key, cx, arg, false, task,
-            |key| OpenTask::Regular(Lock::new(RegularOpenTask {
-                node: key,
+            |_key| Some(TaskDeps {
+                #[cfg(debug_assertions)]
+                node: Some(_key),
                 reads: SmallVec::new(),
                 read_set: Default::default(),
-            })),
-            |data, key, fingerprint, task| data.borrow_mut().complete_task(key, task, fingerprint))
+            }),
+            |data, key, fingerprint, task| {
+                data.borrow_mut().complete_task(key, task.unwrap(), fingerprint)
+            })
     }
 
     /// Creates a new dep-graph input with value `input`
@@ -206,7 +204,7 @@
         }
 
         self.with_task_impl(key, cx, input, true, identity_fn,
-            |_| OpenTask::Ignore,
+            |_| None,
             |data, key, fingerprint, _| {
                 data.borrow_mut().alloc_node(key, SmallVec::new(), fingerprint)
             })
@@ -219,18 +217,18 @@
         arg: A,
         no_tcx: bool,
         task: fn(C, A) -> R,
-        create_task: fn(DepNode) -> OpenTask,
+        create_task: fn(DepNode) -> Option<TaskDeps>,
         finish_task_and_alloc_depnode: fn(&Lock<CurrentDepGraph>,
                                           DepNode,
                                           Fingerprint,
-                                          OpenTask) -> DepNodeIndex
+                                          Option<TaskDeps>) -> DepNodeIndex
     ) -> (R, DepNodeIndex)
     where
         C: DepGraphSafe + StableHashingContextProvider<'gcx>,
         R: HashStable<StableHashingContext<'gcx>>,
     {
         if let Some(ref data) = self.data {
-            let open_task = create_task(key);
+            let task_deps = create_task(key).map(|deps| Lock::new(deps));
 
             // In incremental mode, hash the result of the task. We don't
             // do anything with the hash yet, but we are computing it
@@ -248,7 +246,7 @@
             } else {
                 ty::tls::with_context(|icx| {
                     let icx = ty::tls::ImplicitCtxt {
-                        task: &open_task,
+                        task_deps: task_deps.as_ref(),
                         ..icx.clone()
                     };
 
@@ -271,7 +269,7 @@
                 &data.current,
                 key,
                 current_fingerprint,
-                open_task
+                task_deps.map(|lock| lock.into_inner()),
             );
 
             // Determine the color of the new DepNode.
@@ -304,15 +302,17 @@
         where OP: FnOnce() -> R
     {
         if let Some(ref data) = self.data {
-            let (result, open_task) = ty::tls::with_context(|icx| {
-                let task = OpenTask::Anon(Lock::new(AnonOpenTask {
+            let (result, task_deps) = ty::tls::with_context(|icx| {
+                let task_deps = Lock::new(TaskDeps {
+                    #[cfg(debug_assertions)]
+                    node: None,
                     reads: SmallVec::new(),
                     read_set: Default::default(),
-                }));
+                });
 
                 let r = {
                     let icx = ty::tls::ImplicitCtxt {
-                        task: &task,
+                        task_deps: Some(&task_deps),
                         ..icx.clone()
                     };
 
@@ -321,11 +321,11 @@
                     })
                 };
 
-                (r, task)
+                (r, task_deps.into_inner())
             });
             let dep_node_index = data.current
                                      .borrow_mut()
-                                     .pop_anon_task(dep_kind, open_task);
+                                     .complete_anon_task(dep_kind, task_deps);
             (result, dep_node_index)
         } else {
             (op(), DepNodeIndex::INVALID)
@@ -344,18 +344,23 @@
               R: HashStable<StableHashingContext<'gcx>>,
     {
         self.with_task_impl(key, cx, arg, false, task,
-            |key| OpenTask::EvalAlways { node: key },
-            |data, key, fingerprint, task| {
-                data.borrow_mut().complete_eval_always_task(key, task, fingerprint)
+            |_| None,
+            |data, key, fingerprint, _| {
+                let mut current = data.borrow_mut();
+                let krate_idx = current.node_to_node_index[
+                    &DepNode::new_no_params(DepKind::Krate)
+                ];
+                current.alloc_node(key, smallvec![krate_idx], fingerprint)
             })
     }
 
     #[inline]
     pub fn read(&self, v: DepNode) {
         if let Some(ref data) = self.data {
-            let mut current = data.current.borrow_mut();
+            let current = data.current.borrow_mut();
             if let Some(&dep_node_index) = current.node_to_node_index.get(&v) {
-                current.read_index(dep_node_index);
+                std::mem::drop(current);
+                data.read_index(dep_node_index);
             } else {
                 bug!("DepKind {:?} should be pre-allocated but isn't.", v.kind)
             }
@@ -365,7 +370,7 @@
     #[inline]
     pub fn read_index(&self, dep_node_index: DepNodeIndex) {
         if let Some(ref data) = self.data {
-            data.current.borrow_mut().read_index(dep_node_index);
+            data.read_index(dep_node_index);
         }
     }
 
@@ -446,10 +451,15 @@
             .cloned()
     }
 
-    pub fn edge_deduplication_data(&self) -> (u64, u64) {
-        let current_dep_graph = self.data.as_ref().unwrap().current.borrow();
+    pub fn edge_deduplication_data(&self) -> Option<(u64, u64)> {
+        if cfg!(debug_assertions) {
+            let current_dep_graph = self.data.as_ref().unwrap().current.borrow();
 
-        (current_dep_graph.total_read_count, current_dep_graph.total_duplicate_read_count)
+            Some((current_dep_graph.total_read_count,
+                  current_dep_graph.total_duplicate_read_count))
+        } else {
+            None
+        }
     }
 
     pub fn serialize(&self) -> SerializedDepGraph {
@@ -827,6 +837,7 @@
 pub(super) struct CurrentDepGraph {
     data: IndexVec<DepNodeIndex, DepNodeData>,
     node_to_node_index: FxHashMap<DepNode, DepNodeIndex>,
+    #[allow(dead_code)]
     forbidden_edge: Option<EdgeFilter>,
 
     // Anonymous DepNodes are nodes the ID of which we compute from the list of
@@ -890,134 +901,60 @@
 
     fn complete_task(
         &mut self,
-        key: DepNode,
-        task: OpenTask,
+        node: DepNode,
+        task_deps: TaskDeps,
         fingerprint: Fingerprint
     ) -> DepNodeIndex {
-        if let OpenTask::Regular(task) = task {
-            let RegularOpenTask {
-                node,
-                read_set: _,
-                reads
-            } = task.into_inner();
-            assert_eq!(node, key);
-
-            // If this is an input node, we expect that it either has no
-            // dependencies, or that it just depends on DepKind::CrateMetadata
-            // or DepKind::Krate. This happens for some "thin wrapper queries"
-            // like `crate_disambiguator` which sometimes have zero deps (for
-            // when called for LOCAL_CRATE) or they depend on a CrateMetadata
-            // node.
-            if cfg!(debug_assertions) {
-                if node.kind.is_input() && reads.len() > 0 &&
-                   // FIXME(mw): Special case for DefSpan until Spans are handled
-                   //            better in general.
-                   node.kind != DepKind::DefSpan &&
-                    reads.iter().any(|&i| {
-                        !(self.data[i].node.kind == DepKind::CrateMetadata ||
-                          self.data[i].node.kind == DepKind::Krate)
-                    })
-                {
-                    bug!("Input node {:?} with unexpected reads: {:?}",
-                        node,
-                        reads.iter().map(|&i| self.data[i].node).collect::<Vec<_>>())
-                }
+        // If this is an input node, we expect that it either has no
+        // dependencies, or that it just depends on DepKind::CrateMetadata
+        // or DepKind::Krate. This happens for some "thin wrapper queries"
+        // like `crate_disambiguator` which sometimes have zero deps (for
+        // when called for LOCAL_CRATE) or they depend on a CrateMetadata
+        // node.
+        if cfg!(debug_assertions) {
+            if node.kind.is_input() && task_deps.reads.len() > 0 &&
+                // FIXME(mw): Special case for DefSpan until Spans are handled
+                //            better in general.
+                node.kind != DepKind::DefSpan &&
+                task_deps.reads.iter().any(|&i| {
+                    !(self.data[i].node.kind == DepKind::CrateMetadata ||
+                        self.data[i].node.kind == DepKind::Krate)
+                })
+            {
+                bug!("Input node {:?} with unexpected reads: {:?}",
+                    node,
+                    task_deps.reads.iter().map(|&i| self.data[i].node).collect::<Vec<_>>())
             }
-
-            self.alloc_node(node, reads, fingerprint)
-        } else {
-            bug!("complete_task() - Expected regular task to be popped")
         }
+
+        self.alloc_node(node, task_deps.reads, fingerprint)
     }
 
-    fn pop_anon_task(&mut self, kind: DepKind, task: OpenTask) -> DepNodeIndex {
-        if let OpenTask::Anon(task) = task {
-            let AnonOpenTask {
-                read_set: _,
-                reads
-            } = task.into_inner();
-            debug_assert!(!kind.is_input());
+    fn complete_anon_task(&mut self, kind: DepKind, task_deps: TaskDeps) -> DepNodeIndex {
+        debug_assert!(!kind.is_input());
 
-            let mut fingerprint = self.anon_id_seed;
-            let mut hasher = StableHasher::new();
+        let mut fingerprint = self.anon_id_seed;
+        let mut hasher = StableHasher::new();
 
-            for &read in reads.iter() {
-                let read_dep_node = self.data[read].node;
+        for &read in task_deps.reads.iter() {
+            let read_dep_node = self.data[read].node;
 
-                ::std::mem::discriminant(&read_dep_node.kind).hash(&mut hasher);
+            ::std::mem::discriminant(&read_dep_node.kind).hash(&mut hasher);
 
-                // Fingerprint::combine() is faster than sending Fingerprint
-                // through the StableHasher (at least as long as StableHasher
-                // is so slow).
-                fingerprint = fingerprint.combine(read_dep_node.hash);
-            }
-
-            fingerprint = fingerprint.combine(hasher.finish());
-
-            let target_dep_node = DepNode {
-                kind,
-                hash: fingerprint,
-            };
-
-            self.intern_node(target_dep_node, reads, Fingerprint::ZERO).0
-        } else {
-            bug!("pop_anon_task() - Expected anonymous task to be popped")
+            // Fingerprint::combine() is faster than sending Fingerprint
+            // through the StableHasher (at least as long as StableHasher
+            // is so slow).
+            fingerprint = fingerprint.combine(read_dep_node.hash);
         }
-    }
 
-    fn complete_eval_always_task(
-        &mut self,
-        key: DepNode,
-        task: OpenTask,
-        fingerprint: Fingerprint
-    ) -> DepNodeIndex {
-        if let OpenTask::EvalAlways {
-            node,
-        } = task {
-            debug_assert_eq!(node, key);
-            let krate_idx = self.node_to_node_index[&DepNode::new_no_params(DepKind::Krate)];
-            self.alloc_node(node, smallvec![krate_idx], fingerprint)
-        } else {
-            bug!("complete_eval_always_task() - Expected eval always task to be popped");
-        }
-    }
+        fingerprint = fingerprint.combine(hasher.finish());
 
-    fn read_index(&mut self, source: DepNodeIndex) {
-        ty::tls::with_context_opt(|icx| {
-            let icx = if let Some(icx) = icx { icx } else { return };
-            match *icx.task {
-                OpenTask::Regular(ref task) => {
-                    let mut task = task.lock();
-                    self.total_read_count += 1;
-                    if task.read_set.insert(source) {
-                        task.reads.push(source);
+        let target_dep_node = DepNode {
+            kind,
+            hash: fingerprint,
+        };
 
-                        if cfg!(debug_assertions) {
-                            if let Some(ref forbidden_edge) = self.forbidden_edge {
-                                let target = &task.node;
-                                let source = self.data[source].node;
-                                if forbidden_edge.test(&source, &target) {
-                                    bug!("forbidden edge {:?} -> {:?} created",
-                                        source,
-                                        target)
-                                }
-                            }
-                        }
-                    } else {
-                        self.total_duplicate_read_count += 1;
-                    }
-                }
-                OpenTask::Anon(ref task) => {
-                    let mut task = task.lock();
-                    if task.read_set.insert(source) {
-                        task.reads.push(source);
-                    }
-                }
-                OpenTask::Ignore | OpenTask::EvalAlways { .. } => {
-                    // ignore
-                }
-            }
-        })
+        self.intern_node(target_dep_node, task_deps.reads, Fingerprint::ZERO).0
     }
 
     fn alloc_node(
@@ -1054,26 +991,47 @@
     }
 }
 
-pub struct RegularOpenTask {
-    node: DepNode,
-    reads: SmallVec<[DepNodeIndex; 8]>,
-    read_set: FxHashSet<DepNodeIndex>,
+impl DepGraphData {
+    fn read_index(&self, source: DepNodeIndex) {
+        ty::tls::with_context_opt(|icx| {
+            let icx = if let Some(icx) = icx { icx } else {  return };
+            if let Some(task_deps) = icx.task_deps {
+                let mut task_deps = task_deps.lock();
+                if cfg!(debug_assertions) {
+                    self.current.lock().total_read_count += 1;
+                }
+                if task_deps.read_set.insert(source) {
+                    task_deps.reads.push(source);
+
+                    #[cfg(debug_assertions)]
+                    {
+                        if let Some(target) = task_deps.node {
+                            let graph = self.current.lock();
+                            if let Some(ref forbidden_edge) = graph.forbidden_edge {
+                                let source = graph.data[source].node;
+                                if forbidden_edge.test(&source, &target) {
+                                    bug!("forbidden edge {:?} -> {:?} created",
+                                        source,
+                                        target)
+                                }
+                            }
+                        }
+                    }
+                } else if cfg!(debug_assertions) {
+                    self.current.lock().total_duplicate_read_count += 1;
+                }
+            }
+        })
+    }
 }
 
-pub struct AnonOpenTask {
+pub struct TaskDeps {
+    #[cfg(debug_assertions)]
+    node: Option<DepNode>,
     reads: SmallVec<[DepNodeIndex; 8]>,
     read_set: FxHashSet<DepNodeIndex>,
 }
 
-pub enum OpenTask {
-    Regular(Lock<RegularOpenTask>),
-    Anon(Lock<AnonOpenTask>),
-    Ignore,
-    EvalAlways {
-        node: DepNode,
-    },
-}
-
 // A data structure that stores Option<DepNodeColor> values as a contiguous
 // array, using one u32 per entry.
 struct DepNodeColorMap {
diff --git a/src/librustc/dep_graph/mod.rs b/src/librustc/dep_graph/mod.rs
index d153b74..022caab 100644
--- a/src/librustc/dep_graph/mod.rs
+++ b/src/librustc/dep_graph/mod.rs
@@ -10,7 +10,7 @@
 
 pub use self::dep_tracking_map::{DepTrackingMap, DepTrackingMapConfig};
 pub use self::dep_node::{DepNode, DepKind, DepConstructor, WorkProductId, label_strs};
-pub use self::graph::{DepGraph, WorkProduct, DepNodeIndex, DepNodeColor, OpenTask};
+pub use self::graph::{DepGraph, WorkProduct, DepNodeIndex, DepNodeColor, TaskDeps};
 pub use self::graph::WorkProductFileKind;
 pub use self::prev::PreviousDepGraph;
 pub use self::query::DepGraphQuery;
diff --git a/src/librustc/hir/map/mod.rs b/src/librustc/hir/map/mod.rs
index 188d487..5bcbeee 100644
--- a/src/librustc/hir/map/mod.rs
+++ b/src/librustc/hir/map/mod.rs
@@ -667,6 +667,7 @@
                 Node::Item(_) |
                 Node::ForeignItem(_) |
                 Node::TraitItem(_) |
+                Node::Expr(Expr { node: ExprKind::Closure(..), ..}) |
                 Node::ImplItem(_) => true,
                 _ => false,
             }
@@ -675,7 +676,7 @@
             match *node {
                 Node::Expr(ref expr) => {
                     match expr.node {
-                        ExprKind::While(..) | ExprKind::Loop(..) => true,
+                        ExprKind::While(..) | ExprKind::Loop(..) | ExprKind::Ret(..) => true,
                         _ => false,
                     }
                 }
diff --git a/src/librustc/ich/impls_ty.rs b/src/librustc/ich/impls_ty.rs
index 57a53d3..ef7fb01 100644
--- a/src/librustc/ich/impls_ty.rs
+++ b/src/librustc/ich/impls_ty.rs
@@ -477,22 +477,6 @@
     MaybeDead
 });
 
-impl_stable_hash_for!(enum mir::interpret::Lock {
-    NoLock,
-    WriteLock(dl),
-    ReadLock(v)
-});
-
-impl_stable_hash_for!(struct mir::interpret::DynamicLifetime {
-    frame,
-    region
-});
-
-impl_stable_hash_for!(enum mir::interpret::AccessKind {
-    Read,
-    Write
-});
-
 impl_stable_hash_for!(enum ty::Variance {
     Covariant,
     Invariant,
diff --git a/src/librustc/infer/opaque_types/mod.rs b/src/librustc/infer/opaque_types/mod.rs
index 56c6da8..5e94bb1 100644
--- a/src/librustc/infer/opaque_types/mod.rs
+++ b/src/librustc/infer/opaque_types/mod.rs
@@ -19,7 +19,7 @@
 /// appear in the return type).
 #[derive(Copy, Clone, Debug)]
 pub struct OpaqueTypeDecl<'tcx> {
-    /// The substitutions that we apply to the abstract that that this
+    /// The substitutions that we apply to the abstract that this
     /// `impl Trait` desugars to. e.g., if:
     ///
     ///     fn foo<'a, 'b, T>() -> impl Trait<'a>
diff --git a/src/librustc/lint/levels.rs b/src/librustc/lint/levels.rs
index 1ae12fe..fe11349 100644
--- a/src/librustc/lint/levels.rs
+++ b/src/librustc/lint/levels.rs
@@ -173,8 +173,8 @@
 
     /// Pushes a list of AST lint attributes onto this context.
     ///
-    /// This function will return a `BuilderPush` object which should be be
-    /// passed to `pop` when this scope for the attributes provided is exited.
+    /// This function will return a `BuilderPush` object which should be passed
+    /// to `pop` when this scope for the attributes provided is exited.
     ///
     /// This function will perform a number of tasks:
     ///
diff --git a/src/librustc/mir/interpret/mod.rs b/src/librustc/mir/interpret/mod.rs
index 25a0f0b..e6a560b 100644
--- a/src/librustc/mir/interpret/mod.rs
+++ b/src/librustc/mir/interpret/mod.rs
@@ -29,7 +29,6 @@
 use hir::def_id::DefId;
 use ty::{self, TyCtxt, Instance};
 use ty::layout::{self, Size};
-use middle::region;
 use std::io;
 use rustc_serialize::{Encoder, Decodable, Encodable};
 use rustc_data_structures::fx::FxHashMap;
@@ -40,27 +39,6 @@
 use std::sync::atomic::{AtomicU32, Ordering};
 use std::num::NonZeroU32;
 
-#[derive(Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
-pub enum Lock {
-    NoLock,
-    WriteLock(DynamicLifetime),
-    /// This should never be empty -- that would be a read lock held and nobody
-    /// there to release it...
-    ReadLock(Vec<DynamicLifetime>),
-}
-
-#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
-pub struct DynamicLifetime {
-    pub frame: usize,
-    pub region: Option<region::Scope>, // "None" indicates "until the function ends"
-}
-
-#[derive(Copy, Clone, Debug, PartialEq, Eq, RustcEncodable, RustcDecodable)]
-pub enum AccessKind {
-    Read,
-    Write,
-}
-
 /// Uniquely identifies a specific constant or static.
 #[derive(Copy, Clone, Debug, Eq, PartialEq, Hash, RustcEncodable, RustcDecodable)]
 pub struct GlobalId<'tcx> {
diff --git a/src/librustc/mir/interpret/value.rs b/src/librustc/mir/interpret/value.rs
index 26a8e63..76eb43e 100644
--- a/src/librustc/mir/interpret/value.rs
+++ b/src/librustc/mir/interpret/value.rs
@@ -79,7 +79,7 @@
     /// The raw bytes of a simple value.
     Bits {
         /// The first `size` bytes are the value.
-        /// Do not try to read less or more bytes that that. The remaining bytes must be 0.
+        /// Do not try to read less or more bytes than that. The remaining bytes must be 0.
         size: u8,
         bits: u128,
     },
diff --git a/src/librustc/session/config.rs b/src/librustc/session/config.rs
index 33409f9..42adc6a 100644
--- a/src/librustc/session/config.rs
+++ b/src/librustc/session/config.rs
@@ -1311,12 +1311,8 @@
         "Disable the instrumentation pre-inliner, useful for profiling / PGO."),
     relro_level: Option<RelroLevel> = (None, parse_relro_level, [TRACKED],
         "choose which RELRO level to use"),
-    nll_subminimal_causes: bool = (false, parse_bool, [UNTRACKED],
-        "when tracking region error causes, accept subminimal results for faster execution."),
     nll_facts: bool = (false, parse_bool, [UNTRACKED],
                        "dump facts from NLL analysis into side files"),
-    disable_nll_user_type_assert: bool = (false, parse_bool, [UNTRACKED],
-        "disable user provided type assertion in NLL"),
     nll_dont_emit_read_for_match: bool = (false, parse_bool, [UNTRACKED],
         "in match codegen, do not include FakeRead statements (used by mir-borrowck)"),
     dont_buffer_diagnostics: bool = (false, parse_bool, [UNTRACKED],
diff --git a/src/librustc/session/filesearch.rs b/src/librustc/session/filesearch.rs
index c6e68ba..19f1c7a 100644
--- a/src/librustc/session/filesearch.rs
+++ b/src/librustc/session/filesearch.rs
@@ -114,13 +114,6 @@
     sysroot.join(&relative_target_lib_path(sysroot, target_triple))
 }
 
-pub fn target_lib_path(target_triple: &str) -> PathBuf {
-    let mut p = PathBuf::from(RUST_LIB_DIR);
-    p.push(target_triple);
-    p.push("lib");
-    p
-}
-
 pub fn get_or_default_sysroot() -> PathBuf {
     // Follow symlinks.  If the resolved path is relative, make it absolute.
     fn canonicalize(path: Option<PathBuf>) -> Option<PathBuf> {
diff --git a/src/librustc/session/mod.rs b/src/librustc/session/mod.rs
index 5c977d5..ba09480 100644
--- a/src/librustc/session/mod.rs
+++ b/src/librustc/session/mod.rs
@@ -16,7 +16,10 @@
 use util::common::ProfileQueriesMsg;
 
 use rustc_data_structures::base_n;
-use rustc_data_structures::sync::{self, Lrc, Lock, LockCell, OneThread, Once, RwLock};
+use rustc_data_structures::sync::{
+    self, Lrc, Lock, OneThread, Once, RwLock, AtomicU64, AtomicUsize, Ordering,
+    Ordering::SeqCst,
+};
 
 use errors::{self, DiagnosticBuilder, DiagnosticId, Applicability};
 use errors::emitter::{Emitter, EmitterWriter};
@@ -41,13 +44,19 @@
 use std::path::PathBuf;
 use std::time::Duration;
 use std::sync::mpsc;
-use std::sync::atomic::{AtomicUsize, Ordering};
 
 mod code_stats;
 pub mod config;
 pub mod filesearch;
 pub mod search_paths;
 
+pub struct OptimizationFuel {
+    /// If -zfuel=crate=n is specified, initially set to n. Otherwise 0.
+    remaining: u64,
+    /// We're rejecting all further optimizations.
+    out_of_fuel: bool,
+}
+
 /// Represents the data associated with a compilation
 /// session for a single crate.
 pub struct Session {
@@ -137,16 +146,15 @@
 
     /// If -zfuel=crate=n is specified, Some(crate).
     optimization_fuel_crate: Option<String>,
-    /// If -zfuel=crate=n is specified, initially set to n. Otherwise 0.
-    optimization_fuel_limit: LockCell<u64>,
-    /// We're rejecting all further optimizations.
-    out_of_fuel: LockCell<bool>,
+
+    /// Tracks fuel info if If -zfuel=crate=n is specified
+    optimization_fuel: Lock<OptimizationFuel>,
 
     // The next two are public because the driver needs to read them.
     /// If -zprint-fuel=crate, Some(crate).
     pub print_fuel_crate: Option<String>,
     /// Always set to zero and incremented so that we can print fuel expended by a crate.
-    pub print_fuel: LockCell<u64>,
+    pub print_fuel: AtomicU64,
 
     /// Loaded up early on in the initialization of this `Session` to avoid
     /// false positives about a job server in our environment.
@@ -871,20 +879,20 @@
         if let Some(ref c) = self.optimization_fuel_crate {
             if c == crate_name {
                 assert_eq!(self.query_threads(), 1);
-                let fuel = self.optimization_fuel_limit.get();
-                ret = fuel != 0;
-                if fuel == 0 && !self.out_of_fuel.get() {
+                let mut fuel = self.optimization_fuel.lock();
+                ret = fuel.remaining != 0;
+                if fuel.remaining == 0 && !fuel.out_of_fuel {
                     eprintln!("optimization-fuel-exhausted: {}", msg());
-                    self.out_of_fuel.set(true);
-                } else if fuel > 0 {
-                    self.optimization_fuel_limit.set(fuel - 1);
+                    fuel.out_of_fuel = true;
+                } else if fuel.remaining > 0 {
+                    fuel.remaining -= 1;
                 }
             }
         }
         if let Some(ref c) = self.print_fuel_crate {
             if c == crate_name {
                 assert_eq!(self.query_threads(), 1);
-                self.print_fuel.set(self.print_fuel.get() + 1);
+                self.print_fuel.fetch_add(1, SeqCst);
             }
         }
         ret
@@ -1134,10 +1142,12 @@
         local_crate_source_file.map(|path| file_path_mapping.map_prefix(path).0);
 
     let optimization_fuel_crate = sopts.debugging_opts.fuel.as_ref().map(|i| i.0.clone());
-    let optimization_fuel_limit =
-        LockCell::new(sopts.debugging_opts.fuel.as_ref().map(|i| i.1).unwrap_or(0));
+    let optimization_fuel = Lock::new(OptimizationFuel {
+        remaining: sopts.debugging_opts.fuel.as_ref().map(|i| i.1).unwrap_or(0),
+        out_of_fuel: false,
+    });
     let print_fuel_crate = sopts.debugging_opts.print_fuel.clone();
-    let print_fuel = LockCell::new(0);
+    let print_fuel = AtomicU64::new(0);
 
     let working_dir = env::current_dir().unwrap_or_else(|e|
         p_s.span_diagnostic
@@ -1199,10 +1209,9 @@
         },
         code_stats: Default::default(),
         optimization_fuel_crate,
-        optimization_fuel_limit,
+        optimization_fuel,
         print_fuel_crate,
         print_fuel,
-        out_of_fuel: LockCell::new(false),
         // Note that this is unsafe because it may misinterpret file descriptors
         // on Unix as jobserver file descriptors. We hopefully execute this near
         // the beginning of the process though to ensure we don't get false
diff --git a/src/librustc/traits/object_safety.rs b/src/librustc/traits/object_safety.rs
index 3851187c..c37dc2a 100644
--- a/src/librustc/traits/object_safety.rs
+++ b/src/librustc/traits/object_safety.rs
@@ -361,7 +361,15 @@
 
                 match abi_of_ty(unit_receiver_ty) {
                     &Abi::Scalar(..) => (),
-                    abi => bug!("Receiver when Self = () should have a Scalar ABI, found {:?}", abi)
+                    abi => {
+                        self.sess.delay_span_bug(
+                            self.def_span(method.def_id),
+                            &format!(
+                                "Receiver when Self = () should have a Scalar ABI, found {:?}",
+                                abi
+                            ),
+                        );
+                    }
                 }
 
                 let trait_object_ty = self.object_ty_for_trait(
@@ -375,10 +383,15 @@
 
                 match abi_of_ty(trait_object_receiver) {
                     &Abi::ScalarPair(..) => (),
-                    abi => bug!(
-                        "Receiver when Self = {} should have a ScalarPair ABI, found {:?}",
-                        trait_object_ty, abi
-                    )
+                    abi => {
+                        self.sess.delay_span_bug(
+                            self.def_span(method.def_id),
+                            &format!(
+                                "Receiver when Self = {} should have a ScalarPair ABI, found {:?}",
+                                trait_object_ty, abi
+                            ),
+                        );
+                    }
                 }
             }
         }
diff --git a/src/librustc/ty/context.rs b/src/librustc/ty/context.rs
index 6c37794..c0ba432 100644
--- a/src/librustc/ty/context.rs
+++ b/src/librustc/ty/context.rs
@@ -1248,7 +1248,11 @@
 
         sync::assert_send_val(&gcx);
 
-        tls::enter_global(gcx, f)
+        let r = tls::enter_global(gcx, f);
+
+        gcx.queries.record_computed_queries(s);
+
+        r
     }
 
     pub fn consider_optimizing<T: Fn() -> String>(&self, msg: T) -> bool {
@@ -1670,7 +1674,7 @@
                 tcx,
                 query: icx.query.clone(),
                 layout_depth: icx.layout_depth,
-                task: icx.task,
+                task_deps: icx.task_deps,
             };
             ty::tls::enter_context(&new_icx, |_| {
                 f(tcx)
@@ -1778,7 +1782,7 @@
     use errors::{Diagnostic, TRACK_DIAGNOSTICS};
     use rustc_data_structures::OnDrop;
     use rustc_data_structures::sync::{self, Lrc, Lock};
-    use dep_graph::OpenTask;
+    use dep_graph::TaskDeps;
 
     #[cfg(not(parallel_queries))]
     use std::cell::Cell;
@@ -1806,7 +1810,7 @@
 
         /// The current dep graph task. This is used to add dependencies to queries
         /// when executing them
-        pub task: &'a OpenTask,
+        pub task_deps: Option<&'a Lock<TaskDeps>>,
     }
 
     /// Sets Rayon's thread local variable which is preserved for Rayon jobs
@@ -1935,7 +1939,7 @@
                 tcx,
                 query: None,
                 layout_depth: 0,
-                task: &OpenTask::Ignore,
+                task_deps: None,
             };
             enter_context(&icx, |_| {
                 f(tcx)
@@ -1965,7 +1969,7 @@
             query: None,
             tcx,
             layout_depth: 0,
-            task: &OpenTask::Ignore,
+            task_deps: None,
         };
         enter_context(&icx, |_| f(tcx))
     }
@@ -2930,9 +2934,6 @@
 }
 
 pub fn provide(providers: &mut ty::query::Providers<'_>) {
-    // FIXME(#44234): almost all of these queries have no sub-queries and
-    // therefore no actual inputs, they're just reading tables calculated in
-    // resolve! Does this work? Unsure! That's what the issue is about.
     providers.in_scope_traits_map = |tcx, id| tcx.gcx.trait_map.get(&id).cloned();
     providers.module_exports = |tcx, id| tcx.gcx.export_map.get(&id).cloned();
     providers.crate_name = |tcx, id| {
diff --git a/src/librustc/ty/fold.rs b/src/librustc/ty/fold.rs
index 4495e96..28b6f01 100644
--- a/src/librustc/ty/fold.rs
+++ b/src/librustc/ty/fold.rs
@@ -109,7 +109,7 @@
         self.has_type_flags(TypeFlags::HAS_FREE_REGIONS)
     }
 
-    /// True if there any any un-erased free regions.
+    /// True if there are any un-erased free regions.
     fn has_erasable_regions(&self) -> bool {
         self.has_type_flags(TypeFlags::HAS_FREE_REGIONS)
     }
diff --git a/src/librustc/ty/mod.rs b/src/librustc/ty/mod.rs
index f11a368..a2c96e7 100644
--- a/src/librustc/ty/mod.rs
+++ b/src/librustc/ty/mod.rs
@@ -14,7 +14,6 @@
 use ich::StableHashingContext;
 use infer::canonical::Canonical;
 use middle::lang_items::{FnTraitLangItem, FnMutTraitLangItem, FnOnceTraitLangItem};
-use middle::privacy::AccessLevels;
 use middle::resolve_lifetime::ObjectLifetimeDefault;
 use mir::Mir;
 use mir::interpret::{GlobalId, ErrorHandled};
@@ -123,8 +122,6 @@
 /// *on-demand* infrastructure.
 #[derive(Clone)]
 pub struct CrateAnalysis {
-    pub access_levels: Lrc<AccessLevels>,
-    pub name: String,
     pub glob_map: Option<hir::GlobMap>,
 }
 
@@ -2842,7 +2839,7 @@
             self.impl_polarity(def_id1) == self.impl_polarity(def_id2)
                 && trait1_is_empty
                 && trait2_is_empty
-        } else if self.features().marker_trait_attr {
+        } else {
             let is_marker_impl = |def_id: DefId| -> bool {
                 let trait_ref = self.impl_trait_ref(def_id);
                 trait_ref.map_or(false, |tr| self.trait_def(tr.def_id).is_marker)
@@ -2850,8 +2847,6 @@
             self.impl_polarity(def_id1) == self.impl_polarity(def_id2)
                 && is_marker_impl(def_id1)
                 && is_marker_impl(def_id2)
-        } else {
-            false
         };
 
         if is_legit {
diff --git a/src/librustc/ty/query/mod.rs b/src/librustc/ty/query/mod.rs
index 99dd356..d9cabb3 100644
--- a/src/librustc/ty/query/mod.rs
+++ b/src/librustc/ty/query/mod.rs
@@ -42,6 +42,7 @@
 use util::nodemap::{DefIdSet, DefIdMap, ItemLocalSet};
 use util::common::{ErrorReported};
 use util::profiling::ProfileCategory::*;
+use session::Session;
 
 use rustc_data_structures::bit_set::BitSet;
 use rustc_data_structures::indexed_vec::IndexVec;
diff --git a/src/librustc/ty/query/plumbing.rs b/src/librustc/ty/query/plumbing.rs
index 9a1ab55..2d619d1 100644
--- a/src/librustc/ty/query/plumbing.rs
+++ b/src/librustc/ty/query/plumbing.rs
@@ -112,11 +112,7 @@
             let mut lock = cache.borrow_mut();
             if let Some(value) = lock.results.get(key) {
                 profq_msg!(tcx, ProfileQueriesMsg::CacheHit);
-                tcx.sess.profiler(|p| {
-                    p.record_query(Q::CATEGORY);
-                    p.record_query_hit(Q::CATEGORY);
-                });
-
+                tcx.sess.profiler(|p| p.record_query_hit(Q::CATEGORY));
                 let result = Ok((value.value.clone(), value.index));
                 #[cfg(debug_assertions)]
                 {
@@ -195,6 +191,7 @@
     /// Executes a job by changing the ImplicitCtxt to point to the
     /// new query job while it executes. It returns the diagnostics
     /// captured during execution and the actual result.
+    #[inline(always)]
     pub(super) fn start<'lcx, F, R>(
         &self,
         tcx: TyCtxt<'_, 'tcx, 'lcx>,
@@ -212,7 +209,7 @@
                 tcx: tcx.global_tcx(),
                 query: Some(self.job.clone()),
                 layout_depth: current_icx.layout_depth,
-                task: current_icx.task,
+                task_deps: current_icx.task_deps,
             };
 
             // Use the ImplicitCtxt while we execute the query
@@ -382,13 +379,10 @@
             )
         );
 
-        self.sess.profiler(|p| p.record_query(Q::CATEGORY));
-
         let job = match JobOwner::try_get(self, span, &key) {
             TryGetJob::NotYetStarted(job) => job,
             TryGetJob::JobCompleted(result) => {
                 return result.map(|(v, index)| {
-                    self.sess.profiler(|p| p.record_query_hit(Q::CATEGORY));
                     self.dep_graph.read_index(index);
                     v
                 })
@@ -430,9 +424,6 @@
 
         if !dep_node.kind.is_input() {
             if let Some(dep_node_index) = self.try_mark_green_and_read(&dep_node) {
-                profq_msg!(self, ProfileQueriesMsg::CacheHit);
-                self.sess.profiler(|p| p.record_query_hit(Q::CATEGORY));
-
                 return self.load_from_disk_and_cache_in_memory::<Q>(key,
                                                                     job,
                                                                     dep_node_index,
@@ -483,11 +474,16 @@
         };
 
         let result = if let Some(result) = result {
+            profq_msg!(self, ProfileQueriesMsg::CacheHit);
+            self.sess.profiler(|p| p.record_query_hit(Q::CATEGORY));
+
             result
         } else {
             // We could not load a result from the on-disk cache, so
             // recompute.
 
+            self.sess.profiler(|p| p.start_activity(Q::CATEGORY));
+
             // The diagnostics for this query have already been
             // promoted to the current session during
             // try_mark_green(), so we can ignore them here.
@@ -498,6 +494,8 @@
                     Q::compute(tcx, key)
                 })
             });
+
+            self.sess.profiler(|p| p.end_activity(Q::CATEGORY));
             result
         };
 
@@ -547,6 +545,7 @@
             for {:?}", dep_node);
     }
 
+    #[inline(always)]
     fn force_query_with_job<Q: QueryDescription<'gcx>>(
         self,
         key: Q::Key,
@@ -565,10 +564,7 @@
                 key, dep_node);
 
         profq_msg!(self, ProfileQueriesMsg::ProviderBegin);
-        self.sess.profiler(|p| {
-            p.start_activity(Q::CATEGORY);
-            p.record_query(Q::CATEGORY);
-        });
+        self.sess.profiler(|p| p.start_activity(Q::CATEGORY));
 
         let res = job.start(self, |tcx| {
             if dep_node.kind.is_eval_always() {
@@ -624,14 +620,10 @@
             // this introduces should be negligible as we'll immediately hit the
             // in-memory cache, or another query down the line will.
 
-            self.sess.profiler(|p| {
-                p.start_activity(Q::CATEGORY);
-                p.record_query(Q::CATEGORY);
-            });
-
             let _ = self.get_query::<Q>(DUMMY_SP, key);
-
-            self.sess.profiler(|p| p.end_activity(Q::CATEGORY));
+        } else {
+            profq_msg!(self, ProfileQueriesMsg::CacheHit);
+            self.sess.profiler(|p| p.record_query_hit(Q::CATEGORY));
         }
     }
 
@@ -751,6 +743,17 @@
                 }
             }
 
+            pub fn record_computed_queries(&self, sess: &Session) {
+                sess.profiler(|p| {
+                    $(
+                        p.record_computed_queries(
+                            <queries::$name<'_> as QueryConfig<'_>>::CATEGORY,
+                            self.$name.lock().results.len()
+                        );
+                    )*
+                });
+            }
+
             #[cfg(parallel_queries)]
             pub fn collect_active_jobs(&self) -> Vec<Lrc<QueryJob<$tcx>>> {
                 let mut jobs = Vec::new();
@@ -974,7 +977,7 @@
                         // HACK(eddyb) it's possible crates may be loaded after
                         // the query engine is created, and because crate loading
                         // is not yet integrated with the query engine, such crates
-                        // would be be missing appropriate entries in `providers`.
+                        // would be missing appropriate entries in `providers`.
                         .unwrap_or(&tcx.queries.fallback_extern_providers)
                         .$name;
                     provider(tcx.global_tcx(), key)
diff --git a/src/librustc/util/profiling.rs b/src/librustc/util/profiling.rs
index d598709..d31a06d 100644
--- a/src/librustc/util/profiling.rs
+++ b/src/librustc/util/profiling.rs
@@ -2,7 +2,7 @@
 
 use std::fs;
 use std::io::{self, StderrLock, Write};
-use std::time::{Duration, Instant};
+use std::time::Instant;
 
 macro_rules! define_categories {
     ($($name:ident,)*) => {
@@ -62,7 +62,8 @@
                 let total_time = ($(self.times.$name + )* 0) as f32;
 
                 $(
-                    let (hits, total) = self.query_counts.$name;
+                    let (hits, computed) = self.query_counts.$name;
+                    let total = hits + computed;
                     let (hits, total) = if total > 0 {
                         (format!("{:.2}",
                         (((hits as f32) / (total as f32)) * 100.0)), total.to_string())
@@ -86,7 +87,8 @@
                 let mut json = String::from("[");
 
                 $(
-                    let (hits, total) = self.query_counts.$name;
+                    let (hits, computed) = self.query_counts.$name;
+                    let total = hits + computed;
 
                     //normalize hits to 0%
                     let hit_percent =
@@ -168,14 +170,14 @@
         self.timer_stack.push(category);
     }
 
-    pub fn record_query(&mut self, category: ProfileCategory) {
-        let (hits, total) = *self.data.query_counts.get(category);
-        self.data.query_counts.set(category, (hits, total + 1));
+    pub fn record_computed_queries(&mut self, category: ProfileCategory, count: usize) {
+        let (hits, computed) = *self.data.query_counts.get(category);
+        self.data.query_counts.set(category, (hits, computed + count as u64));
     }
 
     pub fn record_query_hit(&mut self, category: ProfileCategory) {
-        let (hits, total) = *self.data.query_counts.get(category);
-        self.data.query_counts.set(category, (hits + 1, total));
+        let (hits, computed) = *self.data.query_counts.get(category);
+        self.data.query_counts.set(category, (hits + 1, computed));
     }
 
     pub fn end_activity(&mut self, category: ProfileCategory) {
@@ -203,20 +205,7 @@
     }
 
     fn stop_timer(&mut self) -> u64 {
-        let elapsed = if cfg!(windows) {
-            // On Windows, timers don't always appear to be monotonic (see #51648)
-            // which can lead to panics when calculating elapsed time.
-            // Work around this by testing to see if the current time is less than
-            // our recorded time, and if it is, just returning 0.
-            let now = Instant::now();
-            if self.current_timer >= now {
-                Duration::new(0, 0)
-            } else {
-                self.current_timer.elapsed()
-            }
-        } else {
-            self.current_timer.elapsed()
-        };
+        let elapsed = self.current_timer.elapsed();
 
         self.current_timer = Instant::now();
 
diff --git a/src/librustc_apfloat/ieee.rs b/src/librustc_apfloat/ieee.rs
index 2ff9faa..7ad34be 100644
--- a/src/librustc_apfloat/ieee.rs
+++ b/src/librustc_apfloat/ieee.rs
@@ -2341,7 +2341,7 @@
             // Our exponent should not underflow.
             *exp = exp.checked_sub(bits as ExpInt).unwrap();
 
-            // Jump is the inter-limb jump; shift is is intra-limb shift.
+            // Jump is the inter-limb jump; shift is the intra-limb shift.
             let jump = bits / LIMB_BITS;
             let shift = bits % LIMB_BITS;
 
@@ -2375,7 +2375,7 @@
             // Our exponent should not overflow.
             *exp = exp.checked_add(bits as ExpInt).unwrap();
 
-            // Jump is the inter-limb jump; shift is is intra-limb shift.
+            // Jump is the inter-limb jump; shift is the intra-limb shift.
             let jump = bits / LIMB_BITS;
             let shift = bits % LIMB_BITS;
 
diff --git a/src/librustc_codegen_ssa/mir/block.rs b/src/librustc_codegen_ssa/mir/block.rs
index 7397c72..aa82c85 100644
--- a/src/librustc_codegen_ssa/mir/block.rs
+++ b/src/librustc_codegen_ssa/mir/block.rs
@@ -500,53 +500,57 @@
                     _ => bx.new_fn_type(sig, &extra_args)
                 };
 
-                // emit a panic instead of instantiating an uninhabited type
-                if (intrinsic == Some("init") || intrinsic == Some("uninit")) &&
-                    fn_ty.ret.layout.abi.is_uninhabited()
-                {
-                    let loc = bx.sess().source_map().lookup_char_pos(span.lo());
-                    let filename = Symbol::intern(&loc.file.name.to_string()).as_str();
-                    let filename = bx.const_str_slice(filename);
-                    let line = bx.const_u32(loc.line as u32);
-                    let col = bx.const_u32(loc.col.to_usize() as u32 + 1);
-                    let align = tcx.data_layout.aggregate_align.abi
-                        .max(tcx.data_layout.i32_align.abi)
-                        .max(tcx.data_layout.pointer_align.abi);
+                // emit a panic or a NOP for `panic_if_uninhabited`
+                if intrinsic == Some("panic_if_uninhabited") {
+                    let ty = instance.unwrap().substs.type_at(0);
+                    let layout = bx.layout_of(ty);
+                    if layout.abi.is_uninhabited() {
+                        let loc = bx.sess().source_map().lookup_char_pos(span.lo());
+                        let filename = Symbol::intern(&loc.file.name.to_string()).as_str();
+                        let filename = bx.const_str_slice(filename);
+                        let line = bx.const_u32(loc.line as u32);
+                        let col = bx.const_u32(loc.col.to_usize() as u32 + 1);
+                        let align = tcx.data_layout.aggregate_align.abi
+                            .max(tcx.data_layout.i32_align.abi)
+                            .max(tcx.data_layout.pointer_align.abi);
 
-                    let str = format!(
-                        "Attempted to instantiate uninhabited type {} using mem::{}",
-                        sig.output(),
-                        if intrinsic == Some("init") { "zeroed" } else { "uninitialized" }
-                    );
-                    let msg_str = Symbol::intern(&str).as_str();
-                    let msg_str = bx.const_str_slice(msg_str);
-                    let msg_file_line_col = bx.const_struct(
-                        &[msg_str, filename, line, col],
-                        false,
-                    );
-                    let msg_file_line_col = bx.static_addr_of(
-                        msg_file_line_col,
-                        align,
-                        Some("panic_loc"),
-                    );
+                        let str = format!(
+                            "Attempted to instantiate uninhabited type {}",
+                            ty
+                        );
+                        let msg_str = Symbol::intern(&str).as_str();
+                        let msg_str = bx.const_str_slice(msg_str);
+                        let msg_file_line_col = bx.const_struct(
+                            &[msg_str, filename, line, col],
+                            false,
+                        );
+                        let msg_file_line_col = bx.static_addr_of(
+                            msg_file_line_col,
+                            align,
+                            Some("panic_loc"),
+                        );
 
-                    // Obtain the panic entry point.
-                    let def_id =
-                        common::langcall(bx.tcx(), Some(span), "", lang_items::PanicFnLangItem);
-                    let instance = ty::Instance::mono(bx.tcx(), def_id);
-                    let fn_ty = bx.fn_type_of_instance(&instance);
-                    let llfn = bx.get_fn(instance);
+                        // Obtain the panic entry point.
+                        let def_id =
+                            common::langcall(bx.tcx(), Some(span), "", lang_items::PanicFnLangItem);
+                        let instance = ty::Instance::mono(bx.tcx(), def_id);
+                        let fn_ty = bx.fn_type_of_instance(&instance);
+                        let llfn = bx.get_fn(instance);
 
-                    // Codegen the actual panic invoke/call.
-                    do_call(
-                        self,
-                        &mut bx,
-                        fn_ty,
-                        llfn,
-                        &[msg_file_line_col],
-                        destination.as_ref().map(|(_, bb)| (ReturnDest::Nothing, *bb)),
-                        cleanup,
-                    );
+                        // Codegen the actual panic invoke/call.
+                        do_call(
+                            self,
+                            &mut bx,
+                            fn_ty,
+                            llfn,
+                            &[msg_file_line_col],
+                            destination.as_ref().map(|(_, bb)| (ReturnDest::Nothing, *bb)),
+                            cleanup,
+                        );
+                    } else {
+                        // a NOP
+                        funclet_br(self, &mut bx, destination.as_ref().unwrap().1);
+                    }
                     return;
                 }
 
diff --git a/src/librustc_data_structures/flock.rs b/src/librustc_data_structures/flock.rs
index a5620ca..2dea249 100644
--- a/src/librustc_data_structures/flock.rs
+++ b/src/librustc_data_structures/flock.rs
@@ -31,12 +31,6 @@
                 // not actually here, but brings in line with freebsd
                 pub l_sysid: libc::c_int,
             }
-
-            pub const F_RDLCK: libc::c_short = 0;
-            pub const F_WRLCK: libc::c_short = 1;
-            pub const F_UNLCK: libc::c_short = 2;
-            pub const F_SETLK: libc::c_int = 6;
-            pub const F_SETLKW: libc::c_int = 7;
         }
 
         #[cfg(target_os = "freebsd")]
@@ -52,12 +46,6 @@
                 pub l_whence: libc::c_short,
                 pub l_sysid: libc::c_int,
             }
-
-            pub const F_RDLCK: libc::c_short = 1;
-            pub const F_UNLCK: libc::c_short = 2;
-            pub const F_WRLCK: libc::c_short = 3;
-            pub const F_SETLK: libc::c_int = 12;
-            pub const F_SETLKW: libc::c_int = 13;
         }
 
         #[cfg(any(target_os = "dragonfly",
@@ -78,12 +66,6 @@
                 // not actually here, but brings in line with freebsd
                 pub l_sysid: libc::c_int,
             }
-
-            pub const F_RDLCK: libc::c_short = 1;
-            pub const F_UNLCK: libc::c_short = 2;
-            pub const F_WRLCK: libc::c_short = 3;
-            pub const F_SETLK: libc::c_int = 8;
-            pub const F_SETLKW: libc::c_int = 9;
         }
 
         #[cfg(target_os = "haiku")]
@@ -101,12 +83,6 @@
                 // not actually here, but brings in line with freebsd
                 pub l_sysid: libc::c_int,
             }
-
-            pub const F_RDLCK: libc::c_short = 0x0040;
-            pub const F_UNLCK: libc::c_short = 0x0200;
-            pub const F_WRLCK: libc::c_short = 0x0400;
-            pub const F_SETLK: libc::c_int = 0x0080;
-            pub const F_SETLKW: libc::c_int = 0x0100;
         }
 
         #[cfg(any(target_os = "macos", target_os = "ios"))]
@@ -124,12 +100,6 @@
                 // not actually here, but brings in line with freebsd
                 pub l_sysid: libc::c_int,
             }
-
-            pub const F_RDLCK: libc::c_short = 1;
-            pub const F_UNLCK: libc::c_short = 2;
-            pub const F_WRLCK: libc::c_short = 3;
-            pub const F_SETLK: libc::c_int = 8;
-            pub const F_SETLKW: libc::c_int = 9;
         }
 
         #[cfg(target_os = "solaris")]
@@ -145,12 +115,6 @@
                 pub l_sysid: libc::c_int,
                 pub l_pid: libc::pid_t,
             }
-
-            pub const F_RDLCK: libc::c_short = 1;
-            pub const F_WRLCK: libc::c_short = 2;
-            pub const F_UNLCK: libc::c_short = 3;
-            pub const F_SETLK: libc::c_int = 6;
-            pub const F_SETLKW: libc::c_int = 7;
         }
 
         #[derive(Debug)]
@@ -182,9 +146,9 @@
                 }
 
                 let lock_type = if exclusive {
-                    os::F_WRLCK
+                    libc::F_WRLCK as libc::c_short
                 } else {
-                    os::F_RDLCK
+                    libc::F_RDLCK as libc::c_short
                 };
 
                 let flock = os::flock {
@@ -195,7 +159,7 @@
                     l_type: lock_type,
                     l_sysid: 0,
                 };
-                let cmd = if wait { os::F_SETLKW } else { os::F_SETLK };
+                let cmd = if wait { libc::F_SETLKW } else { libc::F_SETLK };
                 let ret = unsafe {
                     libc::fcntl(fd, cmd, &flock)
                 };
@@ -216,11 +180,11 @@
                     l_len: 0,
                     l_pid: 0,
                     l_whence: libc::SEEK_SET as libc::c_short,
-                    l_type: os::F_UNLCK,
+                    l_type: libc::F_UNLCK as libc::c_short,
                     l_sysid: 0,
                 };
                 unsafe {
-                    libc::fcntl(self.fd, os::F_SETLK, &flock);
+                    libc::fcntl(self.fd, libc::F_SETLK, &flock);
                     libc::close(self.fd);
                 }
             }
diff --git a/src/librustc_data_structures/lib.rs b/src/librustc_data_structures/lib.rs
index c086eb3..ec71f51 100644
--- a/src/librustc_data_structures/lib.rs
+++ b/src/librustc_data_structures/lib.rs
@@ -21,6 +21,7 @@
 #![feature(hash_raw_entry)]
 #![feature(stmt_expr_attributes)]
 #![feature(core_intrinsics)]
+#![feature(integer_atomics)]
 
 #![cfg_attr(unix, feature(libc))]
 #![cfg_attr(test, feature(test))]
diff --git a/src/librustc_data_structures/sync.rs b/src/librustc_data_structures/sync.rs
index d935eb7..f9f94f0 100644
--- a/src/librustc_data_structures/sync.rs
+++ b/src/librustc_data_structures/sync.rs
@@ -10,10 +10,6 @@
 //! It internally uses `parking_lot::RwLock` if cfg!(parallel_queries) is true,
 //! `RefCell` otherwise.
 //!
-//! `LockCell` is a thread safe version of `Cell`, with `set` and `get` operations.
-//! It can never deadlock. It uses `Cell` when
-//! cfg!(parallel_queries) is false, otherwise it is a `Lock`.
-//!
 //! `MTLock` is a mutex which disappears if cfg!(parallel_queries) is false.
 //!
 //! `MTRef` is a immutable reference if cfg!(parallel_queries), and an mutable reference otherwise.
@@ -23,11 +19,7 @@
 
 use std::collections::HashMap;
 use std::hash::{Hash, BuildHasher};
-use std::cmp::Ordering;
 use std::marker::PhantomData;
-use std::fmt::Debug;
-use std::fmt::Formatter;
-use std::fmt;
 use std::ops::{Deref, DerefMut};
 use owning_ref::{Erased, OwningRef};
 
@@ -54,6 +46,9 @@
     f(&SerialScope)
 }
 
+pub use std::sync::atomic::Ordering::SeqCst;
+pub use std::sync::atomic::Ordering;
+
 cfg_if! {
     if #[cfg(not(parallel_queries))] {
         pub auto trait Send {}
@@ -69,6 +64,62 @@
             }
         }
 
+        use std::ops::Add;
+
+        #[derive(Debug)]
+        pub struct Atomic<T: Copy>(Cell<T>);
+
+        impl<T: Copy> Atomic<T> {
+            pub fn new(v: T) -> Self {
+                Atomic(Cell::new(v))
+            }
+        }
+
+        impl<T: Copy + PartialEq> Atomic<T> {
+            pub fn into_inner(self) -> T {
+                self.0.into_inner()
+            }
+
+            pub fn load(&self, _: Ordering) -> T {
+                self.0.get()
+            }
+
+            pub fn store(&self, val: T, _: Ordering) {
+                self.0.set(val)
+            }
+
+            pub fn swap(&self, val: T, _: Ordering) -> T {
+                self.0.replace(val)
+            }
+
+            pub fn compare_exchange(&self,
+                                    current: T,
+                                    new: T,
+                                    _: Ordering,
+                                    _: Ordering)
+                                    -> Result<T, T> {
+                let read = self.0.get();
+                if read == current {
+                    self.0.set(new);
+                    Ok(read)
+                } else {
+                    Err(read)
+                }
+            }
+        }
+
+        impl<T: Add<Output=T> + Copy> Atomic<T> {
+            pub fn fetch_add(&self, val: T, _: Ordering) -> T {
+                let old = self.0.get();
+                self.0.set(old + val);
+                old
+            }
+        }
+
+        pub type AtomicUsize = Atomic<usize>;
+        pub type AtomicBool = Atomic<bool>;
+        pub type AtomicU64 = Atomic<u64>;
+
         pub use self::serial_join as join;
         pub use self::serial_scope as scope;
 
@@ -160,47 +211,6 @@
                 MTLock(self.0.clone())
             }
         }
-
-        pub struct LockCell<T>(Cell<T>);
-
-        impl<T> LockCell<T> {
-            #[inline(always)]
-            pub fn new(inner: T) -> Self {
-                LockCell(Cell::new(inner))
-            }
-
-            #[inline(always)]
-            pub fn into_inner(self) -> T {
-                self.0.into_inner()
-            }
-
-            #[inline(always)]
-            pub fn set(&self, new_inner: T) {
-                self.0.set(new_inner);
-            }
-
-            #[inline(always)]
-            pub fn get(&self) -> T where T: Copy {
-                self.0.get()
-            }
-
-            #[inline(always)]
-            pub fn set_mut(&mut self, new_inner: T) {
-                self.0.set(new_inner);
-            }
-
-            #[inline(always)]
-            pub fn get_mut(&mut self) -> T where T: Copy {
-                self.0.get()
-            }
-        }
-
-        impl<T> LockCell<Option<T>> {
-            #[inline(always)]
-            pub fn take(&self) -> Option<T> {
-                unsafe { (*self.0.as_ptr()).take() }
-            }
-        }
     } else {
         pub use std::marker::Send as Send;
         pub use std::marker::Sync as Sync;
@@ -213,6 +223,8 @@
         pub use parking_lot::MutexGuard as LockGuard;
         pub use parking_lot::MappedMutexGuard as MappedLockGuard;
 
+        pub use std::sync::atomic::{AtomicBool, AtomicUsize, AtomicU64};
+
         pub use std::sync::Arc as Lrc;
         pub use std::sync::Weak as Weak;
 
@@ -278,51 +290,11 @@
                 v.erase_send_sync_owner()
             }}
         }
-
-        pub struct LockCell<T>(Lock<T>);
-
-        impl<T> LockCell<T> {
-            #[inline(always)]
-            pub fn new(inner: T) -> Self {
-                LockCell(Lock::new(inner))
-            }
-
-            #[inline(always)]
-            pub fn into_inner(self) -> T {
-                self.0.into_inner()
-            }
-
-            #[inline(always)]
-            pub fn set(&self, new_inner: T) {
-                *self.0.lock() = new_inner;
-            }
-
-            #[inline(always)]
-            pub fn get(&self) -> T where T: Copy {
-                *self.0.lock()
-            }
-
-            #[inline(always)]
-            pub fn set_mut(&mut self, new_inner: T) {
-                *self.0.get_mut() = new_inner;
-            }
-
-            #[inline(always)]
-            pub fn get_mut(&mut self) -> T where T: Copy {
-                *self.0.get_mut()
-            }
-        }
-
-        impl<T> LockCell<Option<T>> {
-            #[inline(always)]
-            pub fn take(&self) -> Option<T> {
-                self.0.lock().take()
-            }
-        }
     }
 }
 
 pub fn assert_sync<T: ?Sized + Sync>() {}
+pub fn assert_send<T: ?Sized + Send>() {}
 pub fn assert_send_val<T: ?Sized + Send>(_t: &T) {}
 pub fn assert_send_sync_val<T: ?Sized + Sync + Send>(_t: &T) {}
 
@@ -466,65 +438,6 @@
     }
 }
 
-impl<T: Copy + Debug> Debug for LockCell<T> {
-    fn fmt(&self, f: &mut Formatter) -> fmt::Result {
-        f.debug_struct("LockCell")
-            .field("value", &self.get())
-            .finish()
-    }
-}
-
-impl<T:Default> Default for LockCell<T> {
-    /// Creates a `LockCell<T>`, with the `Default` value for T.
-    #[inline]
-    fn default() -> LockCell<T> {
-        LockCell::new(Default::default())
-    }
-}
-
-impl<T:PartialEq + Copy> PartialEq for LockCell<T> {
-    #[inline]
-    fn eq(&self, other: &LockCell<T>) -> bool {
-        self.get() == other.get()
-    }
-}
-
-impl<T:Eq + Copy> Eq for LockCell<T> {}
-
-impl<T:PartialOrd + Copy> PartialOrd for LockCell<T> {
-    #[inline]
-    fn partial_cmp(&self, other: &LockCell<T>) -> Option<Ordering> {
-        self.get().partial_cmp(&other.get())
-    }
-
-    #[inline]
-    fn lt(&self, other: &LockCell<T>) -> bool {
-        self.get() < other.get()
-    }
-
-    #[inline]
-    fn le(&self, other: &LockCell<T>) -> bool {
-        self.get() <= other.get()
-    }
-
-    #[inline]
-    fn gt(&self, other: &LockCell<T>) -> bool {
-        self.get() > other.get()
-    }
-
-    #[inline]
-    fn ge(&self, other: &LockCell<T>) -> bool {
-        self.get() >= other.get()
-    }
-}
-
-impl<T:Ord + Copy> Ord for LockCell<T> {
-    #[inline]
-    fn cmp(&self, other: &LockCell<T>) -> Ordering {
-        self.get().cmp(&other.get())
-    }
-}
-
 #[derive(Debug)]
 pub struct Lock<T>(InnerLock<T>);
 
diff --git a/src/librustc_driver/driver.rs b/src/librustc_driver/driver.rs
index 9b232ed..bfff592 100644
--- a/src/librustc_driver/driver.rs
+++ b/src/librustc_driver/driver.rs
@@ -4,7 +4,6 @@
 use rustc::hir::map as hir_map;
 use rustc::lint;
 use rustc::middle::{self, reachable, resolve_lifetime, stability};
-use rustc::middle::privacy::AccessLevels;
 use rustc::ty::{self, AllArenas, Resolutions, TyCtxt};
 use rustc::traits;
 use rustc::util::common::{install_panic_hook, time, ErrorReported};
@@ -18,7 +17,7 @@
 use rustc_codegen_utils::codegen_backend::CodegenBackend;
 use rustc_data_structures::fingerprint::Fingerprint;
 use rustc_data_structures::stable_hasher::StableHasher;
-use rustc_data_structures::sync::{self, Lrc, Lock};
+use rustc_data_structures::sync::{self, Lock};
 use rustc_incremental;
 use rustc_metadata::creader::CrateLoader;
 use rustc_metadata::cstore::{self, CStore};
@@ -403,14 +402,15 @@
 
     /// Allows overriding default rustc query providers,
     /// after `default_provide` has installed them.
-    pub provide: Box<dyn Fn(&mut ty::query::Providers) + 'a>,
+    pub provide: Box<dyn Fn(&mut ty::query::Providers) + 'a + sync::Send>,
     /// Same as `provide`, but only for non-local crates,
     /// applied after `default_provide_extern`.
-    pub provide_extern: Box<dyn Fn(&mut ty::query::Providers) + 'a>,
+    pub provide_extern: Box<dyn Fn(&mut ty::query::Providers) + 'a + sync::Send>,
 }
 
 impl<'a> CompileController<'a> {
     pub fn basic() -> CompileController<'a> {
+        sync::assert_send::<Self>();
         CompileController {
             after_parse: PhaseController::basic(),
             after_expand: PhaseController::basic(),
@@ -500,7 +500,7 @@
     // If true then the compiler will try to run the callback even if the phase
     // ends with an error. Note that this is not always possible.
     pub run_callback_on_error: bool,
-    pub callback: Box<dyn Fn(&mut CompileState) + 'a>,
+    pub callback: Box<dyn Fn(&mut CompileState) + 'a + sync::Send>,
 }
 
 impl<'a> PhaseController<'a> {
@@ -785,8 +785,6 @@
             },
 
             analysis: ty::CrateAnalysis {
-                access_levels: Lrc::new(AccessLevels::default()),
-                name: crate_name.to_string(),
                 glob_map: if resolver.make_glob_map {
                     Some(resolver.glob_map)
                 } else {
@@ -1101,23 +1099,20 @@
         ast_validation::check_crate(sess, &krate)
     });
 
-    time(sess, "name resolution", || -> CompileResult {
+    time(sess, "name resolution", || {
         resolver.resolve_crate(&krate);
-        Ok(())
-    })?;
+    });
 
     // Needs to go *after* expansion to be able to check the results of macro expansion.
     time(sess, "complete gated feature checking", || {
-        sess.track_errors(|| {
-            syntax::feature_gate::check_crate(
-                &krate,
-                &sess.parse_sess,
-                &sess.features_untracked(),
-                &attributes,
-                sess.opts.unstable_features,
-            );
-        })
-    })?;
+        syntax::feature_gate::check_crate(
+            &krate,
+            &sess.parse_sess,
+            &sess.features_untracked(),
+            &attributes,
+            sess.opts.unstable_features,
+        );
+    });
 
     // Lower ast -> hir.
     // First, we need to collect the dep_graph.
@@ -1193,7 +1188,7 @@
     sess: &'tcx Session,
     cstore: &'tcx CStore,
     hir_map: hir_map::Map<'tcx>,
-    mut analysis: ty::CrateAnalysis,
+    analysis: ty::CrateAnalysis,
     resolutions: Resolutions,
     arenas: &'tcx mut AllArenas<'tcx>,
     name: &str,
@@ -1275,8 +1270,9 @@
                 rvalue_promotion::check_crate(tcx)
             });
 
-            analysis.access_levels =
-                time(sess, "privacy checking", || rustc_privacy::check_crate(tcx));
+            time(sess, "privacy checking", || {
+                rustc_privacy::check_crate(tcx)
+            });
 
             time(sess, "intrinsic checking", || {
                 middle::intrinsicck::check_crate(tcx)
diff --git a/src/librustc_driver/lib.rs b/src/librustc_driver/lib.rs
index 5ff3dc1..889e1ec 100644
--- a/src/librustc_driver/lib.rs
+++ b/src/librustc_driver/lib.rs
@@ -16,6 +16,7 @@
 #![feature(slice_sort_by_cached_key)]
 #![feature(set_stdio)]
 #![feature(no_debug)]
+#![feature(integer_atomics)]
 
 #![recursion_limit="256"]
 
@@ -59,7 +60,7 @@
 use rustc_resolve as resolve;
 use rustc_save_analysis as save;
 use rustc_save_analysis::DumpHandler;
-use rustc_data_structures::sync::{self, Lrc};
+use rustc_data_structures::sync::{self, Lrc, Ordering::SeqCst};
 use rustc_data_structures::OnDrop;
 use rustc::session::{self, config, Session, build_session, CompileResult};
 use rustc::session::CompileIncomplete;
@@ -200,14 +201,7 @@
 }
 
 fn load_backend_from_dylib(path: &Path) -> fn() -> Box<dyn CodegenBackend> {
-    // Note that we're specifically using `open_global_now` here rather than
-    // `open`, namely we want the behavior on Unix of RTLD_GLOBAL and RTLD_NOW,
-    // where NOW means "bind everything right now" because we don't want
-    // surprises later on and RTLD_GLOBAL allows the symbols to be made
-    // available for future dynamic libraries opened. This is currently used by
-    // loading LLVM and then making its symbols available for other dynamic
-    // libraries.
-    let lib = DynamicLibrary::open_global_now(path).unwrap_or_else(|err| {
+    let lib = DynamicLibrary::open(Some(path)).unwrap_or_else(|err| {
         let err = format!("couldn't load codegen backend {:?}: {:?}", path, err);
         early_error(ErrorOutputType::default(), &err);
     });
@@ -276,35 +270,37 @@
     }
 
     let target = session::config::host_triple();
-    // get target libdir path based on executable binary path
-    let sysroot = filesearch::get_or_default_sysroot();
-    let mut libdir_candidates = vec![filesearch::make_target_lib_path(&sysroot, &target)];
+    let mut sysroot_candidates = vec![filesearch::get_or_default_sysroot()];
     let path = current_dll_path()
         .and_then(|s| s.canonicalize().ok());
     if let Some(dll) = path {
-        // use `parent` once to chop off the file name
-        if let Some(path) = dll.parent() {
+        // use `parent` twice to chop off the file name and then also the
+        // directory containing the dll which should be either `lib` or `bin`.
+        if let Some(path) = dll.parent().and_then(|p| p.parent()) {
             // The original `path` pointed at the `rustc_driver` crate's dll.
             // Now that dll should only be in one of two locations. The first is
-            // in the compiler's libdir, for example `$sysroot/$libdir/*.dll`. The
+            // in the compiler's libdir, for example `$sysroot/lib/*.dll`. The
             // other is the target's libdir, for example
-            // `$sysroot/$libdir/rustlib/$target/lib/*.dll`.
+            // `$sysroot/lib/rustlib/$target/lib/*.dll`.
             //
             // We don't know which, so let's assume that if our `path` above
-            // doesn't end in `$target` we *could* be in the main libdir, and always
-            // assume that we may be in the target libdir.
-            libdir_candidates.push(path.to_owned());
+            // ends in `$target` we *could* be in the target libdir, and always
+            // assume that we may be in the main libdir.
+            sysroot_candidates.push(path.to_owned());
 
-            if !path.parent().map_or(false, |p| p.ends_with(target)) {
-                libdir_candidates.push(path.join(filesearch::target_lib_path(target)));
+            if path.ends_with(target) {
+                sysroot_candidates.extend(path.parent() // chop off `$target`
+                    .and_then(|p| p.parent())           // chop off `rustlib`
+                    .and_then(|p| p.parent())           // chop off `lib`
+                    .map(|s| s.to_owned()));
             }
         }
     }
 
-    let sysroot = libdir_candidates.iter()
-        .map(|libdir| {
-            debug!("Trying target libdir: {}", libdir.display());
-            libdir.with_file_name(
+    let sysroot = sysroot_candidates.iter()
+        .map(|sysroot| {
+            let libdir = filesearch::relative_target_lib_path(&sysroot, &target);
+            sysroot.join(libdir).with_file_name(
                 option_env!("CFG_CODEGEN_BACKENDS_DIR").unwrap_or("codegen-backends"))
         })
         .filter(|f| {
@@ -313,12 +309,12 @@
         })
         .next();
     let sysroot = sysroot.unwrap_or_else(|| {
-        let candidates = libdir_candidates.iter()
+        let candidates = sysroot_candidates.iter()
             .map(|p| p.display().to_string())
             .collect::<Vec<_>>()
             .join("\n* ");
         let err = format!("failed to find a `codegen-backends` folder \
-                           in the libdir candidates:\n* {}", candidates);
+                           in the sysroot candidates:\n* {}", candidates);
         early_error(ErrorOutputType::default(), &err);
     });
     info!("probing {} for a codegen backend", sysroot.display());
@@ -932,7 +928,7 @@
                 let sess = state.session;
                 eprintln!("Fuel used by {}: {}",
                     sess.print_fuel_crate.as_ref().unwrap(),
-                    sess.print_fuel.get());
+                    sess.print_fuel.load(SeqCst));
             }
         }
         control
diff --git a/src/librustc_errors/lib.rs b/src/librustc_errors/lib.rs
index f0fde6b..a074441 100644
--- a/src/librustc_errors/lib.rs
+++ b/src/librustc_errors/lib.rs
@@ -26,15 +26,13 @@
 
 use emitter::{Emitter, EmitterWriter};
 
-use rustc_data_structures::sync::{self, Lrc, Lock, LockCell};
+use rustc_data_structures::sync::{self, Lrc, Lock, AtomicUsize, AtomicBool, SeqCst};
 use rustc_data_structures::fx::FxHashSet;
 use rustc_data_structures::stable_hasher::StableHasher;
 
 use std::borrow::Cow;
 use std::cell::Cell;
 use std::{error, fmt};
-use std::sync::atomic::AtomicUsize;
-use std::sync::atomic::Ordering::SeqCst;
 use std::panic;
 
 use termcolor::{ColorSpec, Color};
@@ -271,7 +269,7 @@
 
     err_count: AtomicUsize,
     emitter: Lock<Box<dyn Emitter + sync::Send>>,
-    continue_after_error: LockCell<bool>,
+    continue_after_error: AtomicBool,
     delayed_span_bugs: Lock<Vec<Diagnostic>>,
 
     // This set contains the `DiagnosticId` of all emitted diagnostics to avoid
@@ -370,7 +368,7 @@
             flags,
             err_count: AtomicUsize::new(0),
             emitter: Lock::new(e),
-            continue_after_error: LockCell::new(true),
+            continue_after_error: AtomicBool::new(true),
             delayed_span_bugs: Lock::new(Vec::new()),
             taught_diagnostics: Default::default(),
             emitted_diagnostic_codes: Default::default(),
@@ -379,7 +377,7 @@
     }
 
     pub fn set_continue_after_error(&self, continue_after_error: bool) {
-        self.continue_after_error.set(continue_after_error);
+        self.continue_after_error.store(continue_after_error, SeqCst);
     }
 
     /// Resets the diagnostic error count as well as the cached emitted diagnostics.
@@ -658,7 +656,7 @@
         let mut db = DiagnosticBuilder::new(self, lvl, msg);
         db.set_span(msp.clone());
         db.emit();
-        if !self.continue_after_error.get() {
+        if !self.continue_after_error.load(SeqCst) {
             self.abort_if_errors();
         }
     }
@@ -669,7 +667,7 @@
         let mut db = DiagnosticBuilder::new_with_code(self, lvl, Some(code), msg);
         db.set_span(msp.clone());
         db.emit();
-        if !self.continue_after_error.get() {
+        if !self.continue_after_error.load(SeqCst) {
             self.abort_if_errors();
         }
     }
diff --git a/src/librustc_incremental/persist/save.rs b/src/librustc_incremental/persist/save.rs
index 5131b63..6a7553b 100644
--- a/src/librustc_incremental/persist/save.rs
+++ b/src/librustc_incremental/persist/save.rs
@@ -149,8 +149,6 @@
 
         let total_node_count = serialized_graph.nodes.len();
         let total_edge_count = serialized_graph.edge_list_data.len();
-        let (total_edge_reads, total_duplicate_edge_reads) =
-            tcx.dep_graph.edge_deduplication_data();
 
         let mut counts: FxHashMap<_, Stat> = FxHashMap::default();
 
@@ -188,8 +186,11 @@
         println!("[incremental]");
         println!("[incremental] Total Node Count: {}", total_node_count);
         println!("[incremental] Total Edge Count: {}", total_edge_count);
-        println!("[incremental] Total Edge Reads: {}", total_edge_reads);
-        println!("[incremental] Total Duplicate Edge Reads: {}", total_duplicate_edge_reads);
+        if let Some((total_edge_reads,
+                     total_duplicate_edge_reads)) = tcx.dep_graph.edge_deduplication_data() {
+            println!("[incremental] Total Edge Reads: {}", total_edge_reads);
+            println!("[incremental] Total Duplicate Edge Reads: {}", total_duplicate_edge_reads);
+        }
         println!("[incremental]");
         println!("[incremental]  {:<36}| {:<17}| {:<12}| {:<17}|",
                  "Node Kind",
diff --git a/src/librustc_lint/builtin.rs b/src/librustc_lint/builtin.rs
index 27b65b4..5678f30 100644
--- a/src/librustc_lint/builtin.rs
+++ b/src/librustc_lint/builtin.rs
@@ -297,6 +297,26 @@
     private_traits: FxHashSet<ast::NodeId>,
 }
 
+fn has_doc(attr: &ast::Attribute) -> bool {
+    if !attr.check_name("doc") {
+        return false;
+    }
+
+    if attr.is_value_str() {
+        return true;
+    }
+
+    if let Some(list) = attr.meta_item_list() {
+        for meta in list {
+            if meta.check_name("include") || meta.check_name("hidden") {
+                return true;
+            }
+        }
+    }
+
+    false
+}
+
 impl MissingDoc {
     pub fn new() -> MissingDoc {
         MissingDoc {
@@ -335,26 +355,6 @@
             }
         }
 
-        fn has_doc(attr: &ast::Attribute) -> bool {
-            if !attr.check_name("doc") {
-                return false;
-            }
-
-            if attr.is_value_str() {
-                return true;
-            }
-
-            if let Some(list) = attr.meta_item_list() {
-                for meta in list {
-                    if meta.check_name("include") {
-                        return true;
-                    }
-                }
-            }
-
-            false
-        }
-
         let has_doc = attrs.iter().any(|a| has_doc(a));
         if !has_doc {
             cx.span_lint(MISSING_DOCS,
@@ -389,6 +389,15 @@
 
     fn check_crate(&mut self, cx: &LateContext, krate: &hir::Crate) {
         self.check_missing_docs_attrs(cx, None, &krate.attrs, krate.span, "crate");
+
+        for macro_def in &krate.exported_macros {
+            let has_doc = macro_def.attrs.iter().any(|a| has_doc(a));
+            if !has_doc {
+                cx.span_lint(MISSING_DOCS,
+                             cx.tcx.sess.source_map().def_span(macro_def.span),
+                             "missing documentation for macro");
+            }
+        }
     }
 
     fn check_item(&mut self, cx: &LateContext, it: &hir::Item) {
@@ -673,7 +682,7 @@
     }
 }
 
-/// Checks for incorrect use use of `repr` attributes.
+/// Checks for incorrect use of `repr` attributes.
 #[derive(Clone)]
 pub struct BadRepr;
 
diff --git a/src/librustc_llvm/build.rs b/src/librustc_llvm/build.rs
index 238e79d..d4a3ae2 100644
--- a/src/librustc_llvm/build.rs
+++ b/src/librustc_llvm/build.rs
@@ -132,6 +132,10 @@
             continue;
         }
 
+        if flag.starts_with("-flto") {
+            continue;
+        }
+
         // -Wdate-time is not supported by the netbsd cross compiler
         if is_crossed && target.contains("netbsd") && flag.contains("date-time") {
             continue;
@@ -232,6 +236,7 @@
     }
 
     let llvm_static_stdcpp = env::var_os("LLVM_STATIC_STDCPP");
+    let llvm_use_libcxx = env::var_os("LLVM_USE_LIBCXX");
 
     let stdcppname = if target.contains("openbsd") {
         // llvm-config on OpenBSD doesn't mention stdlib=libc++
@@ -241,6 +246,8 @@
     } else if target.contains("netbsd") && llvm_static_stdcpp.is_some() {
         // NetBSD uses a separate library when relocation is required
         "stdc++_pic"
+    } else if llvm_use_libcxx.is_some() {
+        "c++"
     } else {
         "stdc++"
     };
diff --git a/src/librustc_mir/borrow_check/error_reporting.rs b/src/librustc_mir/borrow_check/error_reporting.rs
index 474e67a..7f7d168 100644
--- a/src/librustc_mir/borrow_check/error_reporting.rs
+++ b/src/librustc_mir/borrow_check/error_reporting.rs
@@ -723,7 +723,7 @@
                      functions can only return borrows to data passed as arguments",
                 );
                 err.note(
-                    "to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch04-02-\
+                    "to learn more, visit <https://doc.rust-lang.org/book/ch04-02-\
                      references-and-borrowing.html#dangling-references>",
                 );
             } else {
@@ -2139,7 +2139,7 @@
                     "argument and return type have the same lifetime due to lifetime elision rules",
                 );
                 diag.note(
-                    "to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch10-03-\
+                    "to learn more, visit <https://doc.rust-lang.org/book/ch10-03-\
                      lifetime-syntax.html#lifetime-elision>",
                 );
 
diff --git a/src/librustc_mir/build/expr/as_rvalue.rs b/src/librustc_mir/build/expr/as_rvalue.rs
index a66da50..e0fc909 100644
--- a/src/librustc_mir/build/expr/as_rvalue.rs
+++ b/src/librustc_mir/build/expr/as_rvalue.rs
@@ -67,7 +67,6 @@
                 block.and(Rvalue::Repeat(value_operand, count))
             }
             ExprKind::Borrow {
-                region,
                 borrow_kind,
                 arg,
             } => {
@@ -75,7 +74,7 @@
                     BorrowKind::Shared => unpack!(block = this.as_read_only_place(block, arg)),
                     _ => unpack!(block = this.as_place(block, arg)),
                 };
-                block.and(Rvalue::Ref(region, borrow_kind, arg_place))
+                block.and(Rvalue::Ref(this.hir.tcx().types.re_erased, borrow_kind, arg_place))
             }
             ExprKind::Binary { op, lhs, rhs } => {
                 let lhs = unpack!(block = this.as_operand(block, scope, lhs));
@@ -249,11 +248,10 @@
                                             BorrowKind::Mut {
                                                 allow_two_phase_borrow: false,
                                             },
-                                        region,
                                         arg,
                                     } => unpack!(
                                         block = this.limit_capture_mutability(
-                                            upvar.span, upvar.ty, scope, block, arg, region,
+                                            upvar.span, upvar.ty, scope, block, arg,
                                         )
                                     ),
                                     _ => unpack!(block = this.as_operand(block, scope, upvar)),
@@ -500,7 +498,6 @@
         temp_lifetime: Option<region::Scope>,
         mut block: BasicBlock,
         arg: ExprRef<'tcx>,
-        region: &'tcx ty::RegionKind,
     ) -> BlockAnd<Operand<'tcx>> {
         let this = self;
 
@@ -582,7 +579,7 @@
             block,
             source_info,
             &Place::Local(temp),
-            Rvalue::Ref(region, borrow_kind, arg_place),
+            Rvalue::Ref(this.hir.tcx().types.re_erased, borrow_kind, arg_place),
         );
 
         // In constants, temp_lifetime is None. We should not need to drop
diff --git a/src/librustc_mir/build/matches/mod.rs b/src/librustc_mir/build/matches/mod.rs
index 409b6c0..d52ce9a 100644
--- a/src/librustc_mir/build/matches/mod.rs
+++ b/src/librustc_mir/build/matches/mod.rs
@@ -284,6 +284,7 @@
                     ..
                 },
                 user_ty: pat_ascription_ty,
+                variance: _,
                 user_ty_span,
             } => {
                 let place =
@@ -310,6 +311,20 @@
                         source_info: ty_source_info,
                         kind: StatementKind::AscribeUserType(
                             place,
+                            // We always use invariant as the variance here. This is because the
+                            // variance field from the ascription refers to the variance to use
+                            // when applying the type to the value being matched, but this
+                            // ascription applies rather to the type of the binding. e.g., in this
+                            // example:
+                            //
+                            // ```
+                            // let x: T = <expr>
+                            // ```
+                            //
+                            // We are creating an ascription that defines the type of `x` to be
+                            // exactly `T` (i.e., with invariance). The variance field, in
+                            // contrast, is intended to be used to relate `T` to the type of
+                            // `<expr>`.
                             ty::Variance::Invariant,
                             user_ty,
                         ),
@@ -541,12 +556,20 @@
             PatternKind::Deref { ref subpattern } => {
                 self.visit_bindings(subpattern, pattern_user_ty.deref(), f);
             }
-            PatternKind::AscribeUserType { ref subpattern, ref user_ty, user_ty_span } => {
+            PatternKind::AscribeUserType {
+                ref subpattern,
+                ref user_ty,
+                user_ty_span,
+                variance: _,
+            } => {
                 // This corresponds to something like
                 //
                 // ```
                 // let A::<'a>(_): A<'static> = ...;
                 // ```
+                //
+                // Note that the variance doesn't apply here, as we are tracking the effect
+                // of `user_ty` on any bindings contained with subpattern.
                 let annotation = (user_ty_span, user_ty.base);
                 let projection = UserTypeProjection {
                     base: self.canonical_user_type_annotations.push(annotation),
@@ -617,7 +640,7 @@
     var_id: NodeId,
     var_ty: Ty<'tcx>,
     mutability: Mutability,
-    binding_mode: BindingMode<'tcx>,
+    binding_mode: BindingMode,
 }
 
 /// Indicates that the type of `source` must be a subtype of the
@@ -628,6 +651,7 @@
     span: Span,
     source: Place<'tcx>,
     user_ty: PatternTypeProjection<'tcx>,
+    variance: ty::Variance,
 }
 
 #[derive(Clone, Debug)]
@@ -1321,7 +1345,7 @@
                     source_info,
                     kind: StatementKind::AscribeUserType(
                         ascription.source.clone(),
-                        ty::Variance::Covariant,
+                        ascription.variance,
                         user_ty,
                     ),
                 },
@@ -1345,7 +1369,7 @@
         // Assign each of the bindings. Since we are binding for a
         // guard expression, this will never trigger moves out of the
         // candidate.
-        let re_empty = self.hir.tcx().types.re_empty;
+        let re_erased = self.hir.tcx().types.re_erased;
         for binding in bindings {
             let source_info = self.source_info(binding.span);
 
@@ -1361,11 +1385,11 @@
             self.schedule_drop_for_binding(binding.var_id, binding.span, RefWithinGuard);
             match binding.binding_mode {
                 BindingMode::ByValue => {
-                    let rvalue = Rvalue::Ref(re_empty, BorrowKind::Shared, binding.source.clone());
+                    let rvalue = Rvalue::Ref(re_erased, BorrowKind::Shared, binding.source.clone());
                     self.cfg
                         .push_assign(block, source_info, &ref_for_guard, rvalue);
                 }
-                BindingMode::ByRef(region, borrow_kind) => {
+                BindingMode::ByRef(borrow_kind) => {
                     // Tricky business: For `ref id` and `ref mut id`
                     // patterns, we want `id` within the guard to
                     // correspond to a temp of type `& &T` or `& &mut
@@ -1405,10 +1429,10 @@
                             allow_two_phase_borrow: true,
                         },
                     };
-                    let rvalue = Rvalue::Ref(region, borrow_kind, binding.source.clone());
+                    let rvalue = Rvalue::Ref(re_erased, borrow_kind, binding.source.clone());
                     self.cfg
                         .push_assign(block, source_info, &val_for_guard, rvalue);
-                    let rvalue = Rvalue::Ref(region, BorrowKind::Shared, val_for_guard);
+                    let rvalue = Rvalue::Ref(re_erased, BorrowKind::Shared, val_for_guard);
                     self.cfg
                         .push_assign(block, source_info, &ref_for_guard, rvalue);
                 }
@@ -1426,6 +1450,8 @@
             block, bindings
         );
 
+
+        let re_erased = self.hir.tcx().types.re_erased;
         // Assign each of the bindings. This may trigger moves out of the candidate.
         for binding in bindings {
             let source_info = self.source_info(binding.span);
@@ -1436,8 +1462,8 @@
                 BindingMode::ByValue => {
                     Rvalue::Use(self.consume_by_copy_or_move(binding.source.clone()))
                 }
-                BindingMode::ByRef(region, borrow_kind) => {
-                    Rvalue::Ref(region, borrow_kind, binding.source.clone())
+                BindingMode::ByRef(borrow_kind) => {
+                    Rvalue::Ref(re_erased, borrow_kind, binding.source.clone())
                 }
             };
             self.cfg.push_assign(block, source_info, &local, rvalue);
@@ -1483,7 +1509,7 @@
         let tcx = self.hir.tcx();
         let binding_mode = match mode {
             BindingMode::ByValue => ty::BindingMode::BindByValue(mutability.into()),
-            BindingMode::ByRef { .. } => ty::BindingMode::BindByReference(mutability.into()),
+            BindingMode::ByRef(_) => ty::BindingMode::BindByReference(mutability.into()),
         };
         debug!("declare_binding: user_ty={:?}", user_ty);
         let local = LocalDecl::<'tcx> {
@@ -1521,7 +1547,7 @@
             let ref_for_guard = self.local_decls.push(LocalDecl::<'tcx> {
                 // See previous comment.
                 mutability: Mutability::Not,
-                ty: tcx.mk_imm_ref(tcx.types.re_empty, var_ty),
+                ty: tcx.mk_imm_ref(tcx.types.re_erased, var_ty),
                 user_ty: UserTypeProjections::none(),
                 name: Some(name),
                 source_info,
@@ -1590,7 +1616,7 @@
 
         for (matched_place, borrow_kind) in all_fake_borrows {
             let borrowed_input =
-                Rvalue::Ref(tcx.types.re_empty, borrow_kind, matched_place.clone());
+                Rvalue::Ref(tcx.types.re_erased, borrow_kind, matched_place.clone());
             let borrowed_input_ty = borrowed_input.ty(&self.local_decls, tcx);
             let borrowed_input_temp = self.temp(borrowed_input_ty, source_info.span);
             self.cfg.push_assign(
diff --git a/src/librustc_mir/build/matches/simplify.rs b/src/librustc_mir/build/matches/simplify.rs
index 7692ad4..22bc350 100644
--- a/src/librustc_mir/build/matches/simplify.rs
+++ b/src/librustc_mir/build/matches/simplify.rs
@@ -56,11 +56,19 @@
                                  -> Result<(), MatchPair<'pat, 'tcx>> {
         let tcx = self.hir.tcx();
         match *match_pair.pattern.kind {
-            PatternKind::AscribeUserType { ref subpattern, ref user_ty, user_ty_span } => {
+            PatternKind::AscribeUserType {
+                ref subpattern,
+                variance,
+                ref user_ty,
+                user_ty_span
+            } => {
+                // Apply the type ascription to the value at `match_pair.place`, which is the
+                // value being matched, taking the variance field into account.
                 candidate.ascriptions.push(Ascription {
                     span: user_ty_span,
                     user_ty: user_ty.clone(),
                     source: match_pair.place.clone(),
+                    variance,
                 });
 
                 candidate.match_pairs.push(MatchPair::new(match_pair.place, subpattern));
diff --git a/src/librustc_mir/build/matches/test.rs b/src/librustc_mir/build/matches/test.rs
index aae3de6..696c173 100644
--- a/src/librustc_mir/build/matches/test.rs
+++ b/src/librustc_mir/build/matches/test.rs
@@ -304,17 +304,16 @@
                     let (mty, method) = self.hir.trait_method(eq_def_id, "eq", ty, &[ty.into()]);
                     let method = self.hir.tcx().intern_lazy_const(ty::LazyConst::Evaluated(method));
 
+                    let re_erased = self.hir.tcx().types.re_erased;
                     // take the argument by reference
-                    let region_scope = self.topmost_scope();
-                    let region = self.hir.tcx().mk_region(ty::ReScope(region_scope));
                     let tam = ty::TypeAndMut {
                         ty,
                         mutbl: Mutability::MutImmutable,
                     };
-                    let ref_ty = self.hir.tcx().mk_ref(region, tam);
+                    let ref_ty = self.hir.tcx().mk_ref(re_erased, tam);
 
                     // let lhs_ref_place = &lhs;
-                    let ref_rvalue = Rvalue::Ref(region, BorrowKind::Shared, place);
+                    let ref_rvalue = Rvalue::Ref(re_erased, BorrowKind::Shared, place);
                     let lhs_ref_place = self.temp(ref_ty, test.span);
                     self.cfg.push_assign(block, source_info, &lhs_ref_place, ref_rvalue);
                     let val = Operand::Move(lhs_ref_place);
@@ -324,7 +323,7 @@
                     self.cfg.push_assign(block, source_info, &rhs_place, Rvalue::Use(expect));
 
                     // let rhs_ref_place = &rhs_place;
-                    let ref_rvalue = Rvalue::Ref(region, BorrowKind::Shared, rhs_place);
+                    let ref_rvalue = Rvalue::Ref(re_erased, BorrowKind::Shared, rhs_place);
                     let rhs_ref_place = self.temp(ref_ty, test.span);
                     self.cfg.push_assign(block, source_info, &rhs_ref_place, ref_rvalue);
                     let expect = Operand::Move(rhs_ref_place);
diff --git a/src/librustc_mir/dataflow/impls/borrows.rs b/src/librustc_mir/dataflow/impls/borrows.rs
index 518fbaa..0ceff4a 100644
--- a/src/librustc_mir/dataflow/impls/borrows.rs
+++ b/src/librustc_mir/dataflow/impls/borrows.rs
@@ -279,20 +279,6 @@
                     });
 
                     sets.gen(*index);
-
-                    // Issue #46746: Two-phase borrows handles
-                    // stmts of form `Tmp = &mut Borrow` ...
-                    match lhs {
-                        Place::Promoted(_) |
-                        Place::Local(..) | Place::Static(..) => {} // okay
-                        Place::Projection(..) => {
-                            // ... can assign into projections,
-                            // e.g., `box (&mut _)`. Current
-                            // conservative solution: force
-                            // immediate activation here.
-                            sets.gen(*index);
-                        }
-                    }
                 }
             }
 
diff --git a/src/librustc_mir/hair/cx/block.rs b/src/librustc_mir/hair/cx/block.rs
index e73cc40..ea8b282 100644
--- a/src/librustc_mir/hair/cx/block.rs
+++ b/src/librustc_mir/hair/cx/block.rs
@@ -3,6 +3,7 @@
 use hair::cx::to_ref::ToRef;
 use rustc::middle::region;
 use rustc::hir;
+use rustc::ty;
 
 use rustc_data_structures::indexed_vec::Idx;
 
@@ -86,7 +87,8 @@
                                     kind: Box::new(PatternKind::AscribeUserType {
                                         user_ty: PatternTypeProjection::from_user_type(user_ty),
                                         user_ty_span: ty.span,
-                                        subpattern: pattern
+                                        subpattern: pattern,
+                                        variance: ty::Variance::Covariant,
                                     })
                                 };
                             }
diff --git a/src/librustc_mir/hair/cx/expr.rs b/src/librustc_mir/hair/cx/expr.rs
index 532e678..eb536fb 100644
--- a/src/librustc_mir/hair/cx/expr.rs
+++ b/src/librustc_mir/hair/cx/expr.rs
@@ -124,7 +124,6 @@
                                   }),
                 span,
                 kind: ExprKind::Borrow {
-                    region: deref.region,
                     borrow_kind: deref.mutbl.to_borrow_kind(),
                     arg: expr.to_ref(),
                 },
@@ -132,32 +131,24 @@
 
             overloaded_place(cx, hir_expr, adjustment.target, Some(call), vec![expr.to_ref()])
         }
-        Adjust::Borrow(AutoBorrow::Ref(r, m)) => {
+        Adjust::Borrow(AutoBorrow::Ref(_, m)) => {
             ExprKind::Borrow {
-                region: r,
                 borrow_kind: m.to_borrow_kind(),
                 arg: expr.to_ref(),
             }
         }
         Adjust::Borrow(AutoBorrow::RawPtr(m)) => {
             // Convert this to a suitable `&foo` and
-            // then an unsafe coercion. Limit the region to be just this
-            // expression.
-            let region = ty::ReScope(region::Scope {
-                id: hir_expr.hir_id.local_id,
-                data: region::ScopeData::Node
-            });
-            let region = cx.tcx.mk_region(region);
+            // then an unsafe coercion.
             expr = Expr {
                 temp_lifetime,
-                ty: cx.tcx.mk_ref(region,
+                ty: cx.tcx.mk_ref(cx.tcx.types.re_erased,
                                   ty::TypeAndMut {
                                     ty: expr.ty,
                                     mutbl: m,
                                   }),
                 span,
                 kind: ExprKind::Borrow {
-                    region,
                     borrow_kind: m.to_borrow_kind(),
                     arg: expr.to_ref(),
                 },
@@ -323,12 +314,7 @@
         }
 
         hir::ExprKind::AddrOf(mutbl, ref expr) => {
-            let region = match expr_ty.sty {
-                ty::Ref(r, _, _) => r,
-                _ => span_bug!(expr.span, "type of & not region"),
-            };
             ExprKind::Borrow {
-                region,
                 borrow_kind: mutbl.to_borrow_kind(),
                 arg: expr.to_ref(),
             }
@@ -1222,7 +1208,6 @@
                 ty: freevar_ty,
                 span: closure_expr.span,
                 kind: ExprKind::Borrow {
-                    region: upvar_borrow.region,
                     borrow_kind,
                     arg: captured_var.to_ref(),
                 },
diff --git a/src/librustc_mir/hair/mod.rs b/src/librustc_mir/hair/mod.rs
index 676b984..e902423 100644
--- a/src/librustc_mir/hair/mod.rs
+++ b/src/librustc_mir/hair/mod.rs
@@ -9,7 +9,7 @@
 use rustc::infer::canonical::Canonical;
 use rustc::middle::region;
 use rustc::ty::subst::Substs;
-use rustc::ty::{AdtDef, UpvarSubsts, Region, Ty, Const, LazyConst, UserTypeAnnotation};
+use rustc::ty::{AdtDef, UpvarSubsts, Ty, Const, LazyConst, UserTypeAnnotation};
 use rustc::ty::layout::VariantIdx;
 use rustc::hir;
 use syntax::ast;
@@ -235,7 +235,6 @@
         id: DefId,
     },
     Borrow {
-        region: Region<'tcx>,
         borrow_kind: BorrowKind,
         arg: ExprRef<'tcx>,
     },
diff --git a/src/librustc_mir/hair/pattern/mod.rs b/src/librustc_mir/hair/pattern/mod.rs
index f52aede..8991a90 100644
--- a/src/librustc_mir/hair/pattern/mod.rs
+++ b/src/librustc_mir/hair/pattern/mod.rs
@@ -39,9 +39,9 @@
 }
 
 #[derive(Copy, Clone, Debug)]
-pub enum BindingMode<'tcx> {
+pub enum BindingMode {
     ByValue,
-    ByRef(Region<'tcx>, BorrowKind),
+    ByRef(BorrowKind),
 }
 
 #[derive(Clone, Debug)]
@@ -91,6 +91,25 @@
     AscribeUserType {
         user_ty: PatternTypeProjection<'tcx>,
         subpattern: Pattern<'tcx>,
+        /// Variance to use when relating the type `user_ty` to the **type of the value being
+        /// matched**. Typically, this is `Variance::Covariant`, since the value being matched must
+        /// have a type that is some subtype of the ascribed type.
+        ///
+        /// Note that this variance does not apply for any bindings within subpatterns. The type
+        /// assigned to those bindings must be exactly equal to the `user_ty` given here.
+        ///
+        /// The only place where this field is not `Covariant` is when matching constants, where
+        /// we currently use `Contravariant` -- this is because the constant type just needs to
+        /// be "comparable" to the type of the input value. So, for example:
+        ///
+        /// ```text
+        /// match x { "foo" => .. }
+        /// ```
+        ///
+        /// requires that `&'static str <: T_x`, where `T_x` is the type of `x`. Really, we should
+        /// probably be checking for a `PartialEq` impl instead, but this preserves the behavior
+        /// of the old type-check for now. See #57280 for details.
+        variance: ty::Variance,
         user_ty_span: Span,
     },
 
@@ -98,7 +117,7 @@
     Binding {
         mutability: Mutability,
         name: ast::Name,
-        mode: BindingMode<'tcx>,
+        mode: BindingMode,
         var: ast::NodeId,
         ty: Ty<'tcx>,
         subpattern: Option<Pattern<'tcx>>,
@@ -162,7 +181,7 @@
             PatternKind::Binding { mutability, name, mode, ref subpattern, .. } => {
                 let is_mut = match mode {
                     BindingMode::ByValue => mutability == Mutability::Mut,
-                    BindingMode::ByRef(_, bk) => {
+                    BindingMode::ByRef(bk) => {
                         write!(f, "ref ")?;
                         match bk { BorrowKind::Mut { .. } => true, _ => false }
                     }
@@ -493,12 +512,9 @@
 
             PatKind::Binding(_, id, ident, ref sub) => {
                 let var_ty = self.tables.node_id_to_type(pat.hir_id);
-                let region = match var_ty.sty {
-                    ty::Ref(r, _, _) => Some(r),
-                    ty::Error => { // Avoid ICE
-                        return Pattern { span: pat.span, ty, kind: Box::new(PatternKind::Wild) };
-                    }
-                    _ => None,
+                if let ty::Error = var_ty.sty {
+                    // Avoid ICE
+                    return Pattern { span: pat.span, ty, kind: Box::new(PatternKind::Wild) };
                 };
                 let bm = *self.tables.pat_binding_modes().get(pat.hir_id)
                                                          .expect("missing binding mode");
@@ -509,10 +525,10 @@
                         (Mutability::Not, BindingMode::ByValue),
                     ty::BindByReference(hir::MutMutable) =>
                         (Mutability::Not, BindingMode::ByRef(
-                            region.unwrap(), BorrowKind::Mut { allow_two_phase_borrow: false })),
+                            BorrowKind::Mut { allow_two_phase_borrow: false })),
                     ty::BindByReference(hir::MutImmutable) =>
                         (Mutability::Not, BindingMode::ByRef(
-                            region.unwrap(), BorrowKind::Shared)),
+                            BorrowKind::Shared)),
                 };
 
                 // A ref x pattern is the same node used for x, and as such it has
@@ -714,6 +730,7 @@
                 },
                 user_ty: PatternTypeProjection::from_user_type(user_ty),
                 user_ty_span: span,
+                variance: ty::Variance::Covariant,
             };
         }
 
@@ -763,6 +780,9 @@
                                         kind: Box::new(
                                             PatternKind::AscribeUserType {
                                                 subpattern: pattern,
+                                                /// Note that use `Contravariant` here. See the
+                                                /// `variance` field documentation for details.
+                                                variance: ty::Variance::Contravariant,
                                                 user_ty,
                                                 user_ty_span: span,
                                             }
@@ -1019,7 +1039,7 @@
 
 CloneImpls!{ <'tcx>
     Span, Field, Mutability, ast::Name, ast::NodeId, usize, ty::Const<'tcx>,
-    Region<'tcx>, Ty<'tcx>, BindingMode<'tcx>, &'tcx AdtDef,
+    Region<'tcx>, Ty<'tcx>, BindingMode, &'tcx AdtDef,
     &'tcx Substs<'tcx>, &'tcx Kind<'tcx>, UserTypeAnnotation<'tcx>,
     UserTypeProjection<'tcx>, PatternTypeProjection<'tcx>
 }
@@ -1057,11 +1077,13 @@
             PatternKind::Wild => PatternKind::Wild,
             PatternKind::AscribeUserType {
                 ref subpattern,
+                variance,
                 ref user_ty,
                 user_ty_span,
             } => PatternKind::AscribeUserType {
                 subpattern: subpattern.fold_with(folder),
                 user_ty: user_ty.fold_with(folder),
+                variance,
                 user_ty_span,
             },
             PatternKind::Binding {
diff --git a/src/librustc_mir/transform/generator.rs b/src/librustc_mir/transform/generator.rs
index 808c3aa..ec0c118 100644
--- a/src/librustc_mir/transform/generator.rs
+++ b/src/librustc_mir/transform/generator.rs
@@ -329,36 +329,6 @@
     }
 }
 
-struct BorrowedLocals(liveness::LiveVarSet<Local>);
-
-fn mark_as_borrowed<'tcx>(place: &Place<'tcx>, locals: &mut BorrowedLocals) {
-    match *place {
-        Place::Local(l) => { locals.0.insert(l); },
-        Place::Promoted(_) |
-        Place::Static(..) => (),
-        Place::Projection(ref proj) => {
-            match proj.elem {
-                // For derefs we don't look any further.
-                // If it pointed to a Local, it would already be borrowed elsewhere
-                ProjectionElem::Deref => (),
-                _ => mark_as_borrowed(&proj.base, locals)
-            }
-        }
-    }
-}
-
-impl<'tcx> Visitor<'tcx> for BorrowedLocals {
-    fn visit_rvalue(&mut self,
-                    rvalue: &Rvalue<'tcx>,
-                    location: Location) {
-        if let Rvalue::Ref(_, _, ref place) = *rvalue {
-            mark_as_borrowed(place, self);
-        }
-
-        self.super_rvalue(rvalue, location)
-    }
-}
-
 fn locals_live_across_suspend_points(
     tcx: TyCtxt<'a, 'tcx, 'tcx>,
     mir: &Mir<'tcx>,
diff --git a/src/librustc_mir/transform/mod.rs b/src/librustc_mir/transform/mod.rs
index 4b7645b..5a80a5f 100644
--- a/src/librustc_mir/transform/mod.rs
+++ b/src/librustc_mir/transform/mod.rs
@@ -26,7 +26,7 @@
 pub mod add_call_guards;
 pub mod promote_consts;
 pub mod qualify_consts;
-mod qualify_min_const_fn;
+pub mod qualify_min_const_fn;
 pub mod remove_noop_landing_pads;
 pub mod dump_mir;
 pub mod deaggregator;
diff --git a/src/librustc_privacy/lib.rs b/src/librustc_privacy/lib.rs
index c6626c1..5015ed0 100644
--- a/src/librustc_privacy/lib.rs
+++ b/src/librustc_privacy/lib.rs
@@ -51,7 +51,8 @@
 /// in `impl Trait`, see individual commits in `DefIdVisitorSkeleton::visit_ty`.
 trait DefIdVisitor<'a, 'tcx: 'a> {
     fn tcx(&self) -> TyCtxt<'a, 'tcx, 'tcx>;
-    fn recurse_into_assoc_tys(&self) -> bool { true }
+    fn shallow(&self) -> bool { false }
+    fn skip_assoc_tys(&self) -> bool { false }
     fn visit_def_id(&mut self, def_id: DefId, kind: &str, descr: &dyn fmt::Display) -> bool;
 
     /// Not overridden, but used to actually visit types and traits.
@@ -86,7 +87,8 @@
 {
     fn visit_trait(&mut self, trait_ref: TraitRef<'tcx>) -> bool {
         let TraitRef { def_id, substs } = trait_ref;
-        self.def_id_visitor.visit_def_id(def_id, "trait", &trait_ref) || substs.visit_with(self)
+        self.def_id_visitor.visit_def_id(def_id, "trait", &trait_ref) ||
+        (!self.def_id_visitor.shallow() && substs.visit_with(self))
     }
 
     fn visit_predicates(&mut self, predicates: Lrc<ty::GenericPredicates<'tcx>>) -> bool {
@@ -138,6 +140,9 @@
                 if self.def_id_visitor.visit_def_id(def_id, "type", ty) {
                     return true;
                 }
+                if self.def_id_visitor.shallow() {
+                    return false;
+                }
                 // Default type visitor doesn't visit signatures of fn types.
                 // Something like `fn() -> Priv {my_func}` is considered a private type even if
                 // `my_func` is public, so we need to visit signatures.
@@ -159,7 +164,7 @@
                 }
             }
             ty::Projection(proj) | ty::UnnormalizedProjection(proj) => {
-                if !self.def_id_visitor.recurse_into_assoc_tys() {
+                if self.def_id_visitor.skip_assoc_tys() {
                     // Visitors searching for minimal visibility/reachability want to
                     // conservatively approximate associated types like `<Type as Trait>::Alias`
                     // as visible/reachable even if both `Type` and `Trait` are private.
@@ -167,10 +172,12 @@
                     // free type aliases, but this isn't done yet.
                     return false;
                 }
-                // This will also visit substs, so we don't need to recurse.
+                // This will also visit substs if necessary, so we don't need to recurse.
                 return self.visit_trait(proj.trait_ref(tcx));
             }
             ty::Dynamic(predicates, ..) => {
+                // All traits in the list are considered the "primary" part of the type
+                // and are visited by shallow visitors.
                 for predicate in *predicates.skip_binder() {
                     let trait_ref = match *predicate {
                         ty::ExistentialPredicate::Trait(trait_ref) => trait_ref,
@@ -187,9 +194,13 @@
             ty::Opaque(def_id, ..) => {
                 // Skip repeated `Opaque`s to avoid infinite recursion.
                 if self.visited_opaque_tys.insert(def_id) {
-                    // Default type visitor doesn't visit traits in `impl Trait`.
-                    // Something like `impl PrivTr` is considered a private type,
-                    // so we need to visit the traits additionally.
+                    // The intent is to treat `impl Trait1 + Trait2` identically to
+                    // `dyn Trait1 + Trait2`. Therefore we ignore def-id of the opaque type itself
+                    // (it either has no visibility, or its visibility is insignificant, like
+                    // visibilities of type aliases) and recurse into predicates instead to go
+                    // through the trait list (default type visitor doesn't visit those traits).
+                    // All traits in the list are considered the "primary" part of the type
+                    // and are visited by shallow visitors.
                     if self.visit_predicates(tcx.predicates_of(def_id)) {
                         return true;
                     }
@@ -206,7 +217,7 @@
                 bug!("unexpected type: {:?}", ty),
         }
 
-        ty.super_visit_with(self)
+        !self.def_id_visitor.shallow() && ty.super_visit_with(self)
     }
 }
 
@@ -325,7 +336,8 @@
 
 impl<'a, 'tcx, VL: VisibilityLike> DefIdVisitor<'a, 'tcx> for FindMin<'a, 'tcx, VL> {
     fn tcx(&self) -> TyCtxt<'a, 'tcx, 'tcx> { self.tcx }
-    fn recurse_into_assoc_tys(&self) -> bool { false }
+    fn shallow(&self) -> bool { VL::SHALLOW }
+    fn skip_assoc_tys(&self) -> bool { true }
     fn visit_def_id(&mut self, def_id: DefId, _kind: &str, _descr: &dyn fmt::Display) -> bool {
         self.min = VL::new_min(self, def_id);
         false
@@ -334,9 +346,10 @@
 
 trait VisibilityLike: Sized {
     const MAX: Self;
+    const SHALLOW: bool = false;
     fn new_min<'a, 'tcx>(find: &FindMin<'a, 'tcx, Self>, def_id: DefId) -> Self;
 
-    // Returns an over-approximation (`recurse_into_assoc_tys` = false) of visibility due to
+    // Returns an over-approximation (`skip_assoc_tys` = true) of visibility due to
     // associated types for which we can't determine visibility precisely.
     fn of_impl<'a, 'tcx>(node_id: ast::NodeId, tcx: TyCtxt<'a, 'tcx, 'tcx>,
                          access_levels: &'a AccessLevels) -> Self {
@@ -357,6 +370,16 @@
 }
 impl VisibilityLike for Option<AccessLevel> {
     const MAX: Self = Some(AccessLevel::Public);
+    // Type inference is very smart sometimes.
+    // It can make an impl reachable even some components of its type or trait are unreachable.
+    // E.g. methods of `impl ReachableTrait<UnreachableTy> for ReachableTy<UnreachableTy> { ... }`
+    // can be usable from other crates (#57264). So we skip substs when calculating reachability
+    // and consider an impl reachable if its "shallow" type and trait are reachable.
+    //
+    // The assumption we make here is that type-inference won't let you use an impl without knowing
+    // both "shallow" version of its self type and "shallow" version of its trait if it exists
+    // (which require reaching the `DefId`s in them).
+    const SHALLOW: bool = true;
     fn new_min<'a, 'tcx>(find: &FindMin<'a, 'tcx, Self>, def_id: DefId) -> Self {
         cmp::min(if let Some(node_id) = find.tcx.hir().as_local_node_id(def_id) {
             find.access_levels.map.get(&node_id).cloned()
@@ -542,7 +565,7 @@
             // Visit everything except for private impl items.
             hir::ItemKind::Impl(.., ref impl_item_refs) => {
                 if item_level.is_some() {
-                    self.reach(item.id, item_level).generics().predicates();
+                    self.reach(item.id, item_level).generics().predicates().ty().trait_ref();
 
                     for impl_item_ref in impl_item_refs {
                         let impl_item_level = self.get(impl_item_ref.id.node_id);
@@ -701,6 +724,13 @@
         self.visit(self.ev.tcx.type_of(self.item_def_id));
         self
     }
+
+    fn trait_ref(&mut self) -> &mut Self {
+        if let Some(trait_ref) = self.ev.tcx.impl_trait_ref(self.item_def_id) {
+            self.visit_trait(trait_ref);
+        }
+        self
+    }
 }
 
 impl<'a, 'tcx> DefIdVisitor<'a, 'tcx> for ReachEverythingInTheInterfaceVisitor<'_, 'a, 'tcx> {
diff --git a/src/librustc_resolve/diagnostics.rs b/src/librustc_resolve/diagnostics.rs
index 84a9c80..3f9c5f4 100644
--- a/src/librustc_resolve/diagnostics.rs
+++ b/src/librustc_resolve/diagnostics.rs
@@ -192,7 +192,7 @@
 fn main() {}
 ```
 
-To fix issue issue, you have to rename at least one of the two imports.
+To fix this issue, you have to rename at least one of the two imports.
 Example:
 
 ```
diff --git a/src/librustc_save_analysis/dump_visitor.rs b/src/librustc_save_analysis/dump_visitor.rs
index 3c83c45..8915373 100644
--- a/src/librustc_save_analysis/dump_visitor.rs
+++ b/src/librustc_save_analysis/dump_visitor.rs
@@ -14,7 +14,7 @@
 //! recording the output.
 
 use rustc::hir::def::Def as HirDef;
-use rustc::hir::def_id::DefId;
+use rustc::hir::def_id::{DefId, LOCAL_CRATE};
 use rustc::session::config::Input;
 use rustc::ty::{self, TyCtxt};
 use rustc_data_structures::fx::FxHashSet;
@@ -56,14 +56,14 @@
     ($save_ctxt:expr, $vis:expr, $id:expr) => {
         Access {
             public: $vis.node.is_pub(),
-            reachable: $save_ctxt.analysis.access_levels.is_reachable($id),
+            reachable: $save_ctxt.tcx.privacy_access_levels(LOCAL_CRATE).is_reachable($id),
         }
     };
 
     ($save_ctxt:expr, $item:expr) => {
         Access {
             public: $item.vis.node.is_pub(),
-            reachable: $save_ctxt.analysis.access_levels.is_reachable($item.id),
+            reachable: $save_ctxt.tcx.privacy_access_levels(LOCAL_CRATE).is_reachable($item.id),
         }
     };
 }
diff --git a/src/librustc_typeck/astconv.rs b/src/librustc_typeck/astconv.rs
index 41ecfaa..8e5eaa1 100644
--- a/src/librustc_typeck/astconv.rs
+++ b/src/librustc_typeck/astconv.rs
@@ -1,6 +1,6 @@
 //! Conversion from AST representation of types to the `ty.rs` representation.
-//! The main routine here is `ast_ty_to_ty()`; each use is is parameterized by
-//! an instance of `AstConv`.
+//! The main routine here is `ast_ty_to_ty()`; each use is parameterized by an
+//! instance of `AstConv`.
 
 use errors::{Applicability, FatalError, DiagnosticId};
 use hir::{self, GenericArg, GenericArgs};
diff --git a/src/librustc_typeck/check/closure.rs b/src/librustc_typeck/check/closure.rs
index ff3b22d..df83c92 100644
--- a/src/librustc_typeck/check/closure.rs
+++ b/src/librustc_typeck/check/closure.rs
@@ -496,7 +496,7 @@
         self.infcx.commit_if_ok(|_| {
             let mut all_obligations = vec![];
 
-            // The liberated version of this signature should be be a subtype
+            // The liberated version of this signature should be a subtype
             // of the liberated form of the expectation.
             for ((hir_ty, &supplied_ty), expected_ty) in decl.inputs.iter()
                .zip(*supplied_sig.inputs().skip_binder()) // binder moved to (*) below
diff --git a/src/librustc_typeck/check/demand.rs b/src/librustc_typeck/check/demand.rs
index 7a788f2..41f2b0e 100644
--- a/src/librustc_typeck/check/demand.rs
+++ b/src/librustc_typeck/check/demand.rs
@@ -335,7 +335,7 @@
                 // we may want to suggest adding a `*`, or removing
                 // a `&`.
                 //
-                // (But, also check check the `expn_info()` to see if this is
+                // (But, also check the `expn_info()` to see if this is
                 // a macro; if so, it's hard to extract the text and make a good
                 // suggestion, so don't bother.)
                 if self.infcx.can_sub(self.param_env, checked, &expected).is_ok() &&
diff --git a/src/librustc_typeck/check/intrinsic.rs b/src/librustc_typeck/check/intrinsic.rs
index a36b219..821c30b 100644
--- a/src/librustc_typeck/check/intrinsic.rs
+++ b/src/librustc_typeck/check/intrinsic.rs
@@ -133,6 +133,7 @@
                  ], tcx.types.usize)
             }
             "rustc_peek" => (1, vec![param(0)], param(0)),
+            "panic_if_uninhabited" => (1, Vec::new(), tcx.mk_unit()),
             "init" => (1, Vec::new(), param(0)),
             "uninit" => (1, Vec::new(), param(0)),
             "forget" => (1, vec![param(0)], tcx.mk_unit()),
diff --git a/src/librustc_typeck/check/method/mod.rs b/src/librustc_typeck/check/method/mod.rs
index 1758f76..02687df 100644
--- a/src/librustc_typeck/check/method/mod.rs
+++ b/src/librustc_typeck/check/method/mod.rs
@@ -11,6 +11,7 @@
 pub use self::suggest::{SelfSource, TraitInfo};
 
 use check::FnCtxt;
+use errors::{Applicability, DiagnosticBuilder};
 use namespace::Namespace;
 use rustc_data_structures::sync::Lrc;
 use rustc::hir;
@@ -123,6 +124,42 @@
         }
     }
 
+    /// Add a suggestion to call the given method to the provided diagnostic.
+    crate fn suggest_method_call(
+        &self,
+        err: &mut DiagnosticBuilder<'a>,
+        msg: &str,
+        method_name: ast::Ident,
+        self_ty: Ty<'tcx>,
+        call_expr_id: ast::NodeId,
+    ) {
+        let has_params = self
+            .probe_for_name(
+                method_name.span,
+                probe::Mode::MethodCall,
+                method_name,
+                IsSuggestion(false),
+                self_ty,
+                call_expr_id,
+                ProbeScope::TraitsInScope,
+            )
+            .and_then(|pick| {
+                let sig = self.tcx.fn_sig(pick.item.def_id);
+                Ok(sig.inputs().skip_binder().len() > 1)
+            });
+
+        let (suggestion, applicability) = if has_params.unwrap_or_default() {
+            (
+                format!("{}(...)", method_name),
+                Applicability::HasPlaceholders,
+            )
+        } else {
+            (format!("{}()", method_name), Applicability::MaybeIncorrect)
+        };
+
+        err.span_suggestion_with_applicability(method_name.span, msg, suggestion, applicability);
+    }
+
     /// Performs method lookup. If lookup is successful, it will return the callee
     /// and store an appropriate adjustment for the self-expr. In some cases it may
     /// report an error (e.g., invoking the `drop` method).
diff --git a/src/librustc_typeck/check/mod.rs b/src/librustc_typeck/check/mod.rs
index b2ea170..1a5d164 100644
--- a/src/librustc_typeck/check/mod.rs
+++ b/src/librustc_typeck/check/mod.rs
@@ -3442,19 +3442,37 @@
                                            "field `{}` of struct `{}` is private",
                                            field, struct_path);
             // Also check if an accessible method exists, which is often what is meant.
-            if self.method_exists(field, expr_t, expr.id, false) {
-                err.note(&format!("a method `{}` also exists, perhaps you wish to call it", field));
+            if self.method_exists(field, expr_t, expr.id, false) && !self.expr_in_place(expr.id) {
+                self.suggest_method_call(
+                    &mut err,
+                    &format!("a method `{}` also exists, call it with parentheses", field),
+                    field,
+                    expr_t,
+                    expr.id,
+                );
             }
             err.emit();
             field_ty
         } else if field.name == keywords::Invalid.name() {
             self.tcx().types.err
         } else if self.method_exists(field, expr_t, expr.id, true) {
-            type_error_struct!(self.tcx().sess, field.span, expr_t, E0615,
+            let mut err = type_error_struct!(self.tcx().sess, field.span, expr_t, E0615,
                                "attempted to take value of method `{}` on type `{}`",
-                               field, expr_t)
-                .help("maybe a `()` to call it is missing?")
-                .emit();
+                               field, expr_t);
+
+            if !self.expr_in_place(expr.id) {
+                self.suggest_method_call(
+                    &mut err,
+                    "use parentheses to call the method",
+                    field,
+                    expr_t,
+                    expr.id
+                );
+            } else {
+                err.help("methods are immutable and cannot be assigned to");
+            }
+
+            err.emit();
             self.tcx().types.err
         } else {
             if !expr_t.is_primitive_ty() {
@@ -4843,11 +4861,31 @@
                 // #41425 -- label the implicit `()` as being the
                 // "found type" here, rather than the "expected type".
                 if !self.diverges.get().always() {
-                    coerce.coerce_forced_unit(self, &self.misc(blk.span), &mut |err| {
+                    // #50009 -- Do not point at the entire fn block span, point at the return type
+                    // span, as it is the cause of the requirement, and
+                    // `consider_hint_about_removing_semicolon` will point at the last expression
+                    // if it were a relevant part of the error. This improves usability in editors
+                    // that highlight errors inline.
+                    let mut sp = blk.span;
+                    let mut fn_span = None;
+                    if let Some((decl, ident)) = self.get_parent_fn_decl(blk.id) {
+                        let ret_sp = decl.output.span();
+                        if let Some(block_sp) = self.parent_item_span(blk.id) {
+                            // HACK: on some cases (`ui/liveness/liveness-issue-2163.rs`) the
+                            // output would otherwise be incorrect and even misleading. Make sure
+                            // the span we're aiming at correspond to a `fn` body.
+                            if block_sp == blk.span {
+                                sp = ret_sp;
+                                fn_span = Some(ident.span);
+                            }
+                        }
+                    }
+                    coerce.coerce_forced_unit(self, &self.misc(sp), &mut |err| {
                         if let Some(expected_ty) = expected.only_has_type(self) {
-                            self.consider_hint_about_removing_semicolon(blk,
-                                                                        expected_ty,
-                                                                        err);
+                            self.consider_hint_about_removing_semicolon(blk, expected_ty, err);
+                        }
+                        if let Some(fn_span) = fn_span {
+                            err.span_label(fn_span, "this function's body doesn't return");
                         }
                     }, false);
                 }
@@ -4872,45 +4910,65 @@
         ty
     }
 
+    fn parent_item_span(&self, id: ast::NodeId) -> Option<Span> {
+        let node = self.tcx.hir().get(self.tcx.hir().get_parent(id));
+        match node {
+            Node::Item(&hir::Item {
+                node: hir::ItemKind::Fn(_, _, _, body_id), ..
+            }) |
+            Node::ImplItem(&hir::ImplItem {
+                node: hir::ImplItemKind::Method(_, body_id), ..
+            }) => {
+                let body = self.tcx.hir().body(body_id);
+                if let ExprKind::Block(block, _) = &body.value.node {
+                    return Some(block.span);
+                }
+            }
+            _ => {}
+        }
+        None
+    }
+
+    /// Given a function block's `NodeId`, return its `FnDecl` if it exists, or `None` otherwise.
+    fn get_parent_fn_decl(&self, blk_id: ast::NodeId) -> Option<(hir::FnDecl, ast::Ident)> {
+        let parent = self.tcx.hir().get(self.tcx.hir().get_parent(blk_id));
+        self.get_node_fn_decl(parent).map(|(fn_decl, ident, _)| (fn_decl, ident))
+    }
+
+    /// Given a function `Node`, return its `FnDecl` if it exists, or `None` otherwise.
+    fn get_node_fn_decl(&self, node: Node) -> Option<(hir::FnDecl, ast::Ident, bool)> {
+        match node {
+            Node::Item(&hir::Item {
+                ident, node: hir::ItemKind::Fn(ref decl, ..), ..
+            }) => decl.clone().and_then(|decl| {
+                // This is less than ideal, it will not suggest a return type span on any
+                // method called `main`, regardless of whether it is actually the entry point,
+                // but it will still present it as the reason for the expected type.
+                Some((decl, ident, ident.name != Symbol::intern("main")))
+            }),
+            Node::TraitItem(&hir::TraitItem {
+                ident, node: hir::TraitItemKind::Method(hir::MethodSig {
+                    ref decl, ..
+                }, ..), ..
+            }) => decl.clone().and_then(|decl| Some((decl, ident, true))),
+            Node::ImplItem(&hir::ImplItem {
+                ident, node: hir::ImplItemKind::Method(hir::MethodSig {
+                    ref decl, ..
+                }, ..), ..
+            }) => decl.clone().and_then(|decl| Some((decl, ident, false))),
+            _ => None,
+        }
+    }
+
     /// Given a `NodeId`, return the `FnDecl` of the method it is enclosed by and whether a
     /// suggestion can be made, `None` otherwise.
     pub fn get_fn_decl(&self, blk_id: ast::NodeId) -> Option<(hir::FnDecl, bool)> {
         // Get enclosing Fn, if it is a function or a trait method, unless there's a `loop` or
         // `while` before reaching it, as block tail returns are not available in them.
-        if let Some(fn_id) = self.tcx.hir().get_return_block(blk_id) {
-            let parent = self.tcx.hir().get(fn_id);
-
-            if let Node::Item(&hir::Item {
-                ident, node: hir::ItemKind::Fn(ref decl, ..), ..
-            }) = parent {
-                decl.clone().and_then(|decl| {
-                    // This is less than ideal, it will not suggest a return type span on any
-                    // method called `main`, regardless of whether it is actually the entry point,
-                    // but it will still present it as the reason for the expected type.
-                    Some((decl, ident.name != Symbol::intern("main")))
-                })
-            } else if let Node::TraitItem(&hir::TraitItem {
-                node: hir::TraitItemKind::Method(hir::MethodSig {
-                    ref decl, ..
-                }, ..), ..
-            }) = parent {
-                decl.clone().and_then(|decl| {
-                    Some((decl, true))
-                })
-            } else if let Node::ImplItem(&hir::ImplItem {
-                node: hir::ImplItemKind::Method(hir::MethodSig {
-                    ref decl, ..
-                }, ..), ..
-            }) = parent {
-                decl.clone().and_then(|decl| {
-                    Some((decl, false))
-                })
-            } else {
-                None
-            }
-        } else {
-            None
-        }
+        self.tcx.hir().get_return_block(blk_id).and_then(|blk_id| {
+            let parent = self.tcx.hir().get(blk_id);
+            self.get_node_fn_decl(parent).map(|(fn_decl, _, is_main)| (fn_decl, is_main))
+        })
     }
 
     /// On implicit return expressions with mismatched types, provide the following suggestions:
@@ -4918,13 +4976,15 @@
     ///  - Point out the method's return type as the reason for the expected type
     ///  - Possible missing semicolon
     ///  - Possible missing return type if the return type is the default, and not `fn main()`
-    pub fn suggest_mismatched_types_on_tail(&self,
-                                            err: &mut DiagnosticBuilder<'tcx>,
-                                            expression: &'gcx hir::Expr,
-                                            expected: Ty<'tcx>,
-                                            found: Ty<'tcx>,
-                                            cause_span: Span,
-                                            blk_id: ast::NodeId) {
+    pub fn suggest_mismatched_types_on_tail(
+        &self,
+        err: &mut DiagnosticBuilder<'tcx>,
+        expression: &'gcx hir::Expr,
+        expected: Ty<'tcx>,
+        found: Ty<'tcx>,
+        cause_span: Span,
+        blk_id: ast::NodeId,
+    ) {
         self.suggest_missing_semicolon(err, expression, expected, cause_span);
         if let Some((fn_decl, can_suggest)) = self.get_fn_decl(blk_id) {
             self.suggest_missing_return_type(err, &fn_decl, expected, found, can_suggest);
@@ -5465,6 +5525,28 @@
             original_values,
             query_result)
     }
+
+    /// Returns whether an expression is contained inside the LHS of an assignment expression.
+    fn expr_in_place(&self, mut expr_id: ast::NodeId) -> bool {
+        let mut contained_in_place = false;
+
+        while let hir::Node::Expr(parent_expr) =
+            self.tcx.hir().get(self.tcx.hir().get_parent_node(expr_id))
+        {
+            match &parent_expr.node {
+                hir::ExprKind::Assign(lhs, ..) | hir::ExprKind::AssignOp(_, lhs, ..) => {
+                    if lhs.id == expr_id {
+                        contained_in_place = true;
+                        break;
+                    }
+                }
+                _ => (),
+            }
+            expr_id = parent_expr.id;
+        }
+
+        contained_in_place
+    }
 }
 
 pub fn check_bounds_are_used<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>,
diff --git a/src/librustdoc/clean/auto_trait.rs b/src/librustdoc/clean/auto_trait.rs
index bdd2b05..27ca205 100644
--- a/src/librustdoc/clean/auto_trait.rs
+++ b/src/librustdoc/clean/auto_trait.rs
@@ -534,7 +534,7 @@
             did, param_env, type_generics, existing_predicates
         );
 
-        // The `Sized` trait must be handled specially, since we only only display it when
+        // The `Sized` trait must be handled specially, since we only display it when
         // it is *not* required (i.e., '?Sized')
         let sized_trait = self.cx
             .tcx
diff --git a/src/librustdoc/core.rs b/src/librustdoc/core.rs
index 032b0fc..8bb0dc9 100644
--- a/src/librustdoc/core.rs
+++ b/src/librustdoc/core.rs
@@ -476,8 +476,6 @@
             }).collect(),
         };
         let analysis = ty::CrateAnalysis {
-            access_levels: Lrc::new(AccessLevels::default()),
-            name: name.to_string(),
             glob_map: if resolver.make_glob_map { Some(resolver.glob_map.clone()) } else { None },
         };
 
@@ -500,12 +498,12 @@
                                                         &mut arenas,
                                                         &name,
                                                         &output_filenames,
-                                                        |tcx, analysis, _, result| {
+                                                        |tcx, _, _, result| {
             if result.is_err() {
                 sess.fatal("Compilation failed, aborting rustdoc");
             }
 
-            let ty::CrateAnalysis { access_levels, .. } = analysis;
+            let access_levels = tcx.privacy_access_levels(LOCAL_CRATE);
 
             // Convert from a NodeId set to a DefId set since we don't always have easy access
             // to the map from defid -> nodeid
diff --git a/src/librustdoc/test.rs b/src/librustdoc/test.rs
index dd9fbbb..2170054 100644
--- a/src/librustdoc/test.rs
+++ b/src/librustdoc/test.rs
@@ -278,7 +278,7 @@
         target_features::add_configuration(&mut cfg, &sess, &*codegen_backend);
         sess.parse_sess.config = cfg;
 
-        let out = Some(outdir.lock().unwrap().path().to_path_buf());
+        let out = Some(outdir.lock().unwrap().path().join("rust_out"));
 
         if no_run {
             control.after_analysis.stop = Compilation::Stop;
@@ -291,8 +291,8 @@
                 &cstore,
                 &None,
                 &input,
-                &out,
                 &None,
+                &out,
                 None,
                 &control
             )
diff --git a/src/libstd/collections/hash/set.rs b/src/libstd/collections/hash/set.rs
index aebd0eb..9214590 100644
--- a/src/libstd/collections/hash/set.rs
+++ b/src/libstd/collections/hash/set.rs
@@ -179,7 +179,7 @@
         HashSet { map: HashMap::with_hasher(hasher) }
     }
 
-    /// Creates an empty `HashSet` with with the specified capacity, using
+    /// Creates an empty `HashSet` with the specified capacity, using
     /// `hasher` to hash the keys.
     ///
     /// The hash set will be able to hold at least `capacity` elements without
diff --git a/src/libstd/io/mod.rs b/src/libstd/io/mod.rs
index 040669b..0991957 100644
--- a/src/libstd/io/mod.rs
+++ b/src/libstd/io/mod.rs
@@ -948,7 +948,7 @@
 #[stable(feature = "rust1", since = "1.0.0")]
 #[doc(spotlight)]
 pub trait Write {
-    /// Write a buffer into this object, returning how many bytes were written.
+    /// Write a buffer into this writer, returning how many bytes were written.
     ///
     /// This function will attempt to write the entire contents of `buf`, but
     /// the entire write may not succeed, or the write may also generate an
@@ -1023,7 +1023,7 @@
     #[stable(feature = "rust1", since = "1.0.0")]
     fn flush(&mut self) -> Result<()>;
 
-    /// Attempts to write an entire buffer into this write.
+    /// Attempts to write an entire buffer into this writer.
     ///
     /// This method will continuously call [`write`] until there is no more data
     /// to be written or an error of non-[`ErrorKind::Interrupted`] kind is
diff --git a/src/libstd/keyword_docs.rs b/src/libstd/keyword_docs.rs
index 4ca62cc..a7ecee2 100644
--- a/src/libstd/keyword_docs.rs
+++ b/src/libstd/keyword_docs.rs
@@ -47,8 +47,8 @@
 ///
 /// Constants must be explicitly typed, unlike with `let` you can't ignore its type and let the
 /// compiler figure it out. Any constant value can be defined in a const, which in practice happens
-/// to be most things that would be reasonable to have a constant (barring `const fn`s, coming
-/// soon). For example, you can't have a File as a `const`.
+/// to be most things that would be reasonable to have a constant (barring `const fn`s). For
+/// example, you can't have a File as a `const`.
 ///
 /// The only lifetime allowed in a constant is `'static`, which is the lifetime that encompasses
 /// all others in a Rust program. For example, if you wanted to define a constant string, it would
@@ -169,7 +169,7 @@
 ///
 /// [Algebraic Data Types]: https://en.wikipedia.org/wiki/Algebraic_data_type
 /// [`Option`]: option/enum.Option.html
-/// [Rust Book]: https://doc.rust-lang.org/book/second-edition/ch06-01-defining-an-enum.html
+/// [Rust Book]: https://doc.rust-lang.org/book/ch06-01-defining-an-enum.html
 /// [Reference]: https://doc.rust-lang.org/reference/items/enumerations.html
 mod enum_keyword { }
 
@@ -211,7 +211,7 @@
 /// For more information on FFI, check the [Rust book] or the [Reference].
 ///
 /// [Rust book]:
-/// https://doc.rust-lang.org/book/second-edition/ch19-01-unsafe-rust.html#using-extern-functions-to-call-external-code
+/// https://doc.rust-lang.org/book/ch19-01-unsafe-rust.html#using-extern-functions-to-call-external-code
 /// [Reference]: https://doc.rust-lang.org/reference/items/external-blocks.html
 mod extern_keyword { }
 
@@ -278,7 +278,7 @@
 ///
 /// [`impl`]: keyword.impl.html
 /// [`extern`]: keyword.extern.html
-/// [Rust book]: https://doc.rust-lang.org/book/second-edition/ch03-03-how-functions-work.html
+/// [Rust book]: https://doc.rust-lang.org/book/ch03-03-how-functions-work.html
 /// [Reference]: https://doc.rust-lang.org/reference/items/functions.html
 mod fn_keyword { }
 
@@ -705,6 +705,6 @@
 /// [Reference][reference].
 ///
 /// [`PhantomData`]: marker/struct.PhantomData.html
-/// [book]: https://doc.rust-lang.org/book/second-edition/ch05-01-defining-structs.html
+/// [book]: https://doc.rust-lang.org/book/ch05-01-defining-structs.html
 /// [reference]: https://doc.rust-lang.org/reference/items/structs.html
 mod struct_keyword { }
diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs
index d42e39f..ccfce67 100644
--- a/src/libstd/lib.rs
+++ b/src/libstd/lib.rs
@@ -248,6 +248,7 @@
 #![feature(const_cstr_unchecked)]
 #![feature(core_intrinsics)]
 #![feature(dropck_eyepatch)]
+#![feature(duration_constants)]
 #![feature(exact_size_is_empty)]
 #![feature(external_doc)]
 #![feature(fixed_size_array)]
diff --git a/src/libstd/macros.rs b/src/libstd/macros.rs
index c92365d..b872571 100644
--- a/src/libstd/macros.rs
+++ b/src/libstd/macros.rs
@@ -322,6 +322,7 @@
     }
 }
 
+/// A macro to await on an async call.
 #[macro_export]
 #[unstable(feature = "await_macro", issue = "50547")]
 #[allow_internal_unstable]
diff --git a/src/libstd/primitive_docs.rs b/src/libstd/primitive_docs.rs
index 7755d93..475c9b4 100644
--- a/src/libstd/primitive_docs.rs
+++ b/src/libstd/primitive_docs.rs
@@ -923,7 +923,7 @@
 /// For more information on how to use references, see [the book's section on "References and
 /// Borrowing"][book-refs].
 ///
-/// [book-refs]: ../book/second-edition/ch04-02-references-and-borrowing.html
+/// [book-refs]: ../book/ch04-02-references-and-borrowing.html
 ///
 /// # Trait implementations
 ///
diff --git a/src/libstd/sys/cloudabi/abi/cloudabi.rs b/src/libstd/sys/cloudabi/abi/cloudabi.rs
index cd9a5ad..aac1804 100644
--- a/src/libstd/sys/cloudabi/abi/cloudabi.rs
+++ b/src/libstd/sys/cloudabi/abi/cloudabi.rs
@@ -107,7 +107,7 @@
 //!
 //! ## Specification of the ABI
 //!
-//! The entire ABI is specified in a a file called
+//! The entire ABI is specified in a file called
 //! [`cloudabi.txt`](https://github.com/NuxiNL/cloudabi/blob/master/cloudabi.txt),
 //! from which all
 //! [headers](https://github.com/NuxiNL/cloudabi/tree/master/headers)
diff --git a/src/libstd/sys/cloudabi/time.rs b/src/libstd/sys/cloudabi/time.rs
index 906beba4..545e3c0 100644
--- a/src/libstd/sys/cloudabi/time.rs
+++ b/src/libstd/sys/cloudabi/time.rs
@@ -25,6 +25,14 @@
         }
     }
 
+    pub fn actually_monotonic() -> bool {
+        true
+    }
+
+    pub const fn zero() -> Instant {
+        Instant { t: 0 }
+    }
+
     pub fn sub_instant(&self, other: &Instant) -> Duration {
         let diff = self.t
             .checked_sub(other.t)
diff --git a/src/libstd/sys/redox/time.rs b/src/libstd/sys/redox/time.rs
index b327235..401b701 100644
--- a/src/libstd/sys/redox/time.rs
+++ b/src/libstd/sys/redox/time.rs
@@ -128,6 +128,14 @@
         Instant { t: now(syscall::CLOCK_MONOTONIC) }
     }
 
+    pub const fn zero() -> Instant {
+        Instant { t: Timespec { t: syscall::TimeSpec { tv_sec: 0, tv_nsec: 0 } } }
+    }
+
+    pub fn actually_monotonic() -> bool {
+        false
+    }
+
     pub fn sub_instant(&self, other: &Instant) -> Duration {
         self.t.sub_timespec(&other.t).unwrap_or_else(|_| {
             panic!("specified instant was later than self")
diff --git a/src/libstd/sys/unix/time.rs b/src/libstd/sys/unix/time.rs
index 073c0d0..4a65571 100644
--- a/src/libstd/sys/unix/time.rs
+++ b/src/libstd/sys/unix/time.rs
@@ -14,6 +14,12 @@
 }
 
 impl Timespec {
+    const fn zero() -> Timespec {
+        Timespec {
+            t: libc::timespec { tv_sec: 0, tv_nsec: 0 },
+        }
+    }
+
     fn sub_timespec(&self, other: &Timespec) -> Result<Duration, Duration> {
         if self >= other {
             Ok(if self.t.tv_nsec >= other.t.tv_nsec {
@@ -128,12 +134,7 @@
     }
 
     pub const UNIX_EPOCH: SystemTime = SystemTime {
-        t: Timespec {
-            t: libc::timespec {
-                tv_sec: 0,
-                tv_nsec: 0,
-            },
-        },
+        t: Timespec::zero(),
     };
 
     impl Instant {
@@ -141,6 +142,14 @@
             Instant { t: unsafe { libc::mach_absolute_time() } }
         }
 
+        pub const fn zero() -> Instant {
+            Instant { t: 0 }
+        }
+
+        pub fn actually_monotonic() -> bool {
+            true
+        }
+
         pub fn sub_instant(&self, other: &Instant) -> Duration {
             let info = info();
             let diff = self.t.checked_sub(other.t)
@@ -258,12 +267,7 @@
     }
 
     pub const UNIX_EPOCH: SystemTime = SystemTime {
-        t: Timespec {
-            t: libc::timespec {
-                tv_sec: 0,
-                tv_nsec: 0,
-            },
-        },
+        t: Timespec::zero(),
     };
 
     impl Instant {
@@ -271,6 +275,18 @@
             Instant { t: now(libc::CLOCK_MONOTONIC) }
         }
 
+        pub const fn zero() -> Instant {
+            Instant {
+                t: Timespec::zero(),
+            }
+        }
+
+        pub fn actually_monotonic() -> bool {
+            (cfg!(target_os = "linux") && cfg!(target_arch = "x86_64")) ||
+            (cfg!(target_os = "linux") && cfg!(target_arch = "x86")) ||
+            false // last clause, used so `||` is always trailing above
+        }
+
         pub fn sub_instant(&self, other: &Instant) -> Duration {
             self.t.sub_timespec(&other.t).unwrap_or_else(|_| {
                 panic!("specified instant was later than self")
diff --git a/src/libstd/sys/wasm/time.rs b/src/libstd/sys/wasm/time.rs
index a5c41d4..3179846 100644
--- a/src/libstd/sys/wasm/time.rs
+++ b/src/libstd/sys/wasm/time.rs
@@ -14,6 +14,14 @@
         Instant(TimeSysCall::perform(TimeClock::Monotonic))
     }
 
+    pub const fn zero() -> Instant {
+        Instant(Duration::from_secs(0))
+    }
+
+    pub fn actually_monotonic() -> bool {
+        false
+    }
+
     pub fn sub_instant(&self, other: &Instant) -> Duration {
         self.0 - other.0
     }
diff --git a/src/libstd/sys/windows/backtrace/mod.rs b/src/libstd/sys/windows/backtrace/mod.rs
index a6bd8f8..4bda8ac 100644
--- a/src/libstd/sys/windows/backtrace/mod.rs
+++ b/src/libstd/sys/windows/backtrace/mod.rs
@@ -103,7 +103,7 @@
         frames[i] = Frame {
             symbol_addr: addr,
             exact_position: addr,
-            inline_context: 0,
+            inline_context: frame.get_inline_context(),
         };
 
         i += 1
@@ -209,6 +209,7 @@
     fn new() -> Self;
     fn init(&mut self, ctx: &c::CONTEXT) -> c::DWORD;
     fn get_addr(&self) -> *const u8;
+    fn get_inline_context(&self) -> u32;
 }
 
 impl StackFrame for c::STACKFRAME_EX {
@@ -263,6 +264,10 @@
     fn get_addr(&self) -> *const u8 {
         (self.AddrPC.Offset - 1) as *const u8
     }
+
+    fn get_inline_context(&self) -> u32 {
+        self.InlineFrameContext
+    }
 }
 
 impl StackFrame for c::STACKFRAME64 {
@@ -317,6 +322,10 @@
     fn get_addr(&self) -> *const u8 {
         (self.AddrPC.Offset - 1) as *const u8
     }
+
+    fn get_inline_context(&self) -> u32 {
+        0
+    }
 }
 
 enum StackWalkVariant {
diff --git a/src/libstd/sys/windows/ext/fs.rs b/src/libstd/sys/windows/ext/fs.rs
index 8eaf58a..6342af4 100644
--- a/src/libstd/sys/windows/ext/fs.rs
+++ b/src/libstd/sys/windows/ext/fs.rs
@@ -126,7 +126,7 @@
     ///
     /// By default `share_mode` is set to
     /// `FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE`. This allows
-    /// other processes to to read, write, and delete/rename the same file
+    /// other processes to read, write, and delete/rename the same file
     /// while it is open. Removing any of the flags will prevent other
     /// processes from performing the corresponding operation until the file
     /// handle is closed.
diff --git a/src/libstd/sys/windows/time.rs b/src/libstd/sys/windows/time.rs
index 60c9695..8e8e919 100644
--- a/src/libstd/sys/windows/time.rs
+++ b/src/libstd/sys/windows/time.rs
@@ -40,6 +40,14 @@
         t
     }
 
+    pub fn actually_monotonic() -> bool {
+        false
+    }
+
+    pub const fn zero() -> Instant {
+        Instant { t: 0 }
+    }
+
     pub fn sub_instant(&self, other: &Instant) -> Duration {
         // Values which are +- 1 need to be considered as basically the same
         // units in time due to various measurement oddities, according to
diff --git a/src/libstd/time.rs b/src/libstd/time.rs
index eb67b71..507ea39 100644
--- a/src/libstd/time.rs
+++ b/src/libstd/time.rs
@@ -12,15 +12,20 @@
 
 #![stable(feature = "time", since = "1.3.0")]
 
+use cmp;
 use error::Error;
 use fmt;
 use ops::{Add, Sub, AddAssign, SubAssign};
 use sys::time;
 use sys_common::FromInner;
+use sys_common::mutex::Mutex;
 
 #[stable(feature = "time", since = "1.3.0")]
 pub use core::time::Duration;
 
+#[unstable(feature = "duration_constants", issue = "57391")]
+pub use core::time::{SECOND, MILLISECOND, MICROSECOND, NANOSECOND};
+
 /// A measurement of a monotonically nondecreasing clock.
 /// Opaque and useful only with `Duration`.
 ///
@@ -150,7 +155,45 @@
     /// ```
     #[stable(feature = "time2", since = "1.8.0")]
     pub fn now() -> Instant {
-        Instant(time::Instant::now())
+        let os_now = time::Instant::now();
+
+        // And here we come upon a sad state of affairs. The whole point of
+        // `Instant` is that it's monotonically increasing. We've found in the
+        // wild, however, that it's not actually monotonically increasing for
+        // one reason or another. These appear to be OS and hardware level bugs,
+        // and there's not really a whole lot we can do about them. Here's a
+        // taste of what we've found:
+        //
+        // * #48514 - OpenBSD, x86_64
+        // * #49281 - linux arm64 and s390x
+        // * #51648 - windows, x86
+        // * #56560 - windows, x86_64, AWS
+        // * #56612 - windows, x86, vm (?)
+        // * #56940 - linux, arm64
+        // * https://bugzilla.mozilla.org/show_bug.cgi?id=1487778 - a similar
+        //   Firefox bug
+        //
+        // It simply seems that this it just happens so that a lot in the wild
+        // we're seeing panics across various platforms where consecutive calls
+        // to `Instant::now`, such as via the `elapsed` function, are panicking
+        // as they're going backwards. Placed here is a last-ditch effort to try
+        // to fix things up. We keep a global "latest now" instance which is
+        // returned instead of what the OS says if the OS goes backwards.
+        //
+        // To hopefully mitigate the impact of this though a few platforms are
+        // whitelisted as "these at least haven't gone backwards yet".
+        if time::Instant::actually_monotonic() {
+            return Instant(os_now)
+        }
+
+        static LOCK: Mutex = Mutex::new();
+        static mut LAST_NOW: time::Instant = time::Instant::zero();
+        unsafe {
+            let _lock = LOCK.lock();
+            let now = cmp::max(LAST_NOW, os_now);
+            LAST_NOW = now;
+            Instant(now)
+        }
     }
 
     /// Returns the amount of time elapsed from another instant to this one.
diff --git a/src/libsyntax/config.rs b/src/libsyntax/config.rs
index 9eebbed..a987f53 100644
--- a/src/libsyntax/config.rs
+++ b/src/libsyntax/config.rs
@@ -5,7 +5,6 @@
     Features,
     get_features,
     GateIssue,
-    emit_feature_err,
 };
 use {fold, attr};
 use ast;
@@ -94,13 +93,6 @@
             return vec![attr];
         }
 
-        let gate_cfg_attr_multi = if let Some(ref features) = self.features {
-            !features.cfg_attr_multi
-        } else {
-            false
-        };
-        let cfg_attr_span = attr.span;
-
         let (cfg_predicate, expanded_attrs) = match attr.parse(self.sess, |parser| {
             parser.expect(&token::OpenDelim(token::Paren))?;
 
@@ -130,21 +122,8 @@
         // Check feature gate and lint on zero attributes in source. Even if the feature is gated,
         // we still compute as if it wasn't, since the emitted error will stop compilation further
         // along the compilation.
-        match (expanded_attrs.len(), gate_cfg_attr_multi) {
-            (0, false) => {
-                // FIXME: Emit unused attribute lint here.
-            },
-            (1, _) => {},
-            (_, true) => {
-                emit_feature_err(
-                    self.sess,
-                    "cfg_attr_multi",
-                    cfg_attr_span,
-                    GateIssue::Language,
-                    "cfg_attr with zero or more than one attributes is experimental",
-                );
-            },
-            (_, false) => {}
+        if expanded_attrs.len() == 0 {
+            // FIXME: Emit unused attribute lint here.
         }
 
         if attr::cfg_matches(&cfg_predicate, self.sess, self.features) {
diff --git a/src/libsyntax/ext/tt/macro_parser.rs b/src/libsyntax/ext/tt/macro_parser.rs
index 970796a..d55f785 100644
--- a/src/libsyntax/ext/tt/macro_parser.rs
+++ b/src/libsyntax/ext/tt/macro_parser.rs
@@ -161,7 +161,7 @@
     /// The position of the "dot" in this matcher
     idx: usize,
 
-    /// The first span of source source that the beginning of this matcher corresponds to. In other
+    /// The first span of source that the beginning of this matcher corresponds to. In other
     /// words, the token in the source whose span is `sp_open` is matched against the first token of
     /// the matcher.
     sp_open: Span,
diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs
index 8362c86..cddec3e 100644
--- a/src/libsyntax/feature_gate.rs
+++ b/src/libsyntax/feature_gate.rs
@@ -465,9 +465,6 @@
     // Allows `impl Trait` in bindings (`let`, `const`, `static`).
     (active, impl_trait_in_bindings, "1.30.0", Some(34511), None),
 
-    // `#[cfg_attr(predicate, multiple, attributes, here)]`
-    (active, cfg_attr_multi, "1.31.0", Some(54881), None),
-
     // Allows `const _: TYPE = VALUE`.
     (active, underscore_const_names, "1.31.0", Some(54912), None),
 
@@ -689,6 +686,8 @@
     (accepted, repr_packed, "1.33.0", Some(33158), None),
     // Allows calling `const unsafe fn` inside `unsafe` blocks in `const fn` functions.
     (accepted, min_const_unsafe_fn, "1.33.0", Some(55607), None),
+    // `#[cfg_attr(predicate, multiple, attributes, here)]`
+    (accepted, cfg_attr_multi, "1.33.0", Some(54881), None),
 );
 
 // If you change this, please modify `src/doc/unstable-book` as well. You must
@@ -1543,7 +1542,6 @@
 
     fn visit_item(&mut self, i: &'a ast::Item) {
         match i.node {
-            ast::ItemKind::Static(..) |
             ast::ItemKind::Const(_,_) => {
                 if i.ident.name == "_" {
                     gate_feature_post!(&self, underscore_const_names, i.span,
diff --git a/src/rustc/Cargo.toml b/src/rustc/Cargo.toml
index 164a3c6..e601a1f 100644
--- a/src/rustc/Cargo.toml
+++ b/src/rustc/Cargo.toml
@@ -2,6 +2,7 @@
 authors = ["The Rust Project Developers"]
 name = "rustc-main"
 version = "0.0.0"
+edition = '2018'
 
 [[bin]]
 name = "rustc_binary"
diff --git a/src/rustc/rustc.rs b/src/rustc/rustc.rs
index a0ef572..fef6b83 100644
--- a/src/rustc/rustc.rs
+++ b/src/rustc/rustc.rs
@@ -1,4 +1,3 @@
-#![feature(rustc_private)]
 #![feature(link_args)]
 
 // Set the stack size at link time on Windows. See rustc_driver::in_rustc_thread
@@ -11,17 +10,39 @@
 // Also, don't forget to set this for rustdoc.
 extern {}
 
-extern crate rustc_driver;
-
-// Note that the linkage here should be all that we need, on Linux we're not
-// prefixing the symbols here so this should naturally override our default
-// allocator. On OSX it should override via the zone allocator. We shouldn't
-// enable this by default on other platforms, so other platforms aren't handled
-// here yet.
-#[cfg(feature = "jemalloc-sys")]
-extern crate jemalloc_sys;
-
 fn main() {
+    // Pull in jemalloc when enabled.
+    //
+    // Note that we're pulling in a static copy of jemalloc which means that to
+    // pull it in we need to actually reference its symbols for it to get
+    // linked. The two crates we link to here, std and rustc_driver, are both
+    // dynamic libraries. That means to pull in jemalloc we need to actually
+    // reference allocation symbols one way or another (as this file is the only
+    // object code in the rustc executable).
+    #[cfg(feature = "jemalloc-sys")]
+    {
+        use std::os::raw::{c_void, c_int};
+
+        #[used]
+        static _F1: unsafe extern fn(usize, usize) -> *mut c_void =
+            jemalloc_sys::calloc;
+        #[used]
+        static _F2: unsafe extern fn(*mut *mut c_void, usize, usize) -> c_int =
+            jemalloc_sys::posix_memalign;
+        #[used]
+        static _F3: unsafe extern fn(usize, usize) -> *mut c_void =
+            jemalloc_sys::aligned_alloc;
+        #[used]
+        static _F4: unsafe extern fn(usize) -> *mut c_void =
+            jemalloc_sys::malloc;
+        #[used]
+        static _F5: unsafe extern fn(*mut c_void, usize) -> *mut c_void =
+            jemalloc_sys::realloc;
+        #[used]
+        static _F6: unsafe extern fn(*mut c_void) =
+            jemalloc_sys::free;
+    }
+
     rustc_driver::set_sigpipe_handler();
     rustc_driver::main()
 }
diff --git a/src/stage0.txt b/src/stage0.txt
index 843ecae..2e376ed 100644
--- a/src/stage0.txt
+++ b/src/stage0.txt
@@ -12,7 +12,7 @@
 # source tarball for a stable release you'll likely see `1.x.0` for rustc and
 # `0.x.0` for Cargo where they were released on `date`.
 
-date: 2018-12-09
+date: 2019-01-04
 rustc: beta
 cargo: beta
 
diff --git a/src/stdsimd b/src/stdsimd
index 513e067..269d0ba 160000
--- a/src/stdsimd
+++ b/src/stdsimd
@@ -1 +1 @@
-Subproject commit 513e067908f3e2eb8b31ad1c12b2e0a62817e557
+Subproject commit 269d0ba959f70e9b692e528311c78b8f9601d4af
diff --git a/src/test/compile-fail/invalid-link-args.rs b/src/test/compile-fail/invalid-link-args.rs
new file mode 100644
index 0000000..1e68b4f
--- /dev/null
+++ b/src/test/compile-fail/invalid-link-args.rs
@@ -0,0 +1,12 @@
+// ignore-msvc due to linker-flavor=ld
+// error-pattern:aFdEfSeVEEE
+// compile-flags: -C linker-flavor=ld
+
+/* Make sure invalid link_args are printed to stderr. */
+
+#![feature(link_args)]
+
+#[link_args = "aFdEfSeVEEE"]
+extern {}
+
+fn main() { }
diff --git a/src/test/compile-fail/nolink-with-link-args.rs b/src/test/compile-fail/nolink-with-link-args.rs
deleted file mode 100644
index c2ca2f8..0000000
--- a/src/test/compile-fail/nolink-with-link-args.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-// error-pattern:aFdEfSeVEE
-// compile-flags: -C linker-flavor=ld
-
-/* We're testing that link_args are indeed passed when nolink is specified.
-So we try to compile with junk link_args and make sure they are visible in
-the compiler output. */
-
-#![feature(link_args)]
-
-#[link_args = "aFdEfSeVEEE"]
-extern {}
-
-fn main() { }
diff --git a/src/test/debuginfo/simd.rs b/src/test/debuginfo/simd.rs
index 4748916..e41acc2 100644
--- a/src/test/debuginfo/simd.rs
+++ b/src/test/debuginfo/simd.rs
@@ -4,7 +4,7 @@
 
 // FIXME: LLVM generates invalid debug info for variables requiring
 // dynamic stack realignment, which is the case on s390x for vector
-// types with with non-vector ABI.
+// types with non-vector ABI.
 // ignore-s390x
 
 // compile-flags:-g
diff --git a/src/test/run-make-fulldeps/llvm-pass/Makefile b/src/test/run-make-fulldeps/llvm-pass/Makefile
deleted file mode 100644
index 8a18aad..0000000
--- a/src/test/run-make-fulldeps/llvm-pass/Makefile
+++ /dev/null
@@ -1,28 +0,0 @@
--include ../tools.mk
-
-ifeq ($(UNAME),Darwin)
-PLUGIN_FLAGS := -C link-args=-Wl,-undefined,dynamic_lookup
-endif
-
-ifeq ($(findstring stage1,$(RUST_BUILD_STAGE)),stage1)
-# ignore stage1
-all:
-
-else
-# Windows doesn't correctly handle include statements with escaping paths,
-# so this test will not get run on Windows.
-ifdef IS_WINDOWS
-all:
-else
-all: $(call NATIVE_STATICLIB,llvm-function-pass) $(call NATIVE_STATICLIB,llvm-module-pass)
-	$(RUSTC) plugin.rs -C prefer-dynamic $(PLUGIN_FLAGS)
-	$(RUSTC) main.rs
-
-$(TMPDIR)/libllvm-function-pass.o:
-	$(CXX) $(CFLAGS) $(LLVM_CXXFLAGS) -c llvm-function-pass.so.cc -o $(TMPDIR)/libllvm-function-pass.o
-
-$(TMPDIR)/libllvm-module-pass.o:
-	$(CXX) $(CFLAGS) $(LLVM_CXXFLAGS) -c llvm-module-pass.so.cc -o $(TMPDIR)/libllvm-module-pass.o
-endif
-
-endif
diff --git a/src/test/run-make-fulldeps/llvm-pass/llvm-function-pass.so.cc b/src/test/run-make-fulldeps/llvm-pass/llvm-function-pass.so.cc
deleted file mode 100644
index 267c688..0000000
--- a/src/test/run-make-fulldeps/llvm-pass/llvm-function-pass.so.cc
+++ /dev/null
@@ -1,46 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#include "llvm/Pass.h"
-#include "llvm/IR/Function.h"
-
-using namespace llvm;
-
-namespace {
-
-  class TestLLVMPass : public FunctionPass {
-
-  public:
-
-    static char ID;
-    TestLLVMPass() : FunctionPass(ID) { }
-
-    bool runOnFunction(Function &F) override;
-
-    StringRef getPassName() const override {
-      return "Some LLVM pass";
-    }
-
-  };
-
-}
-
-bool TestLLVMPass::runOnFunction(Function &F) {
-  // A couple examples of operations that previously caused segmentation faults
-  // https://github.com/rust-lang/rust/issues/31067
-
-  for (auto N = F.begin(); N != F.end(); ++N) {
-    /* code */
-  }
-
-  LLVMContext &C = F.getContext();
-  IntegerType *Int8Ty  = IntegerType::getInt8Ty(C);
-  PointerType::get(Int8Ty, 0);
-  return true;
-}
-
-char TestLLVMPass::ID = 0;
-
-static RegisterPass<TestLLVMPass> RegisterAFLPass(
-  "some-llvm-function-pass", "Some LLVM pass");
diff --git a/src/test/run-make-fulldeps/llvm-pass/llvm-module-pass.so.cc b/src/test/run-make-fulldeps/llvm-pass/llvm-module-pass.so.cc
deleted file mode 100644
index b3ee0c1..0000000
--- a/src/test/run-make-fulldeps/llvm-pass/llvm-module-pass.so.cc
+++ /dev/null
@@ -1,45 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#include "llvm/IR/Module.h"
-
-using namespace llvm;
-
-namespace {
-
-  class TestLLVMPass : public ModulePass {
-
-  public:
-
-    static char ID;
-    TestLLVMPass() : ModulePass(ID) { }
-
-    bool runOnModule(Module &M) override;
-
-    StringRef getPassName() const override {
-      return "Some LLVM pass";
-    }
-
-  };
-
-}
-
-bool TestLLVMPass::runOnModule(Module &M) {
-  // A couple examples of operations that previously caused segmentation faults
-  // https://github.com/rust-lang/rust/issues/31067
-
-  for (auto F = M.begin(); F != M.end(); ++F) {
-    /* code */
-  }
-
-  LLVMContext &C = M.getContext();
-  IntegerType *Int8Ty  = IntegerType::getInt8Ty(C);
-  PointerType::get(Int8Ty, 0);
-  return true;
-}
-
-char TestLLVMPass::ID = 0;
-
-static RegisterPass<TestLLVMPass> RegisterAFLPass(
-  "some-llvm-module-pass", "Some LLVM pass");
diff --git a/src/test/run-make-fulldeps/llvm-pass/main.rs b/src/test/run-make-fulldeps/llvm-pass/main.rs
deleted file mode 100644
index 0c13b89..0000000
--- a/src/test/run-make-fulldeps/llvm-pass/main.rs
+++ /dev/null
@@ -1,4 +0,0 @@
-#![feature(plugin)]
-#![plugin(some_plugin)]
-
-fn main() {}
diff --git a/src/test/run-make-fulldeps/llvm-pass/plugin.rs b/src/test/run-make-fulldeps/llvm-pass/plugin.rs
deleted file mode 100644
index f0e4800..0000000
--- a/src/test/run-make-fulldeps/llvm-pass/plugin.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-#![feature(plugin_registrar, rustc_private)]
-#![crate_type = "dylib"]
-#![crate_name = "some_plugin"]
-
-extern crate rustc;
-extern crate rustc_plugin;
-
-#[link(name = "llvm-function-pass", kind = "static")]
-#[link(name = "llvm-module-pass", kind = "static")]
-extern {}
-
-use rustc_plugin::registry::Registry;
-
-#[plugin_registrar]
-pub fn plugin_registrar(reg: &mut Registry) {
-    reg.register_llvm_pass("some-llvm-function-pass");
-    reg.register_llvm_pass("some-llvm-module-pass");
-}
diff --git a/src/test/run-make-fulldeps/relro-levels/Makefile b/src/test/run-make-fulldeps/relro-levels/Makefile
index 673ba9a..78ac2f6 100644
--- a/src/test/run-make-fulldeps/relro-levels/Makefile
+++ b/src/test/run-make-fulldeps/relro-levels/Makefile
@@ -1,6 +1,6 @@
 -include ../tools.mk
 
-# This tests the different -Zrelro-level values, and makes sure that they they work properly.
+# This tests the different -Zrelro-level values, and makes sure that they work properly.
 
 all:
 ifeq ($(UNAME),Linux)
diff --git a/src/test/run-pass/generator/yield-subtype.rs b/src/test/run-pass/generator/yield-subtype.rs
index c00662e..c3852485 100644
--- a/src/test/run-pass/generator/yield-subtype.rs
+++ b/src/test/run-pass/generator/yield-subtype.rs
@@ -3,7 +3,6 @@
 #![allow(dead_code)]
 
 // revisions:lexical nll
-//[nll]compile-flags: -Z disable-nll-user-type-assert
 #![cfg_attr(nll, feature(nll))]
 
 #![feature(generators)]
diff --git a/src/test/run-pass/panic-uninitialized-zeroed.rs b/src/test/run-pass/panic-uninitialized-zeroed.rs
index c806bb9..d47ff6c 100644
--- a/src/test/run-pass/panic-uninitialized-zeroed.rs
+++ b/src/test/run-pass/panic-uninitialized-zeroed.rs
@@ -2,7 +2,7 @@
 // This test checks that instantiating an uninhabited type via `mem::{uninitialized,zeroed}` results
 // in a runtime panic.
 
-#![feature(never_type)]
+#![feature(never_type, maybe_uninit)]
 
 use std::{mem, panic};
 
@@ -20,7 +20,7 @@
             panic::catch_unwind(|| {
                 mem::uninitialized::<!>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type ! using mem::uninitialized"
+                s == "Attempted to instantiate uninhabited type !"
             })),
             Some(true)
         );
@@ -29,7 +29,16 @@
             panic::catch_unwind(|| {
                 mem::zeroed::<!>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type ! using mem::zeroed"
+                s == "Attempted to instantiate uninhabited type !"
+            })),
+            Some(true)
+        );
+
+        assert_eq!(
+            panic::catch_unwind(|| {
+                mem::MaybeUninit::<!>::uninitialized().into_inner()
+            }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
+                s == "Attempted to instantiate uninhabited type !"
             })),
             Some(true)
         );
@@ -38,7 +47,7 @@
             panic::catch_unwind(|| {
                 mem::uninitialized::<Foo>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type Foo using mem::uninitialized"
+                s == "Attempted to instantiate uninhabited type Foo"
             })),
             Some(true)
         );
@@ -47,7 +56,16 @@
             panic::catch_unwind(|| {
                 mem::zeroed::<Foo>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type Foo using mem::zeroed"
+                s == "Attempted to instantiate uninhabited type Foo"
+            })),
+            Some(true)
+        );
+
+        assert_eq!(
+            panic::catch_unwind(|| {
+                mem::MaybeUninit::<Foo>::uninitialized().into_inner()
+            }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
+                s == "Attempted to instantiate uninhabited type Foo"
             })),
             Some(true)
         );
@@ -56,7 +74,7 @@
             panic::catch_unwind(|| {
                 mem::uninitialized::<Bar>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type Bar using mem::uninitialized"
+                s == "Attempted to instantiate uninhabited type Bar"
             })),
             Some(true)
         );
@@ -65,7 +83,16 @@
             panic::catch_unwind(|| {
                 mem::zeroed::<Bar>()
             }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
-                s == "Attempted to instantiate uninhabited type Bar using mem::zeroed"
+                s == "Attempted to instantiate uninhabited type Bar"
+            })),
+            Some(true)
+        );
+
+        assert_eq!(
+            panic::catch_unwind(|| {
+                mem::MaybeUninit::<Bar>::uninitialized().into_inner()
+            }).err().and_then(|a| a.downcast_ref::<String>().map(|s| {
+                s == "Attempted to instantiate uninhabited type Bar"
             })),
             Some(true)
         );
diff --git a/src/test/rustdoc-ui/deny-missing-docs-crate.rs b/src/test/rustdoc-ui/deny-missing-docs-crate.rs
new file mode 100644
index 0000000..910c993
--- /dev/null
+++ b/src/test/rustdoc-ui/deny-missing-docs-crate.rs
@@ -0,0 +1,13 @@
+// Copyright 2018 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+#![deny(missing_docs)] //~ ERROR
+
+pub struct Foo; //~ ERROR
diff --git a/src/test/rustdoc-ui/deny-missing-docs-crate.stderr b/src/test/rustdoc-ui/deny-missing-docs-crate.stderr
new file mode 100644
index 0000000..7f0590e
--- /dev/null
+++ b/src/test/rustdoc-ui/deny-missing-docs-crate.stderr
@@ -0,0 +1,22 @@
+error: missing documentation for crate
+  --> $DIR/deny-missing-docs-crate.rs:11:1
+   |
+LL | / #![deny(missing_docs)] //~ ERROR
+LL | |
+LL | | pub struct Foo; //~ ERROR
+   | |_______________^
+   |
+note: lint level defined here
+  --> $DIR/deny-missing-docs-crate.rs:11:9
+   |
+LL | #![deny(missing_docs)] //~ ERROR
+   |         ^^^^^^^^^^^^
+
+error: missing documentation for a struct
+  --> $DIR/deny-missing-docs-crate.rs:13:1
+   |
+LL | pub struct Foo; //~ ERROR
+   | ^^^^^^^^^^^^^^^
+
+error: Compilation failed, aborting rustdoc
+
diff --git a/src/test/rustdoc-ui/deny-missing-docs-macro.rs b/src/test/rustdoc-ui/deny-missing-docs-macro.rs
new file mode 100644
index 0000000..a12fe17
--- /dev/null
+++ b/src/test/rustdoc-ui/deny-missing-docs-macro.rs
@@ -0,0 +1,18 @@
+// Copyright 2018 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+//! foo
+
+#![deny(missing_docs)]
+
+#[macro_export]
+macro_rules! foo { //~ ERROR
+    () => {}
+}
diff --git a/src/test/rustdoc-ui/deny-missing-docs-macro.stderr b/src/test/rustdoc-ui/deny-missing-docs-macro.stderr
new file mode 100644
index 0000000..686a450
--- /dev/null
+++ b/src/test/rustdoc-ui/deny-missing-docs-macro.stderr
@@ -0,0 +1,14 @@
+error: missing documentation for macro
+  --> $DIR/deny-missing-docs-macro.rs:16:1
+   |
+LL | macro_rules! foo { //~ ERROR
+   | ^^^^^^^^^^^^^^^^
+   |
+note: lint level defined here
+  --> $DIR/deny-missing-docs-macro.rs:13:9
+   |
+LL | #![deny(missing_docs)]
+   |         ^^^^^^^^^^^^
+
+error: Compilation failed, aborting rustdoc
+
diff --git a/src/test/rustdoc/doctest-manual-crate-name.rs b/src/test/rustdoc/doctest-manual-crate-name.rs
new file mode 100644
index 0000000..3a5e373
--- /dev/null
+++ b/src/test/rustdoc/doctest-manual-crate-name.rs
@@ -0,0 +1,7 @@
+// compile-flags:--test
+
+//! ```
+//! #![crate_name="asdf"]
+//!
+//! println!("yo");
+//! ```
diff --git a/src/test/rustdoc/issue-32374.rs b/src/test/rustdoc/issue-32374.rs
index 709cf5b..58876a1 100644
--- a/src/test/rustdoc/issue-32374.rs
+++ b/src/test/rustdoc/issue-32374.rs
@@ -10,7 +10,7 @@
 //      'Deprecated since 1.0.0: text'
 // @has - '<code>test</code>&nbsp;<a href="http://issue_url/32374">#32374</a>'
 // @matches issue_32374/struct.T.html '//*[@class="stab unstable"]' \
-//      '🔬 This is a nightly-only experimental API. \(test #32374\)$'
+//      '🔬 This is a nightly-only experimental API. \(test\s#32374\)$'
 /// Docs
 #[rustc_deprecated(since = "1.0.0", reason = "text")]
 #[unstable(feature = "test", issue = "32374")]
diff --git a/src/test/rustfix/tuple-float-index.fixed b/src/test/rustfix/tuple-float-index.fixed
index abb0796..358a27d 100644
--- a/src/test/rustfix/tuple-float-index.fixed
+++ b/src/test/rustfix/tuple-float-index.fixed
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main () {
     ((1, (2, 3)).1).1;
 }
diff --git a/src/test/rustfix/tuple-float-index.rs b/src/test/rustfix/tuple-float-index.rs
index f3280e8..7261225 100644
--- a/src/test/rustfix/tuple-float-index.rs
+++ b/src/test/rustfix/tuple-float-index.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main () {
     (1, (2, 3)).1.1;
 }
diff --git a/src/test/ui/assign-to-method.rs b/src/test/ui/assign-to-method.rs
index a7f3ab6..95f066c 100644
--- a/src/test/ui/assign-to-method.rs
+++ b/src/test/ui/assign-to-method.rs
@@ -18,4 +18,5 @@
 fn main() {
   let nyan : Cat = cat(52, 99);
   nyan.speak = || println!("meow"); //~ ERROR attempted to take value of method
+  nyan.speak += || println!("meow"); //~ ERROR attempted to take value of method
 }
diff --git a/src/test/ui/assign-to-method.stderr b/src/test/ui/assign-to-method.stderr
index a08ac19..f79f075 100644
--- a/src/test/ui/assign-to-method.stderr
+++ b/src/test/ui/assign-to-method.stderr
@@ -4,8 +4,16 @@
 LL |   nyan.speak = || println!("meow"); //~ ERROR attempted to take value of method
    |        ^^^^^
    |
-   = help: maybe a `()` to call it is missing?
+   = help: methods are immutable and cannot be assigned to
 
-error: aborting due to previous error
+error[E0615]: attempted to take value of method `speak` on type `Cat`
+  --> $DIR/assign-to-method.rs:21:8
+   |
+LL |   nyan.speak += || println!("meow"); //~ ERROR attempted to take value of method
+   |        ^^^^^
+   |
+   = help: methods are immutable and cannot be assigned to
+
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0615`.
diff --git a/src/test/ui/associated-types/associated-types-unsized.stderr b/src/test/ui/associated-types/associated-types-unsized.stderr
index bc85620..c83b143 100644
--- a/src/test/ui/associated-types/associated-types-unsized.stderr
+++ b/src/test/ui/associated-types/associated-types-unsized.stderr
@@ -5,7 +5,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `<T as Get>::Value`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where <T as Get>::Value: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
diff --git a/src/test/ui/bad/bad-sized.stderr b/src/test/ui/bad/bad-sized.stderr
index 57a2046..9565888 100644
--- a/src/test/ui/bad/bad-sized.stderr
+++ b/src/test/ui/bad/bad-sized.stderr
@@ -11,7 +11,7 @@
    |            ^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn Trait`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::vec::Vec`
 
 error[E0277]: the size for values of type `dyn Trait` cannot be known at compilation time
@@ -21,7 +21,7 @@
    |                                 ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn Trait`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `<std::vec::Vec<T>>::new`
 
 error: aborting due to 3 previous errors
diff --git a/src/test/ui/block-result/consider-removing-last-semi.stderr b/src/test/ui/block-result/consider-removing-last-semi.stderr
index 870da00..1bf17db 100644
--- a/src/test/ui/block-result/consider-removing-last-semi.stderr
+++ b/src/test/ui/block-result/consider-removing-last-semi.stderr
@@ -1,27 +1,27 @@
 error[E0308]: mismatched types
-  --> $DIR/consider-removing-last-semi.rs:1:18
+  --> $DIR/consider-removing-last-semi.rs:1:11
    |
-LL |   fn f() -> String {  //~ ERROR mismatched types
-   |  __________________^
-LL | |     0u8;
-LL | |     "bla".to_string();
-   | |                      - help: consider removing this semicolon
-LL | | }
-   | |_^ expected struct `std::string::String`, found ()
+LL | fn f() -> String {  //~ ERROR mismatched types
+   |    -      ^^^^^^ expected struct `std::string::String`, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     0u8;
+LL |     "bla".to_string();
+   |                      - help: consider removing this semicolon
    |
    = note: expected type `std::string::String`
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/consider-removing-last-semi.rs:6:18
+  --> $DIR/consider-removing-last-semi.rs:6:11
    |
-LL |   fn g() -> String {  //~ ERROR mismatched types
-   |  __________________^
-LL | |     "this won't work".to_string();
-LL | |     "removeme".to_string();
-   | |                           - help: consider removing this semicolon
-LL | | }
-   | |_^ expected struct `std::string::String`, found ()
+LL | fn g() -> String {  //~ ERROR mismatched types
+   |    -      ^^^^^^ expected struct `std::string::String`, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     "this won't work".to_string();
+LL |     "removeme".to_string();
+   |                           - help: consider removing this semicolon
    |
    = note: expected type `std::string::String`
               found type `()`
diff --git a/src/test/ui/block-result/issue-11714.stderr b/src/test/ui/block-result/issue-11714.stderr
index 8bb3739..2c13b28 100644
--- a/src/test/ui/block-result/issue-11714.stderr
+++ b/src/test/ui/block-result/issue-11714.stderr
@@ -1,14 +1,13 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-11714.rs:1:18
+  --> $DIR/issue-11714.rs:1:14
    |
-LL |   fn blah() -> i32 { //~ ERROR mismatched types
-   |  __________________^
-LL | |     1
-LL | |
-LL | |     ;
-   | |     - help: consider removing this semicolon
-LL | | }
-   | |_^ expected i32, found ()
+LL | fn blah() -> i32 { //~ ERROR mismatched types
+   |    ----      ^^^ expected i32, found ()
+   |    |
+   |    this function's body doesn't return
+...
+LL |     ;
+   |     - help: consider removing this semicolon
    |
    = note: expected type `i32`
               found type `()`
diff --git a/src/test/ui/block-result/issue-13428.stderr b/src/test/ui/block-result/issue-13428.stderr
index 516baa8..91e926e 100644
--- a/src/test/ui/block-result/issue-13428.stderr
+++ b/src/test/ui/block-result/issue-13428.stderr
@@ -1,30 +1,27 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-13428.rs:3:20
+  --> $DIR/issue-13428.rs:3:13
    |
-LL |   fn foo() -> String {  //~ ERROR mismatched types
-   |  ____________________^
-LL | |     format!("Hello {}",
-LL | |             "world")
-LL | |     // Put the trailing semicolon on its own line to test that the
-LL | |     // note message gets the offending semicolon exactly
-LL | |     ;
-   | |     - help: consider removing this semicolon
-LL | | }
-   | |_^ expected struct `std::string::String`, found ()
+LL | fn foo() -> String {  //~ ERROR mismatched types
+   |    ---      ^^^^^^ expected struct `std::string::String`, found ()
+   |    |
+   |    this function's body doesn't return
+...
+LL |     ;
+   |     - help: consider removing this semicolon
    |
    = note: expected type `std::string::String`
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/issue-13428.rs:11:20
+  --> $DIR/issue-13428.rs:11:13
    |
-LL |   fn bar() -> String {  //~ ERROR mismatched types
-   |  ____________________^
-LL | |     "foobar".to_string()
-LL | |     ;
-   | |     - help: consider removing this semicolon
-LL | | }
-   | |_^ expected struct `std::string::String`, found ()
+LL | fn bar() -> String {  //~ ERROR mismatched types
+   |    ---      ^^^^^^ expected struct `std::string::String`, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     "foobar".to_string()
+LL |     ;
+   |     - help: consider removing this semicolon
    |
    = note: expected type `std::string::String`
               found type `()`
diff --git a/src/test/ui/coercion/coercion-missing-tail-expected-type.stderr b/src/test/ui/coercion/coercion-missing-tail-expected-type.stderr
index 18adf9a..c8ec2f0 100644
--- a/src/test/ui/coercion/coercion-missing-tail-expected-type.stderr
+++ b/src/test/ui/coercion/coercion-missing-tail-expected-type.stderr
@@ -1,25 +1,25 @@
 error[E0308]: mismatched types
-  --> $DIR/coercion-missing-tail-expected-type.rs:3:28
+  --> $DIR/coercion-missing-tail-expected-type.rs:3:24
    |
-LL |   fn plus_one(x: i32) -> i32 { //~ ERROR mismatched types
-   |  ____________________________^
-LL | |     x + 1;
-   | |          - help: consider removing this semicolon
-LL | | }
-   | |_^ expected i32, found ()
+LL | fn plus_one(x: i32) -> i32 { //~ ERROR mismatched types
+   |    --------            ^^^ expected i32, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     x + 1;
+   |          - help: consider removing this semicolon
    |
    = note: expected type `i32`
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/coercion-missing-tail-expected-type.rs:7:29
+  --> $DIR/coercion-missing-tail-expected-type.rs:7:13
    |
-LL |   fn foo() -> Result<u8, u64> { //~ ERROR mismatched types
-   |  _____________________________^
-LL | |     Ok(1);
-   | |          - help: consider removing this semicolon
-LL | | }
-   | |_^ expected enum `std::result::Result`, found ()
+LL | fn foo() -> Result<u8, u64> { //~ ERROR mismatched types
+   |    ---      ^^^^^^^^^^^^^^^ expected enum `std::result::Result`, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     Ok(1);
+   |          - help: consider removing this semicolon
    |
    = note: expected type `std::result::Result<u8, u64>`
               found type `()`
diff --git a/src/test/ui/conditional-compilation/cfg-attr-crate-2.rs b/src/test/ui/conditional-compilation/cfg-attr-crate-2.rs
index 9345229..0dceba2 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-crate-2.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-crate-2.rs
@@ -1,8 +1,8 @@
-//
-// compile-flags: --cfg broken
-
 // https://github.com/rust-lang/rust/issues/21833#issuecomment-72353044
 
+// compile-flags: --cfg broken
+
+#![crate_type = "lib"]
 #![cfg_attr(broken, no_core)] //~ ERROR no_core is experimental
 
-fn main() { }
+pub struct S {}
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-false.rs b/src/test/ui/conditional-compilation/cfg-attr-multi-false.rs
index ec4ee80..f1ab2f0 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-false.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-false.rs
@@ -4,7 +4,6 @@
 // compile-pass
 
 #![warn(unused_must_use)]
-#![feature(cfg_attr_multi)]
 
 #[cfg_attr(any(), deprecated, must_use)]
 struct Struct {}
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.rs b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.rs
index 0638f48..be762c5 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.rs
@@ -1,7 +1,6 @@
-//
 // compile-flags: --cfg broken
 
-#![feature(cfg_attr_multi)]
+#![crate_type = "lib"]
 #![cfg_attr(broken, no_core, no_std)] //~ ERROR no_core is experimental
 
-fn main() { }
+pub struct S {}
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
index f63e4f9..8cdf4ec 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-1.stderr
@@ -1,5 +1,5 @@
 error[E0658]: no_core is experimental (see issue #29639)
-  --> $DIR/cfg-attr-multi-invalid-1.rs:5:21
+  --> $DIR/cfg-attr-multi-invalid-1.rs:4:21
    |
 LL | #![cfg_attr(broken, no_core, no_std)] //~ ERROR no_core is experimental
    |                     ^^^^^^^
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.rs b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.rs
index 26b4936..8a9e99d 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.rs
@@ -1,7 +1,6 @@
-//
 // compile-flags: --cfg broken
 
-#![feature(cfg_attr_multi)]
+#![crate_type = "lib"]
 #![cfg_attr(broken, no_std, no_core)] //~ ERROR no_core is experimental
 
-fn main() { }
+pub struct S {}
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
index 5907200..b3a3b0c 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-invalid-2.stderr
@@ -1,5 +1,5 @@
 error[E0658]: no_core is experimental (see issue #29639)
-  --> $DIR/cfg-attr-multi-invalid-2.rs:5:29
+  --> $DIR/cfg-attr-multi-invalid-2.rs:4:29
    |
 LL | #![cfg_attr(broken, no_std, no_core)] //~ ERROR no_core is experimental
    |                             ^^^^^^^
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-true.rs b/src/test/ui/conditional-compilation/cfg-attr-multi-true.rs
index 68307a9..86524e8 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-true.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-true.rs
@@ -5,7 +5,6 @@
 // compile-pass
 
 #![warn(unused_must_use)]
-#![feature(cfg_attr_multi)]
 
 #[cfg_attr(all(), deprecated, must_use)]
 struct MustUseDeprecated {}
diff --git a/src/test/ui/conditional-compilation/cfg-attr-multi-true.stderr b/src/test/ui/conditional-compilation/cfg-attr-multi-true.stderr
index 8b62587..3d14c19 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-multi-true.stderr
+++ b/src/test/ui/conditional-compilation/cfg-attr-multi-true.stderr
@@ -1,5 +1,5 @@
 warning: use of deprecated item 'MustUseDeprecated'
-  --> $DIR/cfg-attr-multi-true.rs:13:6
+  --> $DIR/cfg-attr-multi-true.rs:12:6
    |
 LL | impl MustUseDeprecated { //~ warning: use of deprecated item
    |      ^^^^^^^^^^^^^^^^^
@@ -7,25 +7,25 @@
    = note: #[warn(deprecated)] on by default
 
 warning: use of deprecated item 'MustUseDeprecated'
-  --> $DIR/cfg-attr-multi-true.rs:20:5
+  --> $DIR/cfg-attr-multi-true.rs:19:5
    |
 LL |     MustUseDeprecated::new(); //~ warning: use of deprecated item
    |     ^^^^^^^^^^^^^^^^^^^^^^
 
 warning: use of deprecated item 'MustUseDeprecated'
-  --> $DIR/cfg-attr-multi-true.rs:14:17
+  --> $DIR/cfg-attr-multi-true.rs:13:17
    |
 LL |     fn new() -> MustUseDeprecated { //~ warning: use of deprecated item
    |                 ^^^^^^^^^^^^^^^^^
 
 warning: use of deprecated item 'MustUseDeprecated'
-  --> $DIR/cfg-attr-multi-true.rs:15:9
+  --> $DIR/cfg-attr-multi-true.rs:14:9
    |
 LL |         MustUseDeprecated {} //~ warning: use of deprecated item
    |         ^^^^^^^^^^^^^^^^^
 
 warning: unused `MustUseDeprecated` that must be used
-  --> $DIR/cfg-attr-multi-true.rs:20:5
+  --> $DIR/cfg-attr-multi-true.rs:19:5
    |
 LL |     MustUseDeprecated::new(); //~ warning: use of deprecated item
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/conditional-compilation/cfg-attr-parse.rs b/src/test/ui/conditional-compilation/cfg-attr-parse.rs
index eec0e8f..93aef72 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-parse.rs
+++ b/src/test/ui/conditional-compilation/cfg-attr-parse.rs
@@ -1,7 +1,5 @@
 // Parse `cfg_attr` with varying numbers of attributes and trailing commas
 
-#![feature(cfg_attr_multi)]
-
 // Completely empty `cfg_attr` input
 #[cfg_attr()] //~ error: expected identifier, found `)`
 struct NoConfigurationPredicate;
diff --git a/src/test/ui/conditional-compilation/cfg-attr-parse.stderr b/src/test/ui/conditional-compilation/cfg-attr-parse.stderr
index 553406b..36c7c81 100644
--- a/src/test/ui/conditional-compilation/cfg-attr-parse.stderr
+++ b/src/test/ui/conditional-compilation/cfg-attr-parse.stderr
@@ -1,29 +1,29 @@
 error: expected identifier, found `)`
-  --> $DIR/cfg-attr-parse.rs:6:12
+  --> $DIR/cfg-attr-parse.rs:4:12
    |
 LL | #[cfg_attr()] //~ error: expected identifier, found `)`
    |            ^ expected identifier
 
 error: expected `,`, found `)`
-  --> $DIR/cfg-attr-parse.rs:10:17
+  --> $DIR/cfg-attr-parse.rs:8:17
    |
 LL | #[cfg_attr(all())] //~ error: expected `,`, found `)`
    |                 ^ expected `,`
 
 error: expected identifier, found `,`
-  --> $DIR/cfg-attr-parse.rs:18:18
+  --> $DIR/cfg-attr-parse.rs:16:18
    |
 LL | #[cfg_attr(all(),,)] //~ ERROR expected identifier
    |                  ^ expected identifier
 
 error: expected identifier, found `,`
-  --> $DIR/cfg-attr-parse.rs:30:28
+  --> $DIR/cfg-attr-parse.rs:28:28
    |
 LL | #[cfg_attr(all(), must_use,,)] //~ ERROR expected identifier
    |                            ^ expected identifier
 
 error: expected identifier, found `,`
-  --> $DIR/cfg-attr-parse.rs:42:40
+  --> $DIR/cfg-attr-parse.rs:40:40
    |
 LL | #[cfg_attr(all(), must_use, deprecated,,)] //~ ERROR expected identifier
    |                                        ^ expected identifier
diff --git a/src/test/ui/consts/const-unsized.stderr b/src/test/ui/consts/const-unsized.stderr
index cc00b77..0f996fc 100644
--- a/src/test/ui/consts/const-unsized.stderr
+++ b/src/test/ui/consts/const-unsized.stderr
@@ -5,7 +5,7 @@
    |                ^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::fmt::Debug + std::marker::Sync + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
   --> $DIR/const-unsized.rs:6:18
@@ -14,7 +14,7 @@
    |                  ^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error[E0277]: the size for values of type `(dyn std::fmt::Debug + std::marker::Sync + 'static)` cannot be known at compilation time
   --> $DIR/const-unsized.rs:9:18
@@ -23,7 +23,7 @@
    |                  ^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::fmt::Debug + std::marker::Sync + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
   --> $DIR/const-unsized.rs:12:20
@@ -32,7 +32,7 @@
    |                    ^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error: aborting due to 4 previous errors
 
diff --git a/src/test/ui/did_you_mean/issue-40396.stderr b/src/test/ui/did_you_mean/issue-40396.stderr
index 3f6886b..86bbf2b 100644
--- a/src/test/ui/did_you_mean/issue-40396.stderr
+++ b/src/test/ui/did_you_mean/issue-40396.stderr
@@ -80,17 +80,13 @@
   --> $DIR/issue-40396.rs:2:13
    |
 LL |     (0..13).collect<Vec<i32>>();
-   |             ^^^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |             ^^^^^^^ help: use parentheses to call the method: `collect()`
 
 error[E0615]: attempted to take value of method `collect` on type `std::ops::Range<{integer}>`
   --> $DIR/issue-40396.rs:18:13
    |
 LL |     (0..13).collect<Vec<i32>();
-   |             ^^^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |             ^^^^^^^ help: use parentheses to call the method: `collect()`
 
 error[E0308]: mismatched types
   --> $DIR/issue-40396.rs:18:29
diff --git a/src/test/ui/dst/dst-bad-assign-2.stderr b/src/test/ui/dst/dst-bad-assign-2.stderr
index 63c95c3..4e1e67c 100644
--- a/src/test/ui/dst/dst-bad-assign-2.stderr
+++ b/src/test/ui/dst/dst-bad-assign-2.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn ToBar`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the left-hand-side of an assignment must have a statically known size
 
 error: aborting due to previous error
diff --git a/src/test/ui/dst/dst-bad-assign-3.stderr b/src/test/ui/dst/dst-bad-assign-3.stderr
index d0fe27e..0c4f866 100644
--- a/src/test/ui/dst/dst-bad-assign-3.stderr
+++ b/src/test/ui/dst/dst-bad-assign-3.stderr
@@ -14,7 +14,7 @@
    |     ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn ToBar`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the left-hand-side of an assignment must have a statically known size
 
 error: aborting due to 2 previous errors
diff --git a/src/test/ui/dst/dst-bad-assign.stderr b/src/test/ui/dst/dst-bad-assign.stderr
index 2ae732e..a60d9d6 100644
--- a/src/test/ui/dst/dst-bad-assign.stderr
+++ b/src/test/ui/dst/dst-bad-assign.stderr
@@ -14,7 +14,7 @@
    |     ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn ToBar`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the left-hand-side of an assignment must have a statically known size
 
 error: aborting due to 2 previous errors
diff --git a/src/test/ui/dst/dst-bad-deep-2.stderr b/src/test/ui/dst/dst-bad-deep-2.stderr
index 6198c7e..cb27351 100644
--- a/src/test/ui/dst/dst-bad-deep-2.stderr
+++ b/src/test/ui/dst/dst-bad-deep-2.stderr
@@ -5,7 +5,7 @@
    |                              ^^^^^ doesn't have a size known at compile-time
    |
    = help: within `(([isize],),)`, the trait `std::marker::Sized` is not implemented for `[isize]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `([isize],)`
    = note: required because it appears within the type `(([isize],),)`
    = note: tuples must have a statically known size to be initialized
diff --git a/src/test/ui/dst/dst-bad-deep.stderr b/src/test/ui/dst/dst-bad-deep.stderr
index 509dbfe..521adf6 100644
--- a/src/test/ui/dst/dst-bad-deep.stderr
+++ b/src/test/ui/dst/dst-bad-deep.stderr
@@ -5,7 +5,7 @@
    |                                  ^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Fat<Fat<[isize]>>`, the trait `std::marker::Sized` is not implemented for `[isize]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Fat<[isize]>`
    = note: required because it appears within the type `Fat<Fat<[isize]>>`
    = note: structs must have a statically known size to be initialized
diff --git a/src/test/ui/dst/dst-object-from-unsized-type.stderr b/src/test/ui/dst/dst-object-from-unsized-type.stderr
index 3b333ce..4851ca1 100644
--- a/src/test/ui/dst/dst-object-from-unsized-type.stderr
+++ b/src/test/ui/dst/dst-object-from-unsized-type.stderr
@@ -5,7 +5,7 @@
    |                   ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: required for the cast to the object type `dyn Foo`
 
@@ -16,7 +16,7 @@
    |                   ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: required for the cast to the object type `dyn Foo`
 
@@ -27,7 +27,7 @@
    |                        ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required for the cast to the object type `dyn Foo`
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
@@ -37,7 +37,7 @@
    |                   ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required for the cast to the object type `dyn Foo`
 
 error: aborting due to 4 previous errors
diff --git a/src/test/ui/dst/dst-sized-trait-param.stderr b/src/test/ui/dst/dst-sized-trait-param.stderr
index e01bf24..40dc997 100644
--- a/src/test/ui/dst/dst-sized-trait-param.stderr
+++ b/src/test/ui/dst/dst-sized-trait-param.stderr
@@ -5,7 +5,7 @@
    |      ^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[isize]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error[E0277]: the size for values of type `[usize]` cannot be known at compilation time
   --> $DIR/dst-sized-trait-param.rs:10:6
@@ -14,7 +14,7 @@
    |      ^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[usize]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error: aborting due to 2 previous errors
 
diff --git a/src/test/ui/error-codes/E0277.stderr b/src/test/ui/error-codes/E0277.stderr
index 0cfe04a..e5e416d 100644
--- a/src/test/ui/error-codes/E0277.stderr
+++ b/src/test/ui/error-codes/E0277.stderr
@@ -5,7 +5,7 @@
    |      ^ borrow the `Path` instead
    |
    = help: within `std::path::Path`, the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `std::path::Path`
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
diff --git a/src/test/ui/error-codes/E0615.stderr b/src/test/ui/error-codes/E0615.stderr
index 4239486..d86ee5b 100644
--- a/src/test/ui/error-codes/E0615.stderr
+++ b/src/test/ui/error-codes/E0615.stderr
@@ -2,9 +2,7 @@
   --> $DIR/E0615.rs:11:7
    |
 LL |     f.method; //~ ERROR E0615
-   |       ^^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |       ^^^^^^ help: use parentheses to call the method: `method()`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/extern/extern-types-unsized.stderr b/src/test/ui/extern/extern-types-unsized.stderr
index 48d0aa8..4e4f555 100644
--- a/src/test/ui/extern/extern-types-unsized.stderr
+++ b/src/test/ui/extern/extern-types-unsized.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `A`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 note: required by `assert_sized`
   --> $DIR/extern-types-unsized.rs:19:1
    |
@@ -19,7 +19,7 @@
    |     ^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Foo`, the trait `std::marker::Sized` is not implemented for `A`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Foo`
 note: required by `assert_sized`
   --> $DIR/extern-types-unsized.rs:19:1
@@ -34,7 +34,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Bar<A>`, the trait `std::marker::Sized` is not implemented for `A`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Bar<A>`
 note: required by `assert_sized`
   --> $DIR/extern-types-unsized.rs:19:1
@@ -49,7 +49,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Bar<Bar<A>>`, the trait `std::marker::Sized` is not implemented for `A`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Bar<A>`
    = note: required because it appears within the type `Bar<Bar<A>>`
 note: required by `assert_sized`
diff --git a/src/test/ui/feature-gates/feature-gate-abi.rs b/src/test/ui/feature-gates/feature-gate-abi.rs
index 2229e6e..41c9f79 100644
--- a/src/test/ui/feature-gates/feature-gate-abi.rs
+++ b/src/test/ui/feature-gates/feature-gate-abi.rs
@@ -1,3 +1,4 @@
+// only-x86_64
 // ignore-tidy-linelength
 // gate-test-intrinsics
 // gate-test-platform_intrinsics
diff --git a/src/test/ui/feature-gates/feature-gate-abi.stderr b/src/test/ui/feature-gates/feature-gate-abi.stderr
index efcd2ef..d528788 100644
--- a/src/test/ui/feature-gates/feature-gate-abi.stderr
+++ b/src/test/ui/feature-gates/feature-gate-abi.stderr
@@ -1,5 +1,5 @@
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:11:1
+  --> $DIR/feature-gate-abi.rs:12:1
    |
 LL | extern "rust-intrinsic" fn f1() {} //~ ERROR intrinsics are subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -7,7 +7,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:12:1
+  --> $DIR/feature-gate-abi.rs:13:1
    |
 LL | extern "platform-intrinsic" fn f2() {} //~ ERROR platform intrinsics are experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -15,7 +15,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:13:1
+  --> $DIR/feature-gate-abi.rs:14:1
    |
 LL | extern "vectorcall" fn f3() {} //~ ERROR vectorcall is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -23,7 +23,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:14:1
+  --> $DIR/feature-gate-abi.rs:15:1
    |
 LL | extern "rust-call" fn f4() {} //~ ERROR rust-call ABI is subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -31,7 +31,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:15:1
+  --> $DIR/feature-gate-abi.rs:16:1
    |
 LL | extern "msp430-interrupt" fn f5() {} //~ ERROR msp430-interrupt ABI is experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -39,7 +39,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:16:1
+  --> $DIR/feature-gate-abi.rs:17:1
    |
 LL | extern "ptx-kernel" fn f6() {} //~ ERROR PTX ABIs are experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -47,7 +47,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:17:1
+  --> $DIR/feature-gate-abi.rs:18:1
    |
 LL | extern "x86-interrupt" fn f7() {} //~ ERROR x86-interrupt ABI is experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -55,7 +55,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:18:1
+  --> $DIR/feature-gate-abi.rs:19:1
    |
 LL | extern "thiscall" fn f8() {} //~ ERROR thiscall is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -63,7 +63,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:19:1
+  --> $DIR/feature-gate-abi.rs:20:1
    |
 LL | extern "amdgpu-kernel" fn f9() {} //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -71,7 +71,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:23:5
+  --> $DIR/feature-gate-abi.rs:24:5
    |
 LL |     extern "rust-intrinsic" fn m1(); //~ ERROR intrinsics are subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -79,7 +79,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:24:5
+  --> $DIR/feature-gate-abi.rs:25:5
    |
 LL |     extern "platform-intrinsic" fn m2(); //~ ERROR platform intrinsics are experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -87,7 +87,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:25:5
+  --> $DIR/feature-gate-abi.rs:26:5
    |
 LL |     extern "vectorcall" fn m3(); //~ ERROR vectorcall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -95,7 +95,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:26:5
+  --> $DIR/feature-gate-abi.rs:27:5
    |
 LL |     extern "rust-call" fn m4(); //~ ERROR rust-call ABI is subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -103,7 +103,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:27:5
+  --> $DIR/feature-gate-abi.rs:28:5
    |
 LL |     extern "msp430-interrupt" fn m5(); //~ ERROR msp430-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -111,7 +111,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:28:5
+  --> $DIR/feature-gate-abi.rs:29:5
    |
 LL |     extern "ptx-kernel" fn m6(); //~ ERROR PTX ABIs are experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -119,7 +119,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:29:5
+  --> $DIR/feature-gate-abi.rs:30:5
    |
 LL |     extern "x86-interrupt" fn m7(); //~ ERROR x86-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -127,7 +127,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:30:5
+  --> $DIR/feature-gate-abi.rs:31:5
    |
 LL |     extern "thiscall" fn m8(); //~ ERROR thiscall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -135,7 +135,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:31:5
+  --> $DIR/feature-gate-abi.rs:32:5
    |
 LL |     extern "amdgpu-kernel" fn m9(); //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -143,7 +143,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:33:5
+  --> $DIR/feature-gate-abi.rs:34:5
    |
 LL |     extern "rust-intrinsic" fn dm1() {} //~ ERROR intrinsics are subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -151,7 +151,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:34:5
+  --> $DIR/feature-gate-abi.rs:35:5
    |
 LL |     extern "platform-intrinsic" fn dm2() {} //~ ERROR platform intrinsics are experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -159,7 +159,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:35:5
+  --> $DIR/feature-gate-abi.rs:36:5
    |
 LL |     extern "vectorcall" fn dm3() {} //~ ERROR vectorcall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -167,7 +167,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:36:5
+  --> $DIR/feature-gate-abi.rs:37:5
    |
 LL |     extern "rust-call" fn dm4() {} //~ ERROR rust-call ABI is subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -175,7 +175,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:37:5
+  --> $DIR/feature-gate-abi.rs:38:5
    |
 LL |     extern "msp430-interrupt" fn dm5() {} //~ ERROR msp430-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -183,7 +183,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:38:5
+  --> $DIR/feature-gate-abi.rs:39:5
    |
 LL |     extern "ptx-kernel" fn dm6() {} //~ ERROR PTX ABIs are experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -191,7 +191,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:39:5
+  --> $DIR/feature-gate-abi.rs:40:5
    |
 LL |     extern "x86-interrupt" fn dm7() {} //~ ERROR x86-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -199,7 +199,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:40:5
+  --> $DIR/feature-gate-abi.rs:41:5
    |
 LL |     extern "thiscall" fn dm8() {} //~ ERROR thiscall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -207,7 +207,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:41:5
+  --> $DIR/feature-gate-abi.rs:42:5
    |
 LL |     extern "amdgpu-kernel" fn dm9() {} //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -215,7 +215,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:48:5
+  --> $DIR/feature-gate-abi.rs:49:5
    |
 LL |     extern "rust-intrinsic" fn m1() {} //~ ERROR intrinsics are subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -223,7 +223,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:49:5
+  --> $DIR/feature-gate-abi.rs:50:5
    |
 LL |     extern "platform-intrinsic" fn m2() {} //~ ERROR platform intrinsics are experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -231,7 +231,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:50:5
+  --> $DIR/feature-gate-abi.rs:51:5
    |
 LL |     extern "vectorcall" fn m3() {} //~ ERROR vectorcall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -239,7 +239,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:51:5
+  --> $DIR/feature-gate-abi.rs:52:5
    |
 LL |     extern "rust-call" fn m4() {} //~ ERROR rust-call ABI is subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -247,7 +247,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:52:5
+  --> $DIR/feature-gate-abi.rs:53:5
    |
 LL |     extern "msp430-interrupt" fn m5() {} //~ ERROR msp430-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -255,7 +255,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:53:5
+  --> $DIR/feature-gate-abi.rs:54:5
    |
 LL |     extern "ptx-kernel" fn m6() {} //~ ERROR PTX ABIs are experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -263,7 +263,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:54:5
+  --> $DIR/feature-gate-abi.rs:55:5
    |
 LL |     extern "x86-interrupt" fn m7() {} //~ ERROR x86-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -271,7 +271,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:55:5
+  --> $DIR/feature-gate-abi.rs:56:5
    |
 LL |     extern "thiscall" fn m8() {} //~ ERROR thiscall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -279,7 +279,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:56:5
+  --> $DIR/feature-gate-abi.rs:57:5
    |
 LL |     extern "amdgpu-kernel" fn m9() {} //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -287,7 +287,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:61:5
+  --> $DIR/feature-gate-abi.rs:62:5
    |
 LL |     extern "rust-intrinsic" fn im1() {} //~ ERROR intrinsics are subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -295,7 +295,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:62:5
+  --> $DIR/feature-gate-abi.rs:63:5
    |
 LL |     extern "platform-intrinsic" fn im2() {} //~ ERROR platform intrinsics are experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -303,7 +303,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:63:5
+  --> $DIR/feature-gate-abi.rs:64:5
    |
 LL |     extern "vectorcall" fn im3() {} //~ ERROR vectorcall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -311,7 +311,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:64:5
+  --> $DIR/feature-gate-abi.rs:65:5
    |
 LL |     extern "rust-call" fn im4() {} //~ ERROR rust-call ABI is subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -319,7 +319,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:65:5
+  --> $DIR/feature-gate-abi.rs:66:5
    |
 LL |     extern "msp430-interrupt" fn im5() {} //~ ERROR msp430-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -327,7 +327,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:66:5
+  --> $DIR/feature-gate-abi.rs:67:5
    |
 LL |     extern "ptx-kernel" fn im6() {} //~ ERROR PTX ABIs are experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -335,7 +335,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:67:5
+  --> $DIR/feature-gate-abi.rs:68:5
    |
 LL |     extern "x86-interrupt" fn im7() {} //~ ERROR x86-interrupt ABI is experimental
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -343,7 +343,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:68:5
+  --> $DIR/feature-gate-abi.rs:69:5
    |
 LL |     extern "thiscall" fn im8() {} //~ ERROR thiscall is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -351,7 +351,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:69:5
+  --> $DIR/feature-gate-abi.rs:70:5
    |
 LL |     extern "amdgpu-kernel" fn im9() {} //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -359,7 +359,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:73:11
+  --> $DIR/feature-gate-abi.rs:74:11
    |
 LL | type A1 = extern "rust-intrinsic" fn(); //~ ERROR intrinsics are subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -367,7 +367,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:74:11
+  --> $DIR/feature-gate-abi.rs:75:11
    |
 LL | type A2 = extern "platform-intrinsic" fn(); //~ ERROR platform intrinsics are experimental
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -375,7 +375,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:75:11
+  --> $DIR/feature-gate-abi.rs:76:11
    |
 LL | type A3 = extern "vectorcall" fn(); //~ ERROR vectorcall is experimental and subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -383,7 +383,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:76:11
+  --> $DIR/feature-gate-abi.rs:77:11
    |
 LL | type A4 = extern "rust-call" fn(); //~ ERROR rust-call ABI is subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^^
@@ -391,7 +391,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:77:11
+  --> $DIR/feature-gate-abi.rs:78:11
    |
 LL | type A5 = extern "msp430-interrupt" fn(); //~ ERROR msp430-interrupt ABI is experimental
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -399,7 +399,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:78:11
+  --> $DIR/feature-gate-abi.rs:79:11
    |
 LL | type A6 = extern "ptx-kernel" fn (); //~ ERROR PTX ABIs are experimental and subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -407,7 +407,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:79:11
+  --> $DIR/feature-gate-abi.rs:80:11
    |
 LL | type A7 = extern "x86-interrupt" fn(); //~ ERROR x86-interrupt ABI is experimental
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -415,7 +415,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:80:11
+  --> $DIR/feature-gate-abi.rs:81:11
    |
 LL | type A8 = extern "thiscall" fn(); //~ ERROR thiscall is experimental and subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^
@@ -423,7 +423,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:81:11
+  --> $DIR/feature-gate-abi.rs:82:11
    |
 LL | type A9 = extern "amdgpu-kernel" fn(); //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -431,7 +431,7 @@
    = help: add #![feature(abi_amdgpu_kernel)] to the crate attributes to enable
 
 error[E0658]: intrinsics are subject to change
-  --> $DIR/feature-gate-abi.rs:84:1
+  --> $DIR/feature-gate-abi.rs:85:1
    |
 LL | extern "rust-intrinsic" {} //~ ERROR intrinsics are subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -439,7 +439,7 @@
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
 error[E0658]: platform intrinsics are experimental and possibly buggy (see issue #27731)
-  --> $DIR/feature-gate-abi.rs:85:1
+  --> $DIR/feature-gate-abi.rs:86:1
    |
 LL | extern "platform-intrinsic" {} //~ ERROR platform intrinsics are experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -447,7 +447,7 @@
    = help: add #![feature(platform_intrinsics)] to the crate attributes to enable
 
 error[E0658]: vectorcall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:86:1
+  --> $DIR/feature-gate-abi.rs:87:1
    |
 LL | extern "vectorcall" {} //~ ERROR vectorcall is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^
@@ -455,7 +455,7 @@
    = help: add #![feature(abi_vectorcall)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-abi.rs:87:1
+  --> $DIR/feature-gate-abi.rs:88:1
    |
 LL | extern "rust-call" {} //~ ERROR rust-call ABI is subject to change
    | ^^^^^^^^^^^^^^^^^^^^^
@@ -463,7 +463,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: msp430-interrupt ABI is experimental and subject to change (see issue #38487)
-  --> $DIR/feature-gate-abi.rs:88:1
+  --> $DIR/feature-gate-abi.rs:89:1
    |
 LL | extern "msp430-interrupt" {} //~ ERROR msp430-interrupt ABI is experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -471,7 +471,7 @@
    = help: add #![feature(abi_msp430_interrupt)] to the crate attributes to enable
 
 error[E0658]: PTX ABIs are experimental and subject to change (see issue #38788)
-  --> $DIR/feature-gate-abi.rs:89:1
+  --> $DIR/feature-gate-abi.rs:90:1
    |
 LL | extern "ptx-kernel" {} //~ ERROR PTX ABIs are experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^
@@ -479,7 +479,7 @@
    = help: add #![feature(abi_ptx)] to the crate attributes to enable
 
 error[E0658]: x86-interrupt ABI is experimental and subject to change (see issue #40180)
-  --> $DIR/feature-gate-abi.rs:90:1
+  --> $DIR/feature-gate-abi.rs:91:1
    |
 LL | extern "x86-interrupt" {} //~ ERROR x86-interrupt ABI is experimental
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -487,7 +487,7 @@
    = help: add #![feature(abi_x86_interrupt)] to the crate attributes to enable
 
 error[E0658]: thiscall is experimental and subject to change
-  --> $DIR/feature-gate-abi.rs:91:1
+  --> $DIR/feature-gate-abi.rs:92:1
    |
 LL | extern "thiscall" {} //~ ERROR thiscall is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^
@@ -495,7 +495,7 @@
    = help: add #![feature(abi_thiscall)] to the crate attributes to enable
 
 error[E0658]: amdgpu-kernel ABI is experimental and subject to change (see issue #51575)
-  --> $DIR/feature-gate-abi.rs:92:1
+  --> $DIR/feature-gate-abi.rs:93:1
    |
 LL | extern "amdgpu-kernel" {} //~ ERROR amdgpu-kernel ABI is experimental and subject to change
    | ^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/feature-gates/feature-gate-alloc-error-handler.rs b/src/test/ui/feature-gates/feature-gate-alloc-error-handler.rs
index fbd9291..daa2bb5 100644
--- a/src/test/ui/feature-gates/feature-gate-alloc-error-handler.rs
+++ b/src/test/ui/feature-gates/feature-gate-alloc-error-handler.rs
@@ -9,3 +9,6 @@
 fn oom(info: Layout) -> ! {
     loop {}
 }
+
+#[panic_handler]
+fn panic(_: &core::panic::PanicInfo) -> ! { loop {} }
diff --git a/src/test/ui/feature-gates/feature-gate-allow_fail.rs b/src/test/ui/feature-gates/feature-gate-allow_fail.rs
index cd8b096..f9ad485 100644
--- a/src/test/ui/feature-gates/feature-gate-allow_fail.rs
+++ b/src/test/ui/feature-gates/feature-gate-allow_fail.rs
@@ -5,3 +5,4 @@
     assert!(false);
 }
 
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.rs b/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.rs
index 00a3103..84dd1b9 100644
--- a/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.rs
+++ b/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.rs
@@ -6,5 +6,5 @@
 
 fn main() {
     let _ = async {}; //~ ERROR cannot find struct, variant or union type `async`
-    let _ = async || {}; //~ ERROR cannot find value `async` in this scope
+    let _ = async || { true }; //~ ERROR cannot find value `async` in this scope
 }
diff --git a/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.stderr b/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.stderr
index 7754dbb..450b2c4 100644
--- a/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.stderr
+++ b/src/test/ui/feature-gates/feature-gate-async-await-2015-edition.stderr
@@ -7,7 +7,7 @@
 error[E0425]: cannot find value `async` in this scope
   --> $DIR/feature-gate-async-await-2015-edition.rs:9:13
    |
-LL |     let _ = async || {}; //~ ERROR cannot find value `async` in this scope
+LL |     let _ = async || { true }; //~ ERROR cannot find value `async` in this scope
    |             ^^^^^ not found in this scope
 
 error[E0658]: async fn is unstable (see issue #50547)
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.rs b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.rs
deleted file mode 100644
index 9515380..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.rs
+++ /dev/null
@@ -1,5 +0,0 @@
-// gate-test-cfg_attr_multi
-
-#![cfg_attr(all(), warn(nonstandard_style), allow(unused_attributes))]
-//~^ ERROR cfg_attr with zero or more than one attributes is experimental
-fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.stderr b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.stderr
deleted file mode 100644
index 088e6df..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-1.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0658]: cfg_attr with zero or more than one attributes is experimental (see issue #54881)
-  --> $DIR/feature-gate-cfg-attr-multi-1.rs:3:1
-   |
-LL | #![cfg_attr(all(), warn(nonstandard_style), allow(unused_attributes))]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = help: add #![feature(cfg_attr_multi)] to the crate attributes to enable
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0658`.
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.rs b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.rs
deleted file mode 100644
index cf02432..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.rs
+++ /dev/null
@@ -1,3 +0,0 @@
-#![cfg_attr(all(),)]
-//~^ ERROR cfg_attr with zero or more than one attributes is experimental
-fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.stderr b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.stderr
deleted file mode 100644
index a018761..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-2.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0658]: cfg_attr with zero or more than one attributes is experimental (see issue #54881)
-  --> $DIR/feature-gate-cfg-attr-multi-2.rs:1:1
-   |
-LL | #![cfg_attr(all(),)]
-   | ^^^^^^^^^^^^^^^^^^^^
-   |
-   = help: add #![feature(cfg_attr_multi)] to the crate attributes to enable
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0658`.
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-1.rs b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-1.rs
deleted file mode 100644
index e473792..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-1.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-// Test that settingt the featute gate while using its functionality doesn't error.
-
-// compile-pass
-
-#![cfg_attr(all(), feature(cfg_attr_multi), crate_type="bin")]
-
-fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-2.rs b/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-2.rs
deleted file mode 100644
index df74054..0000000
--- a/src/test/ui/feature-gates/feature-gate-cfg-attr-multi-bootstrap-2.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-// Test that settingt the featute gate while using its functionality doesn't error.
-// Specifically, if there's a cfg-attr *before* the feature gate.
-
-// compile-pass
-
-#![cfg_attr(all(),)]
-#![cfg_attr(all(), feature(cfg_attr_multi), crate_type="bin")]
-
-fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-const_fn.rs b/src/test/ui/feature-gates/feature-gate-const_fn.rs
index 5a0a5ac..f46d1dc 100644
--- a/src/test/ui/feature-gates/feature-gate-const_fn.rs
+++ b/src/test/ui/feature-gates/feature-gate-const_fn.rs
@@ -9,14 +9,16 @@
                                 //~| ERROR trait fns cannot be declared const
 }
 
-impl Foo {
-    const fn baz() -> u32 { 0 } // ok
-}
-
 impl Foo for u32 {
     const fn foo() -> u32 { 0 } //~ ERROR trait fns cannot be declared const
 }
 
+trait Bar {}
+
+impl dyn Bar {
+    const fn baz() -> u32 { 0 } // ok
+}
+
 static FOO: usize = foo();
 const BAR: usize = foo();
 
diff --git a/src/test/ui/feature-gates/feature-gate-const_fn.stderr b/src/test/ui/feature-gates/feature-gate-const_fn.stderr
index 32a5771..b3fc587 100644
--- a/src/test/ui/feature-gates/feature-gate-const_fn.stderr
+++ b/src/test/ui/feature-gates/feature-gate-const_fn.stderr
@@ -11,7 +11,7 @@
    |     ^^^^^ trait fns cannot be const
 
 error[E0379]: trait fns cannot be declared const
-  --> $DIR/feature-gate-const_fn.rs:17:5
+  --> $DIR/feature-gate-const_fn.rs:13:5
    |
 LL |     const fn foo() -> u32 { 0 } //~ ERROR trait fns cannot be declared const
    |     ^^^^^ trait fns cannot be const
diff --git a/src/test/ui/feature-gates/feature-gate-doc_keyword.rs b/src/test/ui/feature-gates/feature-gate-doc_keyword.rs
index f417828..b08940e 100644
--- a/src/test/ui/feature-gates/feature-gate-doc_keyword.rs
+++ b/src/test/ui/feature-gates/feature-gate-doc_keyword.rs
@@ -1,3 +1,5 @@
 #[doc(keyword = "match")] //~ ERROR: #[doc(keyword = "...")] is experimental
 /// wonderful
 mod foo{}
+
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-dropck-ugeh.rs b/src/test/ui/feature-gates/feature-gate-dropck-ugeh.rs
index 02aa500..a2377cd 100644
--- a/src/test/ui/feature-gates/feature-gate-dropck-ugeh.rs
+++ b/src/test/ui/feature-gates/feature-gate-dropck-ugeh.rs
@@ -1,14 +1,11 @@
 // gate-test-dropck_parametricity
 
 // Ensure that attempts to use the unsafe attribute are feature-gated.
-
 // Example adapted from RFC 1238 text (just left out the feature gate).
 
 // https://github.com/rust-lang/rfcs/blob/master/text/1238-nonparametric-dropck.md
 //     #example-of-the-unguarded-escape-hatch
 
-// #![feature(dropck_parametricity)]
-
 use std::cell::Cell;
 
 struct Concrete<'a>(u32, Cell<Option<&'a Concrete<'a>>>);
@@ -18,6 +15,7 @@
 impl<T> Drop for Foo<T> {
     #[unsafe_destructor_blind_to_params] // This is the UGEH attribute
     //~^ ERROR unsafe_destructor_blind_to_params has been replaced
+    //~| WARN use of deprecated attribute `dropck_parametricity`
     fn drop(&mut self) { }
 }
 
@@ -29,4 +27,3 @@
     foo.data[0].1.set(Some(&foo.data[1]));
     foo.data[1].1.set(Some(&foo.data[0]));
 }
-
diff --git a/src/test/ui/feature-gates/feature-gate-dropck-ugeh.stderr b/src/test/ui/feature-gates/feature-gate-dropck-ugeh.stderr
index 99ca454b..bc62fc0 100644
--- a/src/test/ui/feature-gates/feature-gate-dropck-ugeh.stderr
+++ b/src/test/ui/feature-gates/feature-gate-dropck-ugeh.stderr
@@ -1,11 +1,19 @@
 error[E0658]: unsafe_destructor_blind_to_params has been replaced by may_dangle and will be removed in the future (see issue #28498)
-  --> $DIR/feature-gate-dropck-ugeh.rs:19:5
+  --> $DIR/feature-gate-dropck-ugeh.rs:16:5
    |
 LL |     #[unsafe_destructor_blind_to_params] // This is the UGEH attribute
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(dropck_parametricity)] to the crate attributes to enable
 
+warning: use of deprecated attribute `dropck_parametricity`: unsafe_destructor_blind_to_params has been replaced by may_dangle and will be removed in the future. See https://github.com/rust-lang/rust/issues/34761
+  --> $DIR/feature-gate-dropck-ugeh.rs:16:5
+   |
+LL |     #[unsafe_destructor_blind_to_params] // This is the UGEH attribute
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace this attribute with `#[may_dangle]`
+   |
+   = note: #[warn(deprecated)] on by default
+
 error: aborting due to previous error
 
 For more information about this error, try `rustc --explain E0658`.
diff --git a/src/test/ui/feature-gates/feature-gate-existential-type.rs b/src/test/ui/feature-gates/feature-gate-existential-type.rs
index e14467d..6dfd2d1 100644
--- a/src/test/ui/feature-gates/feature-gate-existential-type.rs
+++ b/src/test/ui/feature-gates/feature-gate-existential-type.rs
@@ -1,15 +1,17 @@
 // Check that existential types must be ungated to use the `existential` keyword
 
-
-
 existential type Foo: std::fmt::Debug; //~ ERROR existential types are unstable
 
 trait Bar {
     type Baa: std::fmt::Debug;
+    fn define() -> Self::Baa;
 }
 
 impl Bar for () {
     existential type Baa: std::fmt::Debug; //~ ERROR existential types are unstable
+    fn define() -> Self::Baa { 0 }
 }
 
+fn define() -> Foo { 0 }
+
 fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-existential-type.stderr b/src/test/ui/feature-gates/feature-gate-existential-type.stderr
index e88bdc0..e83d5cd 100644
--- a/src/test/ui/feature-gates/feature-gate-existential-type.stderr
+++ b/src/test/ui/feature-gates/feature-gate-existential-type.stderr
@@ -1,5 +1,5 @@
 error[E0658]: existential types are unstable (see issue #34511)
-  --> $DIR/feature-gate-existential-type.rs:5:1
+  --> $DIR/feature-gate-existential-type.rs:3:1
    |
 LL | existential type Foo: std::fmt::Debug; //~ ERROR existential types are unstable
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -7,7 +7,7 @@
    = help: add #![feature(existential_type)] to the crate attributes to enable
 
 error[E0658]: existential types are unstable (see issue #34511)
-  --> $DIR/feature-gate-existential-type.rs:12:5
+  --> $DIR/feature-gate-existential-type.rs:11:5
    |
 LL |     existential type Baa: std::fmt::Debug; //~ ERROR existential types are unstable
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/feature-gates/feature-gate-generators.rs b/src/test/ui/feature-gates/feature-gate-generators.rs
index 88e8781..cee930f 100644
--- a/src/test/ui/feature-gates/feature-gate-generators.rs
+++ b/src/test/ui/feature-gates/feature-gate-generators.rs
@@ -1,3 +1,4 @@
 fn main() {
     yield true; //~ ERROR yield syntax is experimental
+                //~^ ERROR yield statement outside of generator literal
 }
diff --git a/src/test/ui/feature-gates/feature-gate-generators.stderr b/src/test/ui/feature-gates/feature-gate-generators.stderr
index 4b90cd1c..aea1e00 100644
--- a/src/test/ui/feature-gates/feature-gate-generators.stderr
+++ b/src/test/ui/feature-gates/feature-gate-generators.stderr
@@ -6,6 +6,13 @@
    |
    = help: add #![feature(generators)] to the crate attributes to enable
 
-error: aborting due to previous error
+error[E0627]: yield statement outside of generator literal
+  --> $DIR/feature-gate-generators.rs:2:5
+   |
+LL |     yield true; //~ ERROR yield syntax is experimental
+   |     ^^^^^^^^^^
 
-For more information about this error, try `rustc --explain E0658`.
+error: aborting due to 2 previous errors
+
+Some errors occurred: E0627, E0658.
+For more information about an error, try `rustc --explain E0627`.
diff --git a/src/test/ui/feature-gates/feature-gate-generic_associated_types.rs b/src/test/ui/feature-gates/feature-gate-generic_associated_types.rs
index 86a1f5c..17548d7 100644
--- a/src/test/ui/feature-gates/feature-gate-generic_associated_types.rs
+++ b/src/test/ui/feature-gates/feature-gate-generic_associated_types.rs
@@ -11,9 +11,9 @@
 struct Foo;
 
 impl PointerFamily<u32> for Foo {
-    type Pointer<usize> = Box<usize>;
+    type Pointer<Usize> = Box<Usize>;
     //~^ ERROR generic associated types are unstable
-    type Pointer2<u32> = Box<u32>;
+    type Pointer2<U32> = Box<U32>;
     //~^ ERROR generic associated types are unstable
 }
 
diff --git a/src/test/ui/feature-gates/feature-gate-generic_associated_types.stderr b/src/test/ui/feature-gates/feature-gate-generic_associated_types.stderr
index 392d0f1..8a207c9 100644
--- a/src/test/ui/feature-gates/feature-gate-generic_associated_types.stderr
+++ b/src/test/ui/feature-gates/feature-gate-generic_associated_types.stderr
@@ -25,7 +25,7 @@
 error[E0658]: generic associated types are unstable (see issue #44265)
   --> $DIR/feature-gate-generic_associated_types.rs:14:5
    |
-LL |     type Pointer<usize> = Box<usize>;
+LL |     type Pointer<Usize> = Box<Usize>;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(generic_associated_types)] to the crate attributes to enable
@@ -33,7 +33,7 @@
 error[E0658]: generic associated types are unstable (see issue #44265)
   --> $DIR/feature-gate-generic_associated_types.rs:16:5
    |
-LL |     type Pointer2<u32> = Box<u32>;
+LL |     type Pointer2<U32> = Box<U32>;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(generic_associated_types)] to the crate attributes to enable
diff --git a/src/test/ui/feature-gates/feature-gate-intrinsics.rs b/src/test/ui/feature-gates/feature-gate-intrinsics.rs
index 0916d7f..d1da943 100644
--- a/src/test/ui/feature-gates/feature-gate-intrinsics.rs
+++ b/src/test/ui/feature-gates/feature-gate-intrinsics.rs
@@ -1,9 +1,7 @@
 extern "rust-intrinsic" {   //~ ERROR intrinsics are subject to change
-    fn bar();
+    fn bar(); //~ ERROR unrecognized intrinsic function: `bar`
 }
 
-extern "rust-intrinsic" fn baz() {  //~ ERROR intrinsics are subject to change
-}
+extern "rust-intrinsic" fn baz() {} //~ ERROR intrinsics are subject to change
 
-fn main() {
-}
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-intrinsics.stderr b/src/test/ui/feature-gates/feature-gate-intrinsics.stderr
index 034e2b1..092cb98 100644
--- a/src/test/ui/feature-gates/feature-gate-intrinsics.stderr
+++ b/src/test/ui/feature-gates/feature-gate-intrinsics.stderr
@@ -2,7 +2,7 @@
   --> $DIR/feature-gate-intrinsics.rs:1:1
    |
 LL | / extern "rust-intrinsic" {   //~ ERROR intrinsics are subject to change
-LL | |     fn bar();
+LL | |     fn bar(); //~ ERROR unrecognized intrinsic function: `bar`
 LL | | }
    | |_^
    |
@@ -11,12 +11,18 @@
 error[E0658]: intrinsics are subject to change
   --> $DIR/feature-gate-intrinsics.rs:5:1
    |
-LL | / extern "rust-intrinsic" fn baz() {  //~ ERROR intrinsics are subject to change
-LL | | }
-   | |_^
+LL | extern "rust-intrinsic" fn baz() {} //~ ERROR intrinsics are subject to change
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(intrinsics)] to the crate attributes to enable
 
-error: aborting due to 2 previous errors
+error[E0093]: unrecognized intrinsic function: `bar`
+  --> $DIR/feature-gate-intrinsics.rs:2:5
+   |
+LL |     fn bar(); //~ ERROR unrecognized intrinsic function: `bar`
+   |     ^^^^^^^^^ unrecognized intrinsic
 
-For more information about this error, try `rustc --explain E0658`.
+error: aborting due to 3 previous errors
+
+Some errors occurred: E0093, E0658.
+For more information about an error, try `rustc --explain E0093`.
diff --git a/src/test/ui/feature-gates/feature-gate-lang-items.rs b/src/test/ui/feature-gates/feature-gate-lang-items.rs
index 943ca16..93262f2 100644
--- a/src/test/ui/feature-gates/feature-gate-lang-items.rs
+++ b/src/test/ui/feature-gates/feature-gate-lang-items.rs
@@ -1,5 +1,5 @@
-#[lang="foo"]   //~ ERROR language items are subject to change
+#[lang = "foo"] //~ ERROR language items are subject to change
+                //~^ ERROR definition of an unknown language item: `foo`
 trait Foo {}
 
-fn main() {
-}
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-lang-items.stderr b/src/test/ui/feature-gates/feature-gate-lang-items.stderr
index 3383eaa..ccbb711 100644
--- a/src/test/ui/feature-gates/feature-gate-lang-items.stderr
+++ b/src/test/ui/feature-gates/feature-gate-lang-items.stderr
@@ -1,11 +1,18 @@
 error[E0658]: language items are subject to change
   --> $DIR/feature-gate-lang-items.rs:1:1
    |
-LL | #[lang="foo"]   //~ ERROR language items are subject to change
-   | ^^^^^^^^^^^^^
+LL | #[lang = "foo"] //~ ERROR language items are subject to change
+   | ^^^^^^^^^^^^^^^
    |
    = help: add #![feature(lang_items)] to the crate attributes to enable
 
-error: aborting due to previous error
+error[E0522]: definition of an unknown language item: `foo`
+  --> $DIR/feature-gate-lang-items.rs:1:1
+   |
+LL | #[lang = "foo"] //~ ERROR language items are subject to change
+   | ^^^^^^^^^^^^^^^ definition of unknown language item `foo`
 
-For more information about this error, try `rustc --explain E0658`.
+error: aborting due to 2 previous errors
+
+Some errors occurred: E0522, E0658.
+For more information about an error, try `rustc --explain E0522`.
diff --git a/src/test/ui/feature-gates/feature-gate-linkage.rs b/src/test/ui/feature-gates/feature-gate-linkage.rs
index 282c9a8..70f33cc 100644
--- a/src/test/ui/feature-gates/feature-gate-linkage.rs
+++ b/src/test/ui/feature-gates/feature-gate-linkage.rs
@@ -2,3 +2,5 @@
     #[linkage = "extern_weak"] static foo: isize;
     //~^ ERROR: the `linkage` attribute is experimental and not portable
 }
+
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-may-dangle.rs b/src/test/ui/feature-gates/feature-gate-may-dangle.rs
index 45666e9..20896e4 100644
--- a/src/test/ui/feature-gates/feature-gate-may-dangle.rs
+++ b/src/test/ui/feature-gates/feature-gate-may-dangle.rs
@@ -3,7 +3,9 @@
 // Check that `may_dangle` is rejected if `dropck_eyepatch` feature gate is absent.
 
 struct Pt<A>(A);
-impl<#[may_dangle] A> Drop for Pt<A> {
+unsafe impl<#[may_dangle] A> Drop for Pt<A> {
     //~^ ERROR may_dangle has unstable semantics and may be removed in the future
     fn drop(&mut self) { }
 }
+
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-may-dangle.stderr b/src/test/ui/feature-gates/feature-gate-may-dangle.stderr
index b537a58..6d21147 100644
--- a/src/test/ui/feature-gates/feature-gate-may-dangle.stderr
+++ b/src/test/ui/feature-gates/feature-gate-may-dangle.stderr
@@ -1,8 +1,8 @@
 error[E0658]: may_dangle has unstable semantics and may be removed in the future (see issue #34761)
-  --> $DIR/feature-gate-may-dangle.rs:6:6
+  --> $DIR/feature-gate-may-dangle.rs:6:13
    |
-LL | impl<#[may_dangle] A> Drop for Pt<A> {
-   |      ^^^^^^^^^^^^^
+LL | unsafe impl<#[may_dangle] A> Drop for Pt<A> {
+   |             ^^^^^^^^^^^^^
    |
    = help: add #![feature(dropck_eyepatch)] to the crate attributes to enable
 
diff --git a/src/test/ui/feature-gates/feature-gate-min_const_fn.rs b/src/test/ui/feature-gates/feature-gate-min_const_fn.rs
index e685b50..669631d 100644
--- a/src/test/ui/feature-gates/feature-gate-min_const_fn.rs
+++ b/src/test/ui/feature-gates/feature-gate-min_const_fn.rs
@@ -9,14 +9,16 @@
                                 //~| ERROR trait fns cannot be declared const
 }
 
-impl Foo {
-    const fn baz() -> u32 { 0 } // stabilized
-}
-
 impl Foo for u32 {
     const fn foo() -> u32 { 0 } //~ ERROR trait fns cannot be declared const
 }
 
+trait Bar {}
+
+impl dyn Bar {
+    const fn baz() -> u32 { 0 } // stabilized
+}
+
 static FOO: usize = foo();
 const BAR: usize = foo();
 
diff --git a/src/test/ui/feature-gates/feature-gate-min_const_fn.stderr b/src/test/ui/feature-gates/feature-gate-min_const_fn.stderr
index 998a224..bcc5b01 100644
--- a/src/test/ui/feature-gates/feature-gate-min_const_fn.stderr
+++ b/src/test/ui/feature-gates/feature-gate-min_const_fn.stderr
@@ -11,7 +11,7 @@
    |     ^^^^^ trait fns cannot be const
 
 error[E0379]: trait fns cannot be declared const
-  --> $DIR/feature-gate-min_const_fn.rs:17:5
+  --> $DIR/feature-gate-min_const_fn.rs:13:5
    |
 LL |     const fn foo() -> u32 { 0 } //~ ERROR trait fns cannot be declared const
    |     ^^^^^ trait fns cannot be const
diff --git a/src/test/ui/feature-gates/feature-gate-naked_functions.rs b/src/test/ui/feature-gates/feature-gate-naked_functions.rs
index 36bc636..16a51a1 100644
--- a/src/test/ui/feature-gates/feature-gate-naked_functions.rs
+++ b/src/test/ui/feature-gates/feature-gate-naked_functions.rs
@@ -7,3 +7,5 @@
 fn naked_2() -> isize {
     0
 }
+
+fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-never_type.rs b/src/test/ui/feature-gates/feature-gate-never_type.rs
index 44a3bdd..be8c27d 100644
--- a/src/test/ui/feature-gates/feature-gate-never_type.rs
+++ b/src/test/ui/feature-gates/feature-gate-never_type.rs
@@ -6,8 +6,8 @@
 
 type Ma = (u32, !, i32); //~ ERROR type is experimental
 type Meeshka = Vec<!>; //~ ERROR type is experimental
-type Mow = &fn(!) -> !; //~ ERROR type is experimental
-type Skwoz = &mut !; //~ ERROR type is experimental
+type Mow = &'static fn(!) -> !; //~ ERROR type is experimental
+type Skwoz = &'static mut !; //~ ERROR type is experimental
 
 impl Foo for Meeshka {
     type Wub = !; //~ ERROR type is experimental
diff --git a/src/test/ui/feature-gates/feature-gate-never_type.stderr b/src/test/ui/feature-gates/feature-gate-never_type.stderr
index 927758b..c4f8771 100644
--- a/src/test/ui/feature-gates/feature-gate-never_type.stderr
+++ b/src/test/ui/feature-gates/feature-gate-never_type.stderr
@@ -15,18 +15,18 @@
    = help: add #![feature(never_type)] to the crate attributes to enable
 
 error[E0658]: The `!` type is experimental (see issue #35121)
-  --> $DIR/feature-gate-never_type.rs:9:16
+  --> $DIR/feature-gate-never_type.rs:9:24
    |
-LL | type Mow = &fn(!) -> !; //~ ERROR type is experimental
-   |                ^
+LL | type Mow = &'static fn(!) -> !; //~ ERROR type is experimental
+   |                        ^
    |
    = help: add #![feature(never_type)] to the crate attributes to enable
 
 error[E0658]: The `!` type is experimental (see issue #35121)
-  --> $DIR/feature-gate-never_type.rs:10:19
+  --> $DIR/feature-gate-never_type.rs:10:27
    |
-LL | type Skwoz = &mut !; //~ ERROR type is experimental
-   |                   ^
+LL | type Skwoz = &'static mut !; //~ ERROR type is experimental
+   |                           ^
    |
    = help: add #![feature(never_type)] to the crate attributes to enable
 
diff --git a/src/test/ui/feature-gates/feature-gate-no_core.rs b/src/test/ui/feature-gates/feature-gate-no_core.rs
index 03b2378..40178ed 100644
--- a/src/test/ui/feature-gates/feature-gate-no_core.rs
+++ b/src/test/ui/feature-gates/feature-gate-no_core.rs
@@ -1,3 +1,5 @@
+#![crate_type = "rlib"]
+
 #![no_core] //~ ERROR no_core is experimental
 
-fn main() {}
+pub struct S {}
diff --git a/src/test/ui/feature-gates/feature-gate-no_core.stderr b/src/test/ui/feature-gates/feature-gate-no_core.stderr
index cb8fe25..7390051 100644
--- a/src/test/ui/feature-gates/feature-gate-no_core.stderr
+++ b/src/test/ui/feature-gates/feature-gate-no_core.stderr
@@ -1,5 +1,5 @@
 error[E0658]: no_core is experimental (see issue #29639)
-  --> $DIR/feature-gate-no_core.rs:1:1
+  --> $DIR/feature-gate-no_core.rs:3:1
    |
 LL | #![no_core] //~ ERROR no_core is experimental
    | ^^^^^^^^^^^
diff --git a/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.rs b/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.rs
index 9d70cbe..35c05b7 100644
--- a/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.rs
+++ b/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.rs
@@ -3,14 +3,10 @@
 
 struct DummyStruct;
 
-trait DummyTrait {
-    fn dummy(&self) {}
-}
-
 auto trait AutoDummyTrait {}
 //~^ ERROR auto traits are experimental and possibly buggy
 
-impl !DummyTrait for DummyStruct {}
+impl !AutoDummyTrait for DummyStruct {}
 //~^ ERROR negative trait bounds are not yet fully implemented; use marker types for now
 
 fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.stderr b/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.stderr
index c523147..e5d0a86 100644
--- a/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.stderr
+++ b/src/test/ui/feature-gates/feature-gate-optin-builtin-traits.stderr
@@ -1,5 +1,5 @@
 error[E0658]: auto traits are experimental and possibly buggy (see issue #13231)
-  --> $DIR/feature-gate-optin-builtin-traits.rs:10:1
+  --> $DIR/feature-gate-optin-builtin-traits.rs:6:1
    |
 LL | auto trait AutoDummyTrait {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -7,10 +7,10 @@
    = help: add #![feature(optin_builtin_traits)] to the crate attributes to enable
 
 error[E0658]: negative trait bounds are not yet fully implemented; use marker types for now (see issue #13231)
-  --> $DIR/feature-gate-optin-builtin-traits.rs:13:1
+  --> $DIR/feature-gate-optin-builtin-traits.rs:9:1
    |
-LL | impl !DummyTrait for DummyStruct {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | impl !AutoDummyTrait for DummyStruct {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(optin_builtin_traits)] to the crate attributes to enable
 
diff --git a/src/test/ui/feature-gates/feature-gate-repr-simd.rs b/src/test/ui/feature-gates/feature-gate-repr-simd.rs
index 67ae538..9d28f43 100644
--- a/src/test/ui/feature-gates/feature-gate-repr-simd.rs
+++ b/src/test/ui/feature-gates/feature-gate-repr-simd.rs
@@ -1,7 +1,7 @@
 #[repr(simd)] //~ error: SIMD types are experimental
 struct Foo(u64, u64);
 
-#[repr(C)]
+#[repr(C)] //~ warn: conflicting representation hints
 #[repr(simd)] //~ error: SIMD types are experimental
 struct Bar(u64, u64);
 
diff --git a/src/test/ui/feature-gates/feature-gate-repr-simd.stderr b/src/test/ui/feature-gates/feature-gate-repr-simd.stderr
index 161cc67..20cdbce 100644
--- a/src/test/ui/feature-gates/feature-gate-repr-simd.stderr
+++ b/src/test/ui/feature-gates/feature-gate-repr-simd.stderr
@@ -14,6 +14,15 @@
    |
    = help: add #![feature(repr_simd)] to the crate attributes to enable
 
+warning[E0566]: conflicting representation hints
+  --> $DIR/feature-gate-repr-simd.rs:4:8
+   |
+LL | #[repr(C)] //~ warn: conflicting representation hints
+   |        ^
+LL | #[repr(simd)] //~ error: SIMD types are experimental
+   |        ^^^^
+
 error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0658`.
+Some errors occurred: E0566, E0658.
+For more information about an error, try `rustc --explain E0566`.
diff --git a/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.rs b/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.rs
index f7ff3eb..2b23388 100644
--- a/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.rs
+++ b/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.rs
@@ -5,4 +5,4 @@
 #[rustc_variance] //~ ERROR the `#[rustc_variance]` attribute is just used for rustc unit tests and will never be stable
 #[rustc_error] //~ ERROR the `#[rustc_error]` attribute is just used for rustc unit tests and will never be stable
 
-fn main() {}
+fn main() {} //~ ERROR []
diff --git a/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.stderr b/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
index 2b90699..31e24f5 100644
--- a/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
+++ b/src/test/ui/feature-gates/feature-gate-rustc-attrs-1.stderr
@@ -14,6 +14,13 @@
    |
    = help: add #![feature(rustc_attrs)] to the crate attributes to enable
 
-error: aborting due to 2 previous errors
+error[E0208]: []
+  --> $DIR/feature-gate-rustc-attrs-1.rs:8:1
+   |
+LL | fn main() {} //~ ERROR []
+   | ^^^^^^^^^^^^
 
-For more information about this error, try `rustc --explain E0658`.
+error: aborting due to 3 previous errors
+
+Some errors occurred: E0208, E0658.
+For more information about an error, try `rustc --explain E0208`.
diff --git a/src/test/ui/feature-gates/feature-gate-start.rs b/src/test/ui/feature-gates/feature-gate-start.rs
index bf097c8..46a1279 100644
--- a/src/test/ui/feature-gates/feature-gate-start.rs
+++ b/src/test/ui/feature-gates/feature-gate-start.rs
@@ -1,2 +1,3 @@
 #[start]
-fn foo() {} //~ ERROR: a #[start] function is an experimental feature
+fn foo(_: isize, _: *const *const u8) -> isize { 0 }
+//~^ ERROR a #[start] function is an experimental feature
diff --git a/src/test/ui/feature-gates/feature-gate-start.stderr b/src/test/ui/feature-gates/feature-gate-start.stderr
index 255703d..d39e5f3 100644
--- a/src/test/ui/feature-gates/feature-gate-start.stderr
+++ b/src/test/ui/feature-gates/feature-gate-start.stderr
@@ -1,8 +1,8 @@
 error[E0658]: a #[start] function is an experimental feature whose signature may change over time (see issue #29633)
   --> $DIR/feature-gate-start.rs:2:1
    |
-LL | fn foo() {} //~ ERROR: a #[start] function is an experimental feature
-   | ^^^^^^^^^^^
+LL | fn foo(_: isize, _: *const *const u8) -> isize { 0 }
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(start)] to the crate attributes to enable
 
diff --git a/src/test/ui/feature-gates/feature-gate-thread_local.rs b/src/test/ui/feature-gates/feature-gate-thread_local.rs
index c47bdc1..0efae1f 100644
--- a/src/test/ui/feature-gates/feature-gate-thread_local.rs
+++ b/src/test/ui/feature-gates/feature-gate-thread_local.rs
@@ -8,8 +8,4 @@
 #[thread_local] //~ ERROR `#[thread_local]` is an experimental feature
 static FOO: i32 = 3;
 
-pub fn main() {
-    FOO.with(|x| {
-        println!("x: {}", x);
-    });
-}
+pub fn main() {}
diff --git a/src/test/ui/feature-gates/feature-gate-trivial_bounds.stderr b/src/test/ui/feature-gates/feature-gate-trivial_bounds.stderr
index 34c4578..1f35efa 100644
--- a/src/test/ui/feature-gates/feature-gate-trivial_bounds.stderr
+++ b/src/test/ui/feature-gates/feature-gate-trivial_bounds.stderr
@@ -95,7 +95,7 @@
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: see issue #48214
    = help: add #![feature(trivial_bounds)] to the crate attributes to enable
 
@@ -108,7 +108,7 @@
    | |_^ doesn't have a size known at compile-time
    |
    = help: within `Dst<(dyn A + 'static)>`, the trait `std::marker::Sized` is not implemented for `(dyn A + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Dst<(dyn A + 'static)>`
    = help: see issue #48214
    = help: add #![feature(trivial_bounds)] to the crate attributes to enable
@@ -122,7 +122,7 @@
    | |_^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: see issue #48214
    = help: add #![feature(trivial_bounds)] to the crate attributes to enable
 
diff --git a/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.rs b/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.rs
index fc59027..ff6e2b8 100644
--- a/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.rs
+++ b/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.rs
@@ -3,25 +3,29 @@
 // never triggers (yet), because they encounter other problems around
 // angle bracket vs parentheses notation.
 
-#![allow(dead_code)]
+#![feature(fn_traits)]
 
 struct Foo;
 impl Fn<()> for Foo {
+//~^ ERROR the precise format of `Fn`-family traits' type parameters is subject to change
     extern "rust-call" fn call(self, args: ()) -> () {}
     //~^ ERROR rust-call ABI is subject to change
 }
 struct Foo1;
 impl FnOnce() for Foo1 {
+//~^ ERROR associated type bindings are not allowed here
     extern "rust-call" fn call_once(self, args: ()) -> () {}
     //~^ ERROR rust-call ABI is subject to change
 }
 struct Bar;
 impl FnMut<()> for Bar {
+//~^ ERROR the precise format of `Fn`-family traits' type parameters is subject to change
     extern "rust-call" fn call_mut(&self, args: ()) -> () {}
     //~^ ERROR rust-call ABI is subject to change
 }
 struct Baz;
 impl FnOnce<()> for Baz {
+//~^ ERROR the precise format of `Fn`-family traits' type parameters is subject to change
     extern "rust-call" fn call_once(&self, args: ()) -> () {}
     //~^ ERROR rust-call ABI is subject to change
 }
diff --git a/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr b/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
index 0e40e1f..865b87e 100644
--- a/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
+++ b/src/test/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
@@ -1,5 +1,5 @@
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:10:5
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:11:5
    |
 LL |     extern "rust-call" fn call(self, args: ()) -> () {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -7,7 +7,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:15:5
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:17:5
    |
 LL |     extern "rust-call" fn call_once(self, args: ()) -> () {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -15,7 +15,7 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:20:5
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:23:5
    |
 LL |     extern "rust-call" fn call_mut(&self, args: ()) -> () {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -23,13 +23,44 @@
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:25:5
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:29:5
    |
 LL |     extern "rust-call" fn call_once(&self, args: ()) -> () {}
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
-error: aborting due to 4 previous errors
+error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change. Use parenthetical notation (Fn(Foo, Bar) -> Baz) instead (see issue #29625)
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:9:6
+   |
+LL | impl Fn<()> for Foo {
+   |      ^^^^^^
+   |
+   = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
-For more information about this error, try `rustc --explain E0658`.
+error[E0229]: associated type bindings are not allowed here
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:15:12
+   |
+LL | impl FnOnce() for Foo1 {
+   |            ^^ associated type not allowed here
+
+error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change. Use parenthetical notation (Fn(Foo, Bar) -> Baz) instead (see issue #29625)
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:21:6
+   |
+LL | impl FnMut<()> for Bar {
+   |      ^^^^^^^^^
+   |
+   = help: add #![feature(unboxed_closures)] to the crate attributes to enable
+
+error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change. Use parenthetical notation (Fn(Foo, Bar) -> Baz) instead (see issue #29625)
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:27:6
+   |
+LL | impl FnOnce<()> for Baz {
+   |      ^^^^^^^^^^
+   |
+   = help: add #![feature(unboxed_closures)] to the crate attributes to enable
+
+error: aborting due to 8 previous errors
+
+Some errors occurred: E0229, E0658.
+For more information about an error, try `rustc --explain E0229`.
diff --git a/src/test/ui/feature-gates/feature-gate-unboxed-closures.rs b/src/test/ui/feature-gates/feature-gate-unboxed-closures.rs
index 4c0d7d1..c3f5c99 100644
--- a/src/test/ui/feature-gates/feature-gate-unboxed-closures.rs
+++ b/src/test/ui/feature-gates/feature-gate-unboxed-closures.rs
@@ -1,6 +1,9 @@
+#![feature(fn_traits)]
+
 struct Test;
 
 impl FnOnce<(u32, u32)> for Test {
+//~^ ERROR the precise format of `Fn`-family traits' type parameters is subject to change
     type Output = u32;
 
     extern "rust-call" fn call_once(self, (a, b): (u32, u32)) -> u32 {
diff --git a/src/test/ui/feature-gates/feature-gate-unboxed-closures.stderr b/src/test/ui/feature-gates/feature-gate-unboxed-closures.stderr
index 420b331..e7b1fc5 100644
--- a/src/test/ui/feature-gates/feature-gate-unboxed-closures.stderr
+++ b/src/test/ui/feature-gates/feature-gate-unboxed-closures.stderr
@@ -1,5 +1,5 @@
 error[E0658]: rust-call ABI is subject to change (see issue #29625)
-  --> $DIR/feature-gate-unboxed-closures.rs:6:5
+  --> $DIR/feature-gate-unboxed-closures.rs:9:5
    |
 LL | /     extern "rust-call" fn call_once(self, (a, b): (u32, u32)) -> u32 {
 LL | |         a + b
@@ -8,6 +8,14 @@
    |
    = help: add #![feature(unboxed_closures)] to the crate attributes to enable
 
-error: aborting due to previous error
+error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change. Use parenthetical notation (Fn(Foo, Bar) -> Baz) instead (see issue #29625)
+  --> $DIR/feature-gate-unboxed-closures.rs:5:6
+   |
+LL | impl FnOnce<(u32, u32)> for Test {
+   |      ^^^^^^^^^^^^^^^^^^
+   |
+   = help: add #![feature(unboxed_closures)] to the crate attributes to enable
+
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0658`.
diff --git a/src/test/ui/feature-gates/feature-gate-unsized_locals.stderr b/src/test/ui/feature-gates/feature-gate-unsized_locals.stderr
index 77313ed..bde39cb 100644
--- a/src/test/ui/feature-gates/feature-gate-unsized_locals.stderr
+++ b/src/test/ui/feature-gates/feature-gate-unsized_locals.stderr
@@ -5,7 +5,7 @@
    |      ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::ops::FnOnce() + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/generator/sized-yield.stderr b/src/test/ui/generator/sized-yield.stderr
index 7e1cd95..4f59f2c 100644
--- a/src/test/ui/generator/sized-yield.stderr
+++ b/src/test/ui/generator/sized-yield.stderr
@@ -9,7 +9,7 @@
    | |____^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the yield type of a generator must have a statically known size
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
@@ -19,7 +19,7 @@
    |                 ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error: aborting due to 2 previous errors
 
diff --git a/src/test/ui/implicit-method-bind.stderr b/src/test/ui/implicit-method-bind.stderr
index 6f0ed4c..7c70709 100644
--- a/src/test/ui/implicit-method-bind.stderr
+++ b/src/test/ui/implicit-method-bind.stderr
@@ -2,9 +2,7 @@
   --> $DIR/implicit-method-bind.rs:2:20
    |
 LL |     let _f = 10i32.abs; //~ ERROR attempted to take value of method
-   |                    ^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |                    ^^^ help: use parentheses to call the method: `abs()`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/issues/issue-13853-2.stderr b/src/test/ui/issues/issue-13853-2.stderr
index 522042d..3e71124 100644
--- a/src/test/ui/issues/issue-13853-2.stderr
+++ b/src/test/ui/issues/issue-13853-2.stderr
@@ -2,9 +2,7 @@
   --> $DIR/issue-13853-2.rs:5:39
    |
 LL | fn foo(res : Box<ResponseHook>) { res.get } //~ ERROR attempted to take value of method
-   |                                       ^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |                                       ^^^ help: use parentheses to call the method: `get()`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/issues/issue-14366.stderr b/src/test/ui/issues/issue-14366.stderr
index b93f5c2..a3588bb 100644
--- a/src/test/ui/issues/issue-14366.stderr
+++ b/src/test/ui/issues/issue-14366.stderr
@@ -5,7 +5,7 @@
    |              ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required for the cast to the object type `dyn std::any::Any`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-15756.stderr b/src/test/ui/issues/issue-15756.stderr
index 9133376..987bc51 100644
--- a/src/test/ui/issues/issue-15756.stderr
+++ b/src/test/ui/issues/issue-15756.stderr
@@ -5,7 +5,7 @@
    |          ^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[T]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/issues/issue-17651.stderr b/src/test/ui/issues/issue-17651.stderr
index e2d0d33..72c40ff 100644
--- a/src/test/ui/issues/issue-17651.stderr
+++ b/src/test/ui/issues/issue-17651.stderr
@@ -5,7 +5,7 @@
    |         ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[{integer}]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `<std::boxed::Box<T>>::new`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-18107.stderr b/src/test/ui/issues/issue-18107.stderr
index 4bad37d..23b58c3 100644
--- a/src/test/ui/issues/issue-18107.stderr
+++ b/src/test/ui/issues/issue-18107.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn AbstractRenderer + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the return type of a function must have a statically known size
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-18919.stderr b/src/test/ui/issues/issue-18919.stderr
index cbad31a..ca717a3 100644
--- a/src/test/ui/issues/issue-18919.stderr
+++ b/src/test/ui/issues/issue-18919.stderr
@@ -7,7 +7,7 @@
    | |_^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn for<'r> std::ops::Fn(&'r isize) -> isize`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::option::Option`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-20005.stderr b/src/test/ui/issues/issue-20005.stderr
index c69dfa9..672d78f 100644
--- a/src/test/ui/issues/issue-20005.stderr
+++ b/src/test/ui/issues/issue-20005.stderr
@@ -9,7 +9,7 @@
    | |_____^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Self`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Self: std::marker::Sized` bound
 note: required by `From`
   --> $DIR/issue-20005.rs:1:1
diff --git a/src/test/ui/issues/issue-20433.stderr b/src/test/ui/issues/issue-20433.stderr
index cc98a77..f7cb28e 100644
--- a/src/test/ui/issues/issue-20433.stderr
+++ b/src/test/ui/issues/issue-20433.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[i32]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::vec::Vec`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-20605.stderr b/src/test/ui/issues/issue-20605.stderr
index 472080d..f779fe5 100644
--- a/src/test/ui/issues/issue-20605.stderr
+++ b/src/test/ui/issues/issue-20605.stderr
@@ -5,7 +5,7 @@
    |                 ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `dyn std::iter::Iterator<Item=&mut u8>`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::iter::IntoIterator::into_iter`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-22874.stderr b/src/test/ui/issues/issue-22874.stderr
index 26addd1..229f99f 100644
--- a/src/test/ui/issues/issue-22874.stderr
+++ b/src/test/ui/issues/issue-22874.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[std::string::String]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: slice and array elements must have `Sized` type
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-23281.stderr b/src/test/ui/issues/issue-23281.stderr
index adc92ff..1e57774a 100644
--- a/src/test/ui/issues/issue-23281.stderr
+++ b/src/test/ui/issues/issue-23281.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::ops::Fn() + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::vec::Vec`
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-24446.stderr b/src/test/ui/issues/issue-24446.stderr
index 230ea4d..ffec73b 100644
--- a/src/test/ui/issues/issue-24446.stderr
+++ b/src/test/ui/issues/issue-24446.stderr
@@ -5,7 +5,7 @@
    |                 ^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::ops::Fn() -> u32 + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/issues/issue-26472.rs b/src/test/ui/issues/issue-26472.rs
index 4659c0d..4eb38d1 100644
--- a/src/test/ui/issues/issue-26472.rs
+++ b/src/test/ui/issues/issue-26472.rs
@@ -8,6 +8,6 @@
 
 fn main() {
     let s = sub::S::new();
-    let v = s.len;
-    //~^ ERROR field `len` of struct `sub::S` is private
+    let v = s.len; //~ ERROR field `len` of struct `sub::S` is private
+    s.len = v; //~ ERROR field `len` of struct `sub::S` is private
 }
diff --git a/src/test/ui/issues/issue-26472.stderr b/src/test/ui/issues/issue-26472.stderr
index dd7941e..8c261d2 100644
--- a/src/test/ui/issues/issue-26472.stderr
+++ b/src/test/ui/issues/issue-26472.stderr
@@ -1,11 +1,17 @@
 error[E0616]: field `len` of struct `sub::S` is private
   --> $DIR/issue-26472.rs:11:13
    |
-LL |     let v = s.len;
-   |             ^^^^^
-   |
-   = note: a method `len` also exists, perhaps you wish to call it
+LL |     let v = s.len; //~ ERROR field `len` of struct `sub::S` is private
+   |             ^^---
+   |               |
+   |               help: a method `len` also exists, call it with parentheses: `len()`
 
-error: aborting due to previous error
+error[E0616]: field `len` of struct `sub::S` is private
+  --> $DIR/issue-26472.rs:12:5
+   |
+LL |     s.len = v; //~ ERROR field `len` of struct `sub::S` is private
+   |     ^^^^^
+
+error: aborting due to 2 previous errors
 
 For more information about this error, try `rustc --explain E0616`.
diff --git a/src/test/ui/issues/issue-27060-2.stderr b/src/test/ui/issues/issue-27060-2.stderr
index 6141ada..b95c298 100644
--- a/src/test/ui/issues/issue-27060-2.stderr
+++ b/src/test/ui/issues/issue-27060-2.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: the last field of a packed struct may only have a dynamically sized type if it does not need drop to be run
 
diff --git a/src/test/ui/issues/issue-27078.stderr b/src/test/ui/issues/issue-27078.stderr
index 278c57d..76cc3e7 100644
--- a/src/test/ui/issues/issue-27078.stderr
+++ b/src/test/ui/issues/issue-27078.stderr
@@ -5,7 +5,7 @@
    |            ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Self`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Self: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
diff --git a/src/test/ui/issues/issue-30355.stderr b/src/test/ui/issues/issue-30355.stderr
index 5d15419..48b151c 100644
--- a/src/test/ui/issues/issue-30355.stderr
+++ b/src/test/ui/issues/issue-30355.stderr
@@ -5,7 +5,7 @@
    |      ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/issues/issue-32323.stderr b/src/test/ui/issues/issue-32323.stderr
index 00ef2ca..0339fdc 100644
--- a/src/test/ui/issues/issue-32323.stderr
+++ b/src/test/ui/issues/issue-32323.stderr
@@ -1,8 +1,10 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-32323.rs:5:49
+  --> $DIR/issue-32323.rs:5:30
    |
 LL | pub fn f<'a, T: Tr<'a>>() -> <T as Tr<'a>>::Out {}
-   |                                                 ^^ expected associated type, found ()
+   |        -                     ^^^^^^^^^^^^^^^^^^ expected associated type, found ()
+   |        |
+   |        this function's body doesn't return
    |
    = note: expected type `<T as Tr<'a>>::Out`
               found type `()`
diff --git a/src/test/ui/issues/issue-35988.stderr b/src/test/ui/issues/issue-35988.stderr
index a570bd2..825c0de 100644
--- a/src/test/ui/issues/issue-35988.stderr
+++ b/src/test/ui/issues/issue-35988.stderr
@@ -5,7 +5,7 @@
    |       ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[std::boxed::Box<E>]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error: aborting due to previous error
diff --git a/src/test/ui/issues/issue-38954.stderr b/src/test/ui/issues/issue-38954.stderr
index 06093ec..a74d635 100644
--- a/src/test/ui/issues/issue-38954.stderr
+++ b/src/test/ui/issues/issue-38954.stderr
@@ -5,7 +5,7 @@
    |                       ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/issues/issue-41229-ref-str.stderr b/src/test/ui/issues/issue-41229-ref-str.stderr
index c4fe54e..bcca911 100644
--- a/src/test/ui/issues/issue-41229-ref-str.stderr
+++ b/src/test/ui/issues/issue-41229-ref-str.stderr
@@ -5,7 +5,7 @@
    |                            ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/issues/issue-42312.stderr b/src/test/ui/issues/issue-42312.stderr
index 12a4366..20c8d08 100644
--- a/src/test/ui/issues/issue-42312.stderr
+++ b/src/test/ui/issues/issue-42312.stderr
@@ -5,7 +5,7 @@
    |                             ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `<Self as std::ops::Deref>::Target`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where <Self as std::ops::Deref>::Target: std::marker::Sized` bound
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -17,7 +17,7 @@
    |                       ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::string::ToString + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/issues/issue-43162.stderr b/src/test/ui/issues/issue-43162.stderr
index 8b02476..3fc5317 100644
--- a/src/test/ui/issues/issue-43162.stderr
+++ b/src/test/ui/issues/issue-43162.stderr
@@ -11,15 +11,15 @@
    |     ^^^^^^^^ cannot break outside of a loop
 
 error[E0308]: mismatched types
-  --> $DIR/issue-43162.rs:1:18
+  --> $DIR/issue-43162.rs:1:13
    |
-LL |   fn foo() -> bool {
-   |  __________________^
-LL | |     //~^ ERROR E0308
-LL | |     break true; //~ ERROR E0268
-   | |               - help: consider removing this semicolon
-LL | | }
-   | |_^ expected bool, found ()
+LL | fn foo() -> bool {
+   |    ---      ^^^^ expected bool, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     //~^ ERROR E0308
+LL |     break true; //~ ERROR E0268
+   |               - help: consider removing this semicolon
    |
    = note: expected type `bool`
               found type `()`
diff --git a/src/test/ui/issues/issue-44023.stderr b/src/test/ui/issues/issue-44023.stderr
index 21cfe07..f1962a8 100644
--- a/src/test/ui/issues/issue-44023.stderr
+++ b/src/test/ui/issues/issue-44023.stderr
@@ -1,10 +1,10 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-44023.rs:5:42
+  --> $DIR/issue-44023.rs:5:36
    |
-LL |   fn საჭმელად_გემრიელი_სადილი ( ) -> isize { //~ ERROR mismatched types
-   |  __________________________________________^
-LL | | }
-   | |_^ expected isize, found ()
+LL | fn საჭმელად_გემრიელი_სადილი ( ) -> isize { //~ ERROR mismatched types
+   |    ------------------------        ^^^^^ expected isize, found ()
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `isize`
               found type `()`
diff --git a/src/test/ui/issues/issue-51279.rs b/src/test/ui/issues/issue-51279.rs
index ad5438f..f8f3626 100644
--- a/src/test/ui/issues/issue-51279.rs
+++ b/src/test/ui/issues/issue-51279.rs
@@ -15,7 +15,7 @@
 
 struct M<T>(*const T);
 
-unsafe impl<#[cfg_attr(none, may_dangle)] T> Drop for M<T> {
+impl<#[cfg_attr(none, may_dangle)] T> Drop for M<T> {
     //~^ ERROR #[cfg_attr] cannot be applied on a generic parameter
     fn drop(&mut self) {}
 }
@@ -23,3 +23,5 @@
 type Z<#[ignored] 'a, #[cfg(none)] T> = X<'a, T>;
 //~^ ERROR #[cfg] cannot be applied on a generic parameter
 //~| ERROR attribute `ignored` is currently unknown to the compiler
+
+fn main() {}
diff --git a/src/test/ui/issues/issue-51279.stderr b/src/test/ui/issues/issue-51279.stderr
index 1706e98..bc33eac 100644
--- a/src/test/ui/issues/issue-51279.stderr
+++ b/src/test/ui/issues/issue-51279.stderr
@@ -35,10 +35,10 @@
    |                           ^^^^^^^^^^^^
 
 error: #[cfg_attr] cannot be applied on a generic parameter
-  --> $DIR/issue-51279.rs:18:13
+  --> $DIR/issue-51279.rs:18:6
    |
-LL | unsafe impl<#[cfg_attr(none, may_dangle)] T> Drop for M<T> {
-   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+LL | impl<#[cfg_attr(none, may_dangle)] T> Drop for M<T> {
+   |      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: #[cfg] cannot be applied on a generic parameter
   --> $DIR/issue-51279.rs:23:23
diff --git a/src/test/ui/issues/issue-54410.stderr b/src/test/ui/issues/issue-54410.stderr
index ae6888f..992c691 100644
--- a/src/test/ui/issues/issue-54410.stderr
+++ b/src/test/ui/issues/issue-54410.stderr
@@ -5,7 +5,7 @@
    |                            ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[i8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/issues/issue-56806.rs b/src/test/ui/issues/issue-56806.rs
new file mode 100644
index 0000000..b6454e5
--- /dev/null
+++ b/src/test/ui/issues/issue-56806.rs
@@ -0,0 +1,7 @@
+pub trait Trait {
+    fn dyn_instead_of_self(self: Box<dyn Trait>);
+    //~^ ERROR invalid method receiver type: std::boxed::Box<(dyn Trait + 'static)>
+}
+
+pub fn main() {
+}
diff --git a/src/test/ui/issues/issue-56806.stderr b/src/test/ui/issues/issue-56806.stderr
new file mode 100644
index 0000000..2dd3add
--- /dev/null
+++ b/src/test/ui/issues/issue-56806.stderr
@@ -0,0 +1,12 @@
+error[E0307]: invalid method receiver type: std::boxed::Box<(dyn Trait + 'static)>
+  --> $DIR/issue-56806.rs:2:34
+   |
+LL |     fn dyn_instead_of_self(self: Box<dyn Trait>);
+   |                                  ^^^^^^^^^^^^^^
+   |
+   = note: type must be `Self` or a type that dereferences to it
+   = help: consider changing to `self`, `&self`, `&mut self`, or `self: Box<Self>`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0307`.
diff --git a/src/test/ui/issues/issue-5883.stderr b/src/test/ui/issues/issue-5883.stderr
index 398d42c..ad463d4 100644
--- a/src/test/ui/issues/issue-5883.stderr
+++ b/src/test/ui/issues/issue-5883.stderr
@@ -5,7 +5,7 @@
    |               ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn A + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
@@ -16,7 +16,7 @@
    |        ^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Struct`, the trait `std::marker::Sized` is not implemented for `(dyn A + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Struct`
    = note: the return type of a function must have a statically known size
 
diff --git a/src/test/ui/issues/issue-6458-4.stderr b/src/test/ui/issues/issue-6458-4.stderr
index 3e621c1..c087292 100644
--- a/src/test/ui/issues/issue-6458-4.stderr
+++ b/src/test/ui/issues/issue-6458-4.stderr
@@ -1,12 +1,12 @@
 error[E0308]: mismatched types
-  --> $DIR/issue-6458-4.rs:1:40
+  --> $DIR/issue-6458-4.rs:1:20
    |
-LL |   fn foo(b: bool) -> Result<bool,String> { //~ ERROR mismatched types
-   |  ________________________________________^
-LL | |     Err("bar".to_string());
-   | |                           - help: consider removing this semicolon
-LL | | }
-   | |_^ expected enum `std::result::Result`, found ()
+LL | fn foo(b: bool) -> Result<bool,String> { //~ ERROR mismatched types
+   |    ---             ^^^^^^^^^^^^^^^^^^^ expected enum `std::result::Result`, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     Err("bar".to_string());
+   |                           - help: consider removing this semicolon
    |
    = note: expected type `std::result::Result<bool, std::string::String>`
               found type `()`
diff --git a/src/test/ui/liveness/liveness-forgot-ret.stderr b/src/test/ui/liveness/liveness-forgot-ret.stderr
index b891122..bbcbbdb 100644
--- a/src/test/ui/liveness/liveness-forgot-ret.stderr
+++ b/src/test/ui/liveness/liveness-forgot-ret.stderr
@@ -1,8 +1,10 @@
 error[E0308]: mismatched types
-  --> $DIR/liveness-forgot-ret.rs:3:25
+  --> $DIR/liveness-forgot-ret.rs:3:19
    |
 LL | fn f(a: isize) -> isize { if god_exists(a) { return 5; }; }
-   |                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected isize, found ()
+   |    -              ^^^^^ expected isize, found ()    - expected because of this statement
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `isize`
               found type `()`
diff --git a/src/test/ui/liveness/liveness-missing-ret2.stderr b/src/test/ui/liveness/liveness-missing-ret2.stderr
index e5f7478..58d0249 100644
--- a/src/test/ui/liveness/liveness-missing-ret2.stderr
+++ b/src/test/ui/liveness/liveness-missing-ret2.stderr
@@ -1,13 +1,10 @@
 error[E0308]: mismatched types
-  --> $DIR/liveness-missing-ret2.rs:1:17
+  --> $DIR/liveness-missing-ret2.rs:1:11
    |
-LL |   fn f() -> isize { //~ ERROR mismatched types
-   |  _________________^
-LL | |     // Make sure typestate doesn't interpret this match expression as
-LL | |     // the function result
-LL | |    match true { true => { } _ => {} };
-LL | | }
-   | |_^ expected isize, found ()
+LL | fn f() -> isize { //~ ERROR mismatched types
+   |    -      ^^^^^ expected isize, found ()
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `isize`
               found type `()`
diff --git a/src/test/ui/liveness/liveness-return-last-stmt-semi.stderr b/src/test/ui/liveness/liveness-return-last-stmt-semi.stderr
index 3aa81a4..c6d166d 100644
--- a/src/test/ui/liveness/liveness-return-last-stmt-semi.stderr
+++ b/src/test/ui/liveness/liveness-return-last-stmt-semi.stderr
@@ -1,11 +1,11 @@
 error[E0308]: mismatched types
-  --> $DIR/liveness-return-last-stmt-semi.rs:4:45
+  --> $DIR/liveness-return-last-stmt-semi.rs:4:41
    |
 LL | macro_rules! test { () => { fn foo() -> i32 { 1; } } }
-   |                                             ^^^-^^
-   |                                             |  |
-   |                                             |  help: consider removing this semicolon
-   |                                             expected i32, found ()
+   |                                ---      ^^^    - help: consider removing this semicolon
+   |                                |        |
+   |                                |        expected i32, found ()
+   |                                this function's body doesn't return
 ...
 LL |     test!();
    |     -------- in this macro invocation
@@ -14,35 +14,36 @@
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/liveness-return-last-stmt-semi.rs:7:23
+  --> $DIR/liveness-return-last-stmt-semi.rs:7:19
    |
 LL | fn no_return() -> i32 {} //~ ERROR mismatched types
-   |                       ^^ expected i32, found ()
+   |    ---------      ^^^ expected i32, found ()
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `i32`
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/liveness-return-last-stmt-semi.rs:9:23
+  --> $DIR/liveness-return-last-stmt-semi.rs:9:19
    |
-LL |   fn bar(x: u32) -> u32 { //~ ERROR mismatched types
-   |  _______________________^
-LL | |     x * 2;
-   | |          - help: consider removing this semicolon
-LL | | }
-   | |_^ expected u32, found ()
+LL | fn bar(x: u32) -> u32 { //~ ERROR mismatched types
+   |    ---            ^^^ expected u32, found ()
+   |    |
+   |    this function's body doesn't return
+LL |     x * 2;
+   |          - help: consider removing this semicolon
    |
    = note: expected type `u32`
               found type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/liveness-return-last-stmt-semi.rs:13:23
+  --> $DIR/liveness-return-last-stmt-semi.rs:13:19
    |
-LL |   fn baz(x: u64) -> u32 { //~ ERROR mismatched types
-   |  _______________________^
-LL | |     x * 2;
-LL | | }
-   | |_^ expected u32, found ()
+LL | fn baz(x: u64) -> u32 { //~ ERROR mismatched types
+   |    ---            ^^^ expected u32, found ()
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `u32`
               found type `()`
diff --git a/src/test/ui/methods/method-missing-call.stderr b/src/test/ui/methods/method-missing-call.stderr
index 22c907e..886d92a 100644
--- a/src/test/ui/methods/method-missing-call.stderr
+++ b/src/test/ui/methods/method-missing-call.stderr
@@ -2,17 +2,13 @@
   --> $DIR/method-missing-call.rs:22:26
    |
 LL |                         .get_x;//~ ERROR attempted to take value of method `get_x` on type `Point`
-   |                          ^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |                          ^^^^^ help: use parentheses to call the method: `get_x()`
 
 error[E0615]: attempted to take value of method `filter_map` on type `std::iter::Filter<std::iter::Map<std::slice::Iter<'_, {integer}>, [closure@$DIR/method-missing-call.rs:27:20: 27:25]>, [closure@$DIR/method-missing-call.rs:28:23: 28:35]>`
   --> $DIR/method-missing-call.rs:29:16
    |
 LL |               .filter_map; //~ ERROR attempted to take value of method `filter_map` on type
-   |                ^^^^^^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |                ^^^^^^^^^^ help: use parentheses to call the method: `filter_map(...)`
 
 error: aborting due to 2 previous errors
 
diff --git a/src/test/ui/mismatched_types/cast-rfc0401.stderr b/src/test/ui/mismatched_types/cast-rfc0401.stderr
index e220349..158d114 100644
--- a/src/test/ui/mismatched_types/cast-rfc0401.stderr
+++ b/src/test/ui/mismatched_types/cast-rfc0401.stderr
@@ -223,7 +223,7 @@
    |             ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required for the cast to the object type `dyn Foo`
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
@@ -233,7 +233,7 @@
    |             ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required for the cast to the object type `dyn Foo`
 
 error[E0606]: casting `&{float}` as `f32` is invalid
diff --git a/src/test/ui/missing/missing-return.stderr b/src/test/ui/missing/missing-return.stderr
index 6d42daf..42466e2 100644
--- a/src/test/ui/missing/missing-return.stderr
+++ b/src/test/ui/missing/missing-return.stderr
@@ -1,8 +1,10 @@
 error[E0308]: mismatched types
-  --> $DIR/missing-return.rs:3:17
+  --> $DIR/missing-return.rs:3:11
    |
 LL | fn f() -> isize { }
-   |                 ^^^ expected isize, found ()
+   |    -      ^^^^^ expected isize, found ()
+   |    |
+   |    this function's body doesn't return
    |
    = note: expected type `isize`
               found type `()`
diff --git a/src/test/ui/mod/mod_file_disambig.rs b/src/test/ui/mod/mod_file_disambig.rs
index b7365cd..ef203ef 100644
--- a/src/test/ui/mod/mod_file_disambig.rs
+++ b/src/test/ui/mod/mod_file_disambig.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 mod mod_file_disambig_aux; //~ ERROR file for module `mod_file_disambig_aux` found at both
 
 fn main() {
diff --git a/src/test/ui/mod/mod_file_disambig.stderr b/src/test/ui/mod/mod_file_disambig.stderr
index 3e09473..1720ca4 100644
--- a/src/test/ui/mod/mod_file_disambig.stderr
+++ b/src/test/ui/mod/mod_file_disambig.stderr
@@ -1,5 +1,5 @@
 error[E0584]: file for module `mod_file_disambig_aux` found at both mod_file_disambig_aux.rs and mod_file_disambig_aux/mod.rs
-  --> $DIR/mod_file_disambig.rs:3:5
+  --> $DIR/mod_file_disambig.rs:1:5
    |
 LL | mod mod_file_disambig_aux; //~ ERROR file for module `mod_file_disambig_aux` found at both
    |     ^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/mut/mut-ref.rs b/src/test/ui/mut/mut-ref.rs
index 064990e..80990b2 100644
--- a/src/test/ui/mut/mut-ref.rs
+++ b/src/test/ui/mut/mut-ref.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let mut ref x = 10; //~ ERROR the order of `mut` and `ref` is incorrect
     let ref mut y = 11;
diff --git a/src/test/ui/mut/mut-ref.stderr b/src/test/ui/mut/mut-ref.stderr
index a91483a..339da7f 100644
--- a/src/test/ui/mut/mut-ref.stderr
+++ b/src/test/ui/mut/mut-ref.stderr
@@ -1,5 +1,5 @@
 error: the order of `mut` and `ref` is incorrect
-  --> $DIR/mut-ref.rs:4:9
+  --> $DIR/mut-ref.rs:2:9
    |
 LL |     let mut ref x = 10; //~ ERROR the order of `mut` and `ref` is incorrect
    |         ^^^^^^^ help: try switching the order: `ref mut`
diff --git a/src/test/ui/nll/issue-52534.stderr b/src/test/ui/nll/issue-52534.stderr
index 42387c7..e83374a 100644
--- a/src/test/ui/nll/issue-52534.stderr
+++ b/src/test/ui/nll/issue-52534.stderr
@@ -10,7 +10,7 @@
    | - ...but `x` will be dropped here, when the function `bar` returns
    |
    = note: functions cannot return a borrow to data owned within the function's scope, functions can only return borrows to data passed as arguments
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch04-02-references-and-borrowing.html#dangling-references>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch04-02-references-and-borrowing.html#dangling-references>
 
 error[E0597]: `y` does not live long enough
   --> $DIR/issue-52534.rs:18:26
@@ -24,7 +24,7 @@
    | - ...but `y` will be dropped here, when the function `foobar` returns
    |
    = note: functions cannot return a borrow to data owned within the function's scope, functions can only return borrows to data passed as arguments
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch04-02-references-and-borrowing.html#dangling-references>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch04-02-references-and-borrowing.html#dangling-references>
 
 error: aborting due to 2 previous errors
 
diff --git a/src/test/ui/nll/issue-57280-1.rs b/src/test/ui/nll/issue-57280-1.rs
new file mode 100644
index 0000000..356c477
--- /dev/null
+++ b/src/test/ui/nll/issue-57280-1.rs
@@ -0,0 +1,21 @@
+#![feature(nll)]
+
+// compile-pass
+
+trait Foo<'a> {
+    const C: &'a u32;
+}
+
+impl<'a, T> Foo<'a> for T {
+    const C: &'a u32 = &22;
+}
+
+fn foo() {
+    let a = 22;
+    match &a {
+        <() as Foo<'static>>::C => { }
+        &_ => { }
+    }
+}
+
+fn main() {}
diff --git a/src/test/ui/nll/issue-57280.rs b/src/test/ui/nll/issue-57280.rs
new file mode 100644
index 0000000..4fe6a96
--- /dev/null
+++ b/src/test/ui/nll/issue-57280.rs
@@ -0,0 +1,22 @@
+#![feature(nll)]
+
+// compile-pass
+
+trait Foo {
+    const BLAH: &'static str;
+}
+
+struct Placeholder;
+
+impl Foo for Placeholder {
+    const BLAH: &'static str = "hi";
+}
+
+fn foo(x: &str) {
+    match x {
+        <Placeholder as Foo>::BLAH => { }
+        _ => { }
+    }
+}
+
+fn main() {}
diff --git a/src/test/ui/on-unimplemented/expected-comma-found-token.rs b/src/test/ui/on-unimplemented/expected-comma-found-token.rs
index a3e6609..a4e2a17 100644
--- a/src/test/ui/on-unimplemented/expected-comma-found-token.rs
+++ b/src/test/ui/on-unimplemented/expected-comma-found-token.rs
@@ -4,11 +4,10 @@
 
 #![feature(on_unimplemented)]
 
-#[rustc_on_unimplemented(
+#[rustc_on_unimplemented( //~ ERROR `#[rustc_on_unimplemented]` requires a value
     message="the message"
-    label="the label"
+    label="the label" //~ ERROR expected one of `)` or `,`, found `label`
 )]
 trait T {}
-//~^^^ ERROR expected one of `)` or `,`, found `label`
 
 fn main() {  }
diff --git a/src/test/ui/on-unimplemented/expected-comma-found-token.stderr b/src/test/ui/on-unimplemented/expected-comma-found-token.stderr
index 5bbdbe2..aa1b520 100644
--- a/src/test/ui/on-unimplemented/expected-comma-found-token.stderr
+++ b/src/test/ui/on-unimplemented/expected-comma-found-token.stderr
@@ -3,8 +3,20 @@
    |
 LL |     message="the message"
    |                          - expected one of `)` or `,` here
-LL |     label="the label"
+LL |     label="the label" //~ ERROR expected one of `)` or `,`, found `label`
    |     ^^^^^ unexpected token
 
-error: aborting due to previous error
+error[E0232]: `#[rustc_on_unimplemented]` requires a value
+  --> $DIR/expected-comma-found-token.rs:7:1
+   |
+LL | / #[rustc_on_unimplemented( //~ ERROR `#[rustc_on_unimplemented]` requires a value
+LL | |     message="the message"
+LL | |     label="the label" //~ ERROR expected one of `)` or `,`, found `label`
+LL | | )]
+   | |__^ value required here
+   |
+   = note: eg `#[rustc_on_unimplemented(message="foo")]`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0232`.
diff --git a/src/test/ui/parser/ascii-only-character-escape.rs b/src/test/ui/parser/ascii-only-character-escape.rs
index a644f62..f1b028e 100644
--- a/src/test/ui/parser/ascii-only-character-escape.rs
+++ b/src/test/ui/parser/ascii-only-character-escape.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     let x = "\x80"; //~ ERROR may only be used
diff --git a/src/test/ui/parser/assoc-oddities-1.rs b/src/test/ui/parser/assoc-oddities-1.rs
index 7dc3e72..5914805 100644
--- a/src/test/ui/parser/assoc-oddities-1.rs
+++ b/src/test/ui/parser/assoc-oddities-1.rs
@@ -1,6 +1,6 @@
 // compile-flags: -Z parse-only
 
-fn that_odd_parse() {
+fn main() {
     // following lines below parse and must not fail
     x = if c { a } else { b }();
     x = if true { 1 } else { 0 } as *mut _;
diff --git a/src/test/ui/parser/assoc-oddities-2.rs b/src/test/ui/parser/assoc-oddities-2.rs
index fe4641b..3d35aad 100644
--- a/src/test/ui/parser/assoc-oddities-2.rs
+++ b/src/test/ui/parser/assoc-oddities-2.rs
@@ -1,6 +1,6 @@
 // compile-flags: -Z parse-only
 
-fn that_odd_parse() {
+fn main() {
     // see assoc-oddities-1 for explanation
     x..if c { a } else { b }[n]; //~ ERROR expected one of
 }
diff --git a/src/test/ui/parser/associated-types-project-from-hrtb-explicit.rs b/src/test/ui/parser/associated-types-project-from-hrtb-explicit.rs
index aa225be..ed9c996 100644
--- a/src/test/ui/parser/associated-types-project-from-hrtb-explicit.rs
+++ b/src/test/ui/parser/associated-types-project-from-hrtb-explicit.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 // Test you can't use a higher-ranked trait bound inside of a qualified
 // path (just won't parse).
diff --git a/src/test/ui/parser/attr-bad-meta-2.rs b/src/test/ui/parser/attr-bad-meta-2.rs
index b7488d3..cefd336 100644
--- a/src/test/ui/parser/attr-bad-meta-2.rs
+++ b/src/test/ui/parser/attr-bad-meta-2.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 #[path =] //~ ERROR unexpected token: `]`
 mod m {}
diff --git a/src/test/ui/parser/attr-bad-meta-2.stderr b/src/test/ui/parser/attr-bad-meta-2.stderr
index 1c1c276..ddc7a4b 100644
--- a/src/test/ui/parser/attr-bad-meta-2.stderr
+++ b/src/test/ui/parser/attr-bad-meta-2.stderr
@@ -1,5 +1,5 @@
 error: unexpected token: `]`
-  --> $DIR/attr-bad-meta-2.rs:3:9
+  --> $DIR/attr-bad-meta-2.rs:1:9
    |
 LL | #[path =] //~ ERROR unexpected token: `]`
    |         ^ unexpected token after this
diff --git a/src/test/ui/parser/attr-bad-meta-3.rs b/src/test/ui/parser/attr-bad-meta-3.rs
index c72e9c3..b51e9f2 100644
--- a/src/test/ui/parser/attr-bad-meta-3.rs
+++ b/src/test/ui/parser/attr-bad-meta-3.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 #[path() token] //~ ERROR expected `]`, found `token`
 mod m {}
diff --git a/src/test/ui/parser/attr-bad-meta-3.stderr b/src/test/ui/parser/attr-bad-meta-3.stderr
index a31300c..863a2d2 100644
--- a/src/test/ui/parser/attr-bad-meta-3.stderr
+++ b/src/test/ui/parser/attr-bad-meta-3.stderr
@@ -1,5 +1,5 @@
 error: expected `]`, found `token`
-  --> $DIR/attr-bad-meta-3.rs:3:10
+  --> $DIR/attr-bad-meta-3.rs:1:10
    |
 LL | #[path() token] //~ ERROR expected `]`, found `token`
    |          ^^^^^ expected `]`
diff --git a/src/test/ui/parser/attr-bad-meta.rs b/src/test/ui/parser/attr-bad-meta.rs
index 28d5cea..7fe5427 100644
--- a/src/test/ui/parser/attr-bad-meta.rs
+++ b/src/test/ui/parser/attr-bad-meta.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 #![feature(unrestricted_attribute_tokens)]
 
 #[path*] //~ ERROR expected one of `(`, `::`, `=`, `[`, `]`, or `{`, found `*`
diff --git a/src/test/ui/parser/attr-bad-meta.stderr b/src/test/ui/parser/attr-bad-meta.stderr
index f29c14a..7351702 100644
--- a/src/test/ui/parser/attr-bad-meta.stderr
+++ b/src/test/ui/parser/attr-bad-meta.stderr
@@ -1,5 +1,5 @@
 error: expected one of `(`, `::`, `=`, `[`, `]`, or `{`, found `*`
-  --> $DIR/attr-bad-meta.rs:5:7
+  --> $DIR/attr-bad-meta.rs:3:7
    |
 LL | #[path*] //~ ERROR expected one of `(`, `::`, `=`, `[`, `]`, or `{`, found `*`
    |       ^ expected one of `(`, `::`, `=`, `[`, `]`, or `{` here
diff --git a/src/test/ui/parser/attr-before-eof.rs b/src/test/ui/parser/attr-before-eof.rs
index c090a77..6af1783 100644
--- a/src/test/ui/parser/attr-before-eof.rs
+++ b/src/test/ui/parser/attr-before-eof.rs
@@ -1,3 +1,3 @@
-// compile-flags: -Z parse-only
+fn main() {}
 
 #[derive(Debug)] //~ERROR expected item after attributes
diff --git a/src/test/ui/parser/attr-dangling-in-fn.rs b/src/test/ui/parser/attr-dangling-in-fn.rs
index 79bf4c0..c7c45ba 100644
--- a/src/test/ui/parser/attr-dangling-in-fn.rs
+++ b/src/test/ui/parser/attr-dangling-in-fn.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected statement
 
 fn f() {
diff --git a/src/test/ui/parser/attr-dangling-in-fn.stderr b/src/test/ui/parser/attr-dangling-in-fn.stderr
index 2fe6c70..71488d2 100644
--- a/src/test/ui/parser/attr-dangling-in-fn.stderr
+++ b/src/test/ui/parser/attr-dangling-in-fn.stderr
@@ -1,5 +1,5 @@
 error: expected statement after outer attribute
-  --> $DIR/attr-dangling-in-fn.rs:7:1
+  --> $DIR/attr-dangling-in-fn.rs:5:1
    |
 LL | }
    | ^
diff --git a/src/test/ui/parser/attr-dangling-in-mod.rs b/src/test/ui/parser/attr-dangling-in-mod.rs
index ffc6bbc..261ed39 100644
--- a/src/test/ui/parser/attr-dangling-in-mod.rs
+++ b/src/test/ui/parser/attr-dangling-in-mod.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected item
 
 fn main() {
diff --git a/src/test/ui/parser/attr-dangling-in-mod.stderr b/src/test/ui/parser/attr-dangling-in-mod.stderr
index 5f09b05..d896b61 100644
--- a/src/test/ui/parser/attr-dangling-in-mod.stderr
+++ b/src/test/ui/parser/attr-dangling-in-mod.stderr
@@ -1,5 +1,5 @@
 error: expected item after attributes
-  --> $DIR/attr-dangling-in-mod.rs:8:14
+  --> $DIR/attr-dangling-in-mod.rs:6:14
    |
 LL | #[foo = "bar"]
    |              ^
diff --git a/src/test/ui/parser/attr.rs b/src/test/ui/parser/attr.rs
index 9f4ee80..041f30c 100644
--- a/src/test/ui/parser/attr.rs
+++ b/src/test/ui/parser/attr.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 #![feature(lang_items)]
 
 fn main() {}
diff --git a/src/test/ui/parser/attr.stderr b/src/test/ui/parser/attr.stderr
index e66dd7f..44714dc 100644
--- a/src/test/ui/parser/attr.stderr
+++ b/src/test/ui/parser/attr.stderr
@@ -1,5 +1,5 @@
 error: an inner attribute is not permitted in this context
-  --> $DIR/attr.rs:7:3
+  --> $DIR/attr.rs:5:3
    |
 LL | #![lang(foo)] //~ ERROR an inner attribute is not permitted in this context
    |   ^
diff --git a/src/test/ui/parser/attrs-after-extern-mod.rs b/src/test/ui/parser/attrs-after-extern-mod.rs
index 2078320..4bdd164 100644
--- a/src/test/ui/parser/attrs-after-extern-mod.rs
+++ b/src/test/ui/parser/attrs-after-extern-mod.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Constants (static variables) can be used to match in patterns, but mutable
 // statics cannot. This ensures that there's some form of error if this is
 // attempted.
diff --git a/src/test/ui/parser/attrs-after-extern-mod.stderr b/src/test/ui/parser/attrs-after-extern-mod.stderr
index 7be8f72..067c419 100644
--- a/src/test/ui/parser/attrs-after-extern-mod.stderr
+++ b/src/test/ui/parser/attrs-after-extern-mod.stderr
@@ -1,5 +1,5 @@
 error: expected item after attributes
-  --> $DIR/attrs-after-extern-mod.rs:12:19
+  --> $DIR/attrs-after-extern-mod.rs:10:19
    |
 LL |     #[cfg(stage37)] //~ ERROR expected item after attributes
    |                   ^
diff --git a/src/test/ui/parser/bad-char-literals.rs b/src/test/ui/parser/bad-char-literals.rs
index 085f616..1c9b597 100644
--- a/src/test/ui/parser/bad-char-literals.rs
+++ b/src/test/ui/parser/bad-char-literals.rs
Binary files differ
diff --git a/src/test/ui/parser/bad-lit-suffixes.rs b/src/test/ui/parser/bad-lit-suffixes.rs
index 989d63e..391e7f0 100644
--- a/src/test/ui/parser/bad-lit-suffixes.rs
+++ b/src/test/ui/parser/bad-lit-suffixes.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 
 extern
diff --git a/src/test/ui/parser/bad-match.rs b/src/test/ui/parser/bad-match.rs
index 32c4bee..79bc7ee 100644
--- a/src/test/ui/parser/bad-match.rs
+++ b/src/test/ui/parser/bad-match.rs
@@ -1,11 +1,4 @@
-// compile-flags: -Z parse-only
-
-// error-pattern: expected
-
 fn main() {
-  let isize x = 5;
+  let isize x = 5; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `x`
   match x;
 }
-
-fn main() {
-}
diff --git a/src/test/ui/parser/bad-match.stderr b/src/test/ui/parser/bad-match.stderr
index 02f7dd6..dd3a2d2 100644
--- a/src/test/ui/parser/bad-match.stderr
+++ b/src/test/ui/parser/bad-match.stderr
@@ -1,7 +1,7 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `x`
-  --> $DIR/bad-match.rs:6:13
+  --> $DIR/bad-match.rs:2:13
    |
-LL |   let isize x = 5;
+LL |   let isize x = 5; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `x`
    |             ^ expected one of `:`, `;`, `=`, or `@` here
 
 error: aborting due to previous error
diff --git a/src/test/ui/parser/bad-name.rs b/src/test/ui/parser/bad-name.rs
index 3f3e753..9b42716 100644
--- a/src/test/ui/parser/bad-name.rs
+++ b/src/test/ui/parser/bad-name.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern: expected
 
 fn main() {
diff --git a/src/test/ui/parser/bad-name.stderr b/src/test/ui/parser/bad-name.stderr
index 847fdab..15e61cf 100644
--- a/src/test/ui/parser/bad-name.stderr
+++ b/src/test/ui/parser/bad-name.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `.`
-  --> $DIR/bad-name.rs:6:8
+  --> $DIR/bad-name.rs:4:8
    |
 LL |   let x.y::<isize>.z foo;
    |        ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/bad-pointer-type.rs b/src/test/ui/parser/bad-pointer-type.rs
index 7f44654..0e5a011 100644
--- a/src/test/ui/parser/bad-pointer-type.rs
+++ b/src/test/ui/parser/bad-pointer-type.rs
@@ -1,5 +1,5 @@
-// compile-flags: -Z parse-only
-
 fn foo(_: *()) {
     //~^ expected mut or const in raw pointer type (use `*mut T` or `*const T` as appropriate)
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/bad-pointer-type.stderr b/src/test/ui/parser/bad-pointer-type.stderr
index 43b0180..860f9f9 100644
--- a/src/test/ui/parser/bad-pointer-type.stderr
+++ b/src/test/ui/parser/bad-pointer-type.stderr
@@ -1,5 +1,5 @@
 error: expected mut or const in raw pointer type (use `*mut T` or `*const T` as appropriate)
-  --> $DIR/bad-pointer-type.rs:3:11
+  --> $DIR/bad-pointer-type.rs:1:11
    |
 LL | fn foo(_: *()) {
    |           ^
diff --git a/src/test/ui/parser/bad-value-ident-false.rs b/src/test/ui/parser/bad-value-ident-false.rs
index 3379ab8..4645ab4 100644
--- a/src/test/ui/parser/bad-value-ident-false.rs
+++ b/src/test/ui/parser/bad-value-ident-false.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 fn false() { } //~ ERROR expected identifier, found keyword `false`
 fn main() { }
diff --git a/src/test/ui/parser/bad-value-ident-false.stderr b/src/test/ui/parser/bad-value-ident-false.stderr
index 1a5c982..69a496f 100644
--- a/src/test/ui/parser/bad-value-ident-false.stderr
+++ b/src/test/ui/parser/bad-value-ident-false.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found keyword `false`
-  --> $DIR/bad-value-ident-false.rs:3:4
+  --> $DIR/bad-value-ident-false.rs:1:4
    |
 LL | fn false() { } //~ ERROR expected identifier, found keyword `false`
    |    ^^^^^ expected identifier, found keyword
diff --git a/src/test/ui/parser/bad-value-ident-true.rs b/src/test/ui/parser/bad-value-ident-true.rs
index 40815ab..0f64266 100644
--- a/src/test/ui/parser/bad-value-ident-true.rs
+++ b/src/test/ui/parser/bad-value-ident-true.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 fn true() { } //~ ERROR expected identifier, found keyword `true`
 fn main() { }
diff --git a/src/test/ui/parser/bad-value-ident-true.stderr b/src/test/ui/parser/bad-value-ident-true.stderr
index f431706..2606b74 100644
--- a/src/test/ui/parser/bad-value-ident-true.stderr
+++ b/src/test/ui/parser/bad-value-ident-true.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found keyword `true`
-  --> $DIR/bad-value-ident-true.rs:3:4
+  --> $DIR/bad-value-ident-true.rs:1:4
    |
 LL | fn true() { } //~ ERROR expected identifier, found keyword `true`
    |    ^^^^ expected identifier, found keyword
diff --git a/src/test/ui/parser/better-expected.rs b/src/test/ui/parser/better-expected.rs
index 0a6dca7..16b61ca 100644
--- a/src/test/ui/parser/better-expected.rs
+++ b/src/test/ui/parser/better-expected.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let x: [isize 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `3`
 }
diff --git a/src/test/ui/parser/better-expected.stderr b/src/test/ui/parser/better-expected.stderr
index 8751a0a..3495353c 100644
--- a/src/test/ui/parser/better-expected.stderr
+++ b/src/test/ui/parser/better-expected.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `3`
-  --> $DIR/better-expected.rs:4:19
+  --> $DIR/better-expected.rs:2:19
    |
 LL |     let x: [isize 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `3`
    |         -         ^ expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/bind-struct-early-modifiers.rs b/src/test/ui/parser/bind-struct-early-modifiers.rs
index 945823f..c1de0df 100644
--- a/src/test/ui/parser/bind-struct-early-modifiers.rs
+++ b/src/test/ui/parser/bind-struct-early-modifiers.rs
@@ -1,9 +1,8 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     struct Foo { x: isize }
     match (Foo { x: 10 }) {
         Foo { ref x: ref x } => {}, //~ ERROR expected `,`
+                                    //~| ERROR pattern does not mention field `x`
         _ => {}
     }
 }
diff --git a/src/test/ui/parser/bind-struct-early-modifiers.stderr b/src/test/ui/parser/bind-struct-early-modifiers.stderr
index ab83744..618e577 100644
--- a/src/test/ui/parser/bind-struct-early-modifiers.stderr
+++ b/src/test/ui/parser/bind-struct-early-modifiers.stderr
@@ -1,8 +1,15 @@
 error: expected `,`
-  --> $DIR/bind-struct-early-modifiers.rs:6:19
+  --> $DIR/bind-struct-early-modifiers.rs:4:19
    |
 LL |         Foo { ref x: ref x } => {}, //~ ERROR expected `,`
    |                   ^
 
-error: aborting due to previous error
+error[E0027]: pattern does not mention field `x`
+  --> $DIR/bind-struct-early-modifiers.rs:4:9
+   |
+LL |         Foo { ref x: ref x } => {}, //~ ERROR expected `,`
+   |         ^^^^^^^^^^^^^^^^^^^^ missing field `x`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0027`.
diff --git a/src/test/ui/parser/bound-single-question-mark.rs b/src/test/ui/parser/bound-single-question-mark.rs
index 0352dc0..64d702d 100644
--- a/src/test/ui/parser/bound-single-question-mark.rs
+++ b/src/test/ui/parser/bound-single-question-mark.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 fn f<T: ?>() {} //~ ERROR expected identifier, found `>`
diff --git a/src/test/ui/parser/bound-single-question-mark.stderr b/src/test/ui/parser/bound-single-question-mark.stderr
index b2c04c7..e30b32f 100644
--- a/src/test/ui/parser/bound-single-question-mark.stderr
+++ b/src/test/ui/parser/bound-single-question-mark.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `>`
-  --> $DIR/bound-single-question-mark.rs:3:10
+  --> $DIR/bound-single-question-mark.rs:1:10
    |
 LL | fn f<T: ?>() {} //~ ERROR expected identifier, found `>`
    |          ^ expected identifier
diff --git a/src/test/ui/parser/bounds-lifetime-1.rs b/src/test/ui/parser/bounds-lifetime-1.rs
index 1e64756..e458f64 100644
--- a/src/test/ui/parser/bounds-lifetime-1.rs
+++ b/src/test/ui/parser/bounds-lifetime-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A = for<'a 'b> fn(); //~ ERROR expected one of `,`, `:`, or `>`, found `'b`
 
 fn main() {}
diff --git a/src/test/ui/parser/bounds-lifetime-1.stderr b/src/test/ui/parser/bounds-lifetime-1.stderr
index 8fe3bdc..33bba35 100644
--- a/src/test/ui/parser/bounds-lifetime-1.stderr
+++ b/src/test/ui/parser/bounds-lifetime-1.stderr
@@ -1,5 +1,5 @@
 error: expected one of `,`, `:`, or `>`, found `'b`
-  --> $DIR/bounds-lifetime-1.rs:3:17
+  --> $DIR/bounds-lifetime-1.rs:1:17
    |
 LL | type A = for<'a 'b> fn(); //~ ERROR expected one of `,`, `:`, or `>`, found `'b`
    |                 ^^ expected one of `,`, `:`, or `>` here
diff --git a/src/test/ui/parser/bounds-lifetime-2.rs b/src/test/ui/parser/bounds-lifetime-2.rs
index 6d865ff..f184107 100644
--- a/src/test/ui/parser/bounds-lifetime-2.rs
+++ b/src/test/ui/parser/bounds-lifetime-2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A = for<'a + 'b> fn(); //~ ERROR expected one of `,`, `:`, or `>`, found `+`
 
 fn main() {}
diff --git a/src/test/ui/parser/bounds-lifetime-2.stderr b/src/test/ui/parser/bounds-lifetime-2.stderr
index c287dc4..a8a22aa 100644
--- a/src/test/ui/parser/bounds-lifetime-2.stderr
+++ b/src/test/ui/parser/bounds-lifetime-2.stderr
@@ -1,5 +1,5 @@
 error: expected one of `,`, `:`, or `>`, found `+`
-  --> $DIR/bounds-lifetime-2.rs:3:17
+  --> $DIR/bounds-lifetime-2.rs:1:17
    |
 LL | type A = for<'a + 'b> fn(); //~ ERROR expected one of `,`, `:`, or `>`, found `+`
    |                 ^ expected one of `,`, `:`, or `>` here
diff --git a/src/test/ui/parser/bounds-lifetime-where-1.rs b/src/test/ui/parser/bounds-lifetime-where-1.rs
index d0c7c9d..f1a002a 100644
--- a/src/test/ui/parser/bounds-lifetime-where-1.rs
+++ b/src/test/ui/parser/bounds-lifetime-where-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A where 'a; //~ ERROR expected `:`, found `;`
 
 fn main() {}
diff --git a/src/test/ui/parser/bounds-lifetime-where-1.stderr b/src/test/ui/parser/bounds-lifetime-where-1.stderr
index 6f8373f..0300fe9 100644
--- a/src/test/ui/parser/bounds-lifetime-where-1.stderr
+++ b/src/test/ui/parser/bounds-lifetime-where-1.stderr
@@ -1,5 +1,5 @@
 error: expected `:`, found `;`
-  --> $DIR/bounds-lifetime-where-1.rs:3:16
+  --> $DIR/bounds-lifetime-where-1.rs:1:16
    |
 LL | type A where 'a; //~ ERROR expected `:`, found `;`
    |                ^ expected `:`
diff --git a/src/test/ui/parser/bounds-lifetime-where.rs b/src/test/ui/parser/bounds-lifetime-where.rs
index 532bf53..acb04e7 100644
--- a/src/test/ui/parser/bounds-lifetime-where.rs
+++ b/src/test/ui/parser/bounds-lifetime-where.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A where 'a: 'b + 'c = u8; // OK
 type A where 'a: 'b, = u8; // OK
 type A where 'a: = u8; // OK
diff --git a/src/test/ui/parser/bounds-lifetime-where.stderr b/src/test/ui/parser/bounds-lifetime-where.stderr
index 4b3dea1..6a8d7e9 100644
--- a/src/test/ui/parser/bounds-lifetime-where.stderr
+++ b/src/test/ui/parser/bounds-lifetime-where.stderr
@@ -1,5 +1,5 @@
 error: expected one of `=`, lifetime, or type, found `,`
-  --> $DIR/bounds-lifetime-where.rs:10:14
+  --> $DIR/bounds-lifetime-where.rs:8:14
    |
 LL | type A where , = u8; //~ ERROR expected one of `=`, lifetime, or type, found `,`
    |              ^ expected one of `=`, lifetime, or type here
diff --git a/src/test/ui/parser/bounds-lifetime.rs b/src/test/ui/parser/bounds-lifetime.rs
index 52b4556..89a969b 100644
--- a/src/test/ui/parser/bounds-lifetime.rs
+++ b/src/test/ui/parser/bounds-lifetime.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A = for<'a:> fn(); // OK
 type A = for<'a:,> fn(); // OK
 type A = for<'a> fn(); // OK
diff --git a/src/test/ui/parser/bounds-lifetime.stderr b/src/test/ui/parser/bounds-lifetime.stderr
index e78d399..f39e5be 100644
--- a/src/test/ui/parser/bounds-lifetime.stderr
+++ b/src/test/ui/parser/bounds-lifetime.stderr
@@ -1,5 +1,5 @@
 error: expected one of `>`, identifier, or lifetime, found `,`
-  --> $DIR/bounds-lifetime.rs:11:14
+  --> $DIR/bounds-lifetime.rs:9:14
    |
 LL | type A = for<,> fn(); //~ ERROR expected one of `>`, identifier, or lifetime, found `,`
    |              ^ expected one of `>`, identifier, or lifetime here
diff --git a/src/test/ui/parser/bounds-obj-parens.rs b/src/test/ui/parser/bounds-obj-parens.rs
index e855231..cc86879 100644
--- a/src/test/ui/parser/bounds-obj-parens.rs
+++ b/src/test/ui/parser/bounds-obj-parens.rs
@@ -1,4 +1,5 @@
 // compile-pass
-// compile-flags: -Z parse-only
 
-type A = Box<(Fn(D::Error) -> E) + 'static + Send + Sync>; // OK (but see #39318)
+type A = Box<(Fn(u8) -> u8) + 'static + Send + Sync>; // OK (but see #39318)
+
+fn main() {}
diff --git a/src/test/ui/parser/bounds-type-where.rs b/src/test/ui/parser/bounds-type-where.rs
index fa10de3..2520ecb 100644
--- a/src/test/ui/parser/bounds-type-where.rs
+++ b/src/test/ui/parser/bounds-type-where.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 type A where for<'a> for<'b> Trait1 + ?Trait2: 'a + Trait = u8; // OK
 type A where T: Trait, = u8; // OK
 type A where T: = u8; // OK
diff --git a/src/test/ui/parser/bounds-type-where.stderr b/src/test/ui/parser/bounds-type-where.stderr
index c29f3ca..459d5c3 100644
--- a/src/test/ui/parser/bounds-type-where.stderr
+++ b/src/test/ui/parser/bounds-type-where.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `:`, `<`, `==`, or `=`, found `,`
-  --> $DIR/bounds-type-where.rs:10:15
+  --> $DIR/bounds-type-where.rs:8:15
    |
 LL | type A where T, = u8;
    |               ^ expected one of 8 possible tokens here
diff --git a/src/test/ui/parser/brace-after-qualified-path-in-match.rs b/src/test/ui/parser/brace-after-qualified-path-in-match.rs
index 1e7d519..f415208 100644
--- a/src/test/ui/parser/brace-after-qualified-path-in-match.rs
+++ b/src/test/ui/parser/brace-after-qualified-path-in-match.rs
@@ -1,7 +1,5 @@
-// compile-flags: -Z parse-only
-
-fn foo() {
-    match x {
+fn main() {
+    match 10 {
         <T as Trait>::Type{key: value} => (),
         //~^ ERROR unexpected `{` after qualified path
         _ => (),
diff --git a/src/test/ui/parser/brace-after-qualified-path-in-match.stderr b/src/test/ui/parser/brace-after-qualified-path-in-match.stderr
index 0afaf87..4c49e31 100644
--- a/src/test/ui/parser/brace-after-qualified-path-in-match.stderr
+++ b/src/test/ui/parser/brace-after-qualified-path-in-match.stderr
@@ -1,5 +1,5 @@
 error: unexpected `{` after qualified path
-  --> $DIR/brace-after-qualified-path-in-match.rs:5:27
+  --> $DIR/brace-after-qualified-path-in-match.rs:3:27
    |
 LL |         <T as Trait>::Type{key: value} => (),
    |                           ^ unexpected `{` after qualified path
diff --git a/src/test/ui/parser/byte-literals.rs b/src/test/ui/parser/byte-literals.rs
index 59dc5ef..bd358af 100644
--- a/src/test/ui/parser/byte-literals.rs
+++ b/src/test/ui/parser/byte-literals.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 
 // ignore-tidy-tab
diff --git a/src/test/ui/parser/byte-string-literals.rs b/src/test/ui/parser/byte-string-literals.rs
index 82ab311..d028f28 100644
--- a/src/test/ui/parser/byte-string-literals.rs
+++ b/src/test/ui/parser/byte-string-literals.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 
 // ignore-tidy-tab
diff --git a/src/test/ui/parser/circular_modules_hello.rs b/src/test/ui/parser/circular_modules_hello.rs
index 06757fb..6968ca9 100644
--- a/src/test/ui/parser/circular_modules_hello.rs
+++ b/src/test/ui/parser/circular_modules_hello.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // ignore-test: this is an auxiliary file for circular-modules-main.rs
 
 #[path = "circular_modules_main.rs"]
diff --git a/src/test/ui/parser/circular_modules_main.rs b/src/test/ui/parser/circular_modules_main.rs
index bd5c438..b85003b 100644
--- a/src/test/ui/parser/circular_modules_main.rs
+++ b/src/test/ui/parser/circular_modules_main.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 #[path = "circular_modules_hello.rs"]
 mod circular_modules_hello; //~ ERROR: circular modules
 
diff --git a/src/test/ui/parser/circular_modules_main.stderr b/src/test/ui/parser/circular_modules_main.stderr
index 0d54e2a..7751a8c 100644
--- a/src/test/ui/parser/circular_modules_main.stderr
+++ b/src/test/ui/parser/circular_modules_main.stderr
@@ -1,5 +1,5 @@
 error: circular modules: $DIR/circular_modules_hello.rs -> $DIR/circular_modules_main.rs -> $DIR/circular_modules_hello.rs
-  --> $DIR/circular_modules_main.rs:4:5
+  --> $DIR/circular_modules_main.rs:2:5
    |
 LL | mod circular_modules_hello; //~ ERROR: circular modules
    |     ^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/class-implements-bad-trait.rs b/src/test/ui/parser/class-implements-bad-trait.rs
index 10ee1a9..f2f85d0 100644
--- a/src/test/ui/parser/class-implements-bad-trait.rs
+++ b/src/test/ui/parser/class-implements-bad-trait.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:nonexistent
 class cat : nonexistent {
   let meows: usize;
diff --git a/src/test/ui/parser/class-implements-bad-trait.stderr b/src/test/ui/parser/class-implements-bad-trait.stderr
index 973f87a..4558346 100644
--- a/src/test/ui/parser/class-implements-bad-trait.stderr
+++ b/src/test/ui/parser/class-implements-bad-trait.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!` or `::`, found `cat`
-  --> $DIR/class-implements-bad-trait.rs:4:7
+  --> $DIR/class-implements-bad-trait.rs:2:7
    |
 LL | class cat : nonexistent {
    |       ^^^ expected one of `!` or `::` here
diff --git a/src/test/ui/parser/closure-return-syntax.rs b/src/test/ui/parser/closure-return-syntax.rs
index ae67510..54eb791 100644
--- a/src/test/ui/parser/closure-return-syntax.rs
+++ b/src/test/ui/parser/closure-return-syntax.rs
@@ -1,8 +1,6 @@
 // Test that we cannot parse a closure with an explicit return type
 // unless it uses braces.
 
-// compile-flags: -Z parse-only
-
 fn main() {
     let x = || -> i32 22;
     //~^ ERROR expected one of `!`, `(`, `+`, `::`, `<`, or `{`, found `22`
diff --git a/src/test/ui/parser/closure-return-syntax.stderr b/src/test/ui/parser/closure-return-syntax.stderr
index 884c213..dd7ebff 100644
--- a/src/test/ui/parser/closure-return-syntax.stderr
+++ b/src/test/ui/parser/closure-return-syntax.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `<`, or `{`, found `22`
-  --> $DIR/closure-return-syntax.rs:7:23
+  --> $DIR/closure-return-syntax.rs:5:23
    |
 LL |     let x = || -> i32 22;
    |                       ^^ expected one of `!`, `(`, `+`, `::`, `<`, or `{` here
diff --git a/src/test/ui/parser/column-offset-1-based.rs b/src/test/ui/parser/column-offset-1-based.rs
index abd5e5a..e158e52 100644
--- a/src/test/ui/parser/column-offset-1-based.rs
+++ b/src/test/ui/parser/column-offset-1-based.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 # //~ ERROR expected `[`, found `<eof>`
diff --git a/src/test/ui/parser/column-offset-1-based.stderr b/src/test/ui/parser/column-offset-1-based.stderr
index 992e1f1..b12b47b 100644
--- a/src/test/ui/parser/column-offset-1-based.stderr
+++ b/src/test/ui/parser/column-offset-1-based.stderr
@@ -1,5 +1,5 @@
 error: expected `[`, found `<eof>`
-  --> $DIR/column-offset-1-based.rs:3:1
+  --> $DIR/column-offset-1-based.rs:1:1
    |
 LL | # //~ ERROR expected `[`, found `<eof>`
    | ^ expected `[`
diff --git a/src/test/ui/parser/default.rs b/src/test/ui/parser/default.rs
index fc092eb..17cd068 100644
--- a/src/test/ui/parser/default.rs
+++ b/src/test/ui/parser/default.rs
@@ -1,7 +1,7 @@
-// compile-flags: -Z parse-only
-
 // Test successful and unsuccessful parsing of the `default` contextual keyword
 
+#![feature(specialization)]
+
 trait Foo {
     fn foo<T: Default>() -> T;
 }
@@ -13,12 +13,12 @@
 }
 
 impl Foo for u16 {
-    pub default fn foo<T: Default>() -> T {
+    pub default fn foo<T: Default>() -> T { //~ ERROR unnecessary visibility qualifier
         T::default()
     }
 }
 
-impl Foo for u32 {
+impl Foo for u32 { //~ ERROR not all trait items implemented, missing: `foo`
     default pub fn foo<T: Default>() -> T { T::default() } //~ ERROR expected one of
 }
 
diff --git a/src/test/ui/parser/default.stderr b/src/test/ui/parser/default.stderr
index ff87706..2719367 100644
--- a/src/test/ui/parser/default.stderr
+++ b/src/test/ui/parser/default.stderr
@@ -4,5 +4,22 @@
 LL |     default pub fn foo<T: Default>() -> T { T::default() } //~ ERROR expected one of
    |             ^^^ expected one of 7 possible tokens here
 
-error: aborting due to previous error
+error[E0449]: unnecessary visibility qualifier
+  --> $DIR/default.rs:16:5
+   |
+LL |     pub default fn foo<T: Default>() -> T { //~ ERROR unnecessary visibility qualifier
+   |     ^^^ `pub` not permitted here because it's implied
 
+error[E0046]: not all trait items implemented, missing: `foo`
+  --> $DIR/default.rs:21:1
+   |
+LL |     fn foo<T: Default>() -> T;
+   |     -------------------------- `foo` from trait
+...
+LL | impl Foo for u32 { //~ ERROR not all trait items implemented, missing: `foo`
+   | ^^^^^^^^^^^^^^^^ missing `foo` in implementation
+
+error: aborting due to 3 previous errors
+
+Some errors occurred: E0046, E0449.
+For more information about an error, try `rustc --explain E0046`.
diff --git a/src/test/ui/parser/do-catch-suggests-try.rs b/src/test/ui/parser/do-catch-suggests-try.rs
index 7ab78dc..61fae72 100644
--- a/src/test/ui/parser/do-catch-suggests-try.rs
+++ b/src/test/ui/parser/do-catch-suggests-try.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let _: Option<()> = do catch {};
     //~^ ERROR found removed `do catch` syntax
diff --git a/src/test/ui/parser/do-catch-suggests-try.stderr b/src/test/ui/parser/do-catch-suggests-try.stderr
index 085cb9d..6d13b0f 100644
--- a/src/test/ui/parser/do-catch-suggests-try.stderr
+++ b/src/test/ui/parser/do-catch-suggests-try.stderr
@@ -1,5 +1,5 @@
 error: found removed `do catch` syntax
-  --> $DIR/do-catch-suggests-try.rs:4:25
+  --> $DIR/do-catch-suggests-try.rs:2:25
    |
 LL |     let _: Option<()> = do catch {};
    |                         ^^
diff --git a/src/test/ui/parser/doc-after-struct-field.rs b/src/test/ui/parser/doc-after-struct-field.rs
index 8a1904f..7870555 100644
--- a/src/test/ui/parser/doc-after-struct-field.rs
+++ b/src/test/ui/parser/doc-after-struct-field.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct X {
     a: u8 /** document a */,
diff --git a/src/test/ui/parser/doc-before-attr.rs b/src/test/ui/parser/doc-before-attr.rs
index 73c6446..c4125a0 100644
--- a/src/test/ui/parser/doc-before-attr.rs
+++ b/src/test/ui/parser/doc-before-attr.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
+fn main() {}
 
 /// hi
 #[derive(Debug)] //~ERROR expected item after attributes
diff --git a/src/test/ui/parser/doc-before-eof.rs b/src/test/ui/parser/doc-before-eof.rs
index 4cf7400..b31836e 100644
--- a/src/test/ui/parser/doc-before-eof.rs
+++ b/src/test/ui/parser/doc-before-eof.rs
@@ -1,3 +1,3 @@
-// compile-flags: -Z parse-only
+fn main() {}
 
 /// hi //~ERROR expected item after doc comment
diff --git a/src/test/ui/parser/doc-before-extern-rbrace.rs b/src/test/ui/parser/doc-before-extern-rbrace.rs
index ec89316..695d4da 100644
--- a/src/test/ui/parser/doc-before-extern-rbrace.rs
+++ b/src/test/ui/parser/doc-before-extern-rbrace.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 extern {
     /// hi
     //~^ ERROR expected item after doc comment
diff --git a/src/test/ui/parser/doc-before-extern-rbrace.stderr b/src/test/ui/parser/doc-before-extern-rbrace.stderr
index e73fc05..47fab7b 100644
--- a/src/test/ui/parser/doc-before-extern-rbrace.stderr
+++ b/src/test/ui/parser/doc-before-extern-rbrace.stderr
@@ -1,5 +1,5 @@
 error: expected item after doc comment
-  --> $DIR/doc-before-extern-rbrace.rs:4:5
+  --> $DIR/doc-before-extern-rbrace.rs:2:5
    |
 LL |     /// hi
    |     ^^^^^^
diff --git a/src/test/ui/parser/doc-before-fn-rbrace.rs b/src/test/ui/parser/doc-before-fn-rbrace.rs
index 68a5dd3..d33520b 100644
--- a/src/test/ui/parser/doc-before-fn-rbrace.rs
+++ b/src/test/ui/parser/doc-before-fn-rbrace.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     /// document
diff --git a/src/test/ui/parser/doc-before-identifier.rs b/src/test/ui/parser/doc-before-identifier.rs
index 7dc472d..d9777be 100644
--- a/src/test/ui/parser/doc-before-identifier.rs
+++ b/src/test/ui/parser/doc-before-identifier.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn /// document
 foo() {}
diff --git a/src/test/ui/parser/doc-before-mod-rbrace.rs b/src/test/ui/parser/doc-before-mod-rbrace.rs
index 9ce6f99..4e0b65e 100644
--- a/src/test/ui/parser/doc-before-mod-rbrace.rs
+++ b/src/test/ui/parser/doc-before-mod-rbrace.rs
@@ -1,6 +1,8 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 mod Foo {
     /// document
     //~^ ERROR expected item after doc comment
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/doc-before-rbrace.rs b/src/test/ui/parser/doc-before-rbrace.rs
index d24f711..8ff9463 100644
--- a/src/test/ui/parser/doc-before-rbrace.rs
+++ b/src/test/ui/parser/doc-before-rbrace.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     println!("Hi"); /// hi
     //~^ ERROR found a documentation comment that doesn't document anything
diff --git a/src/test/ui/parser/doc-before-rbrace.stderr b/src/test/ui/parser/doc-before-rbrace.stderr
index 2c6c93e..55719cf 100644
--- a/src/test/ui/parser/doc-before-rbrace.stderr
+++ b/src/test/ui/parser/doc-before-rbrace.stderr
@@ -1,5 +1,5 @@
 error[E0585]: found a documentation comment that doesn't document anything
-  --> $DIR/doc-before-rbrace.rs:4:21
+  --> $DIR/doc-before-rbrace.rs:2:21
    |
 LL |     println!("Hi"); /// hi
    |                     ^^^^^^
diff --git a/src/test/ui/parser/doc-before-semi.rs b/src/test/ui/parser/doc-before-semi.rs
index 2d5d549..405a7e1 100644
--- a/src/test/ui/parser/doc-before-semi.rs
+++ b/src/test/ui/parser/doc-before-semi.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     /// hi
     //~^ ERROR found a documentation comment that doesn't document anything
diff --git a/src/test/ui/parser/doc-before-semi.stderr b/src/test/ui/parser/doc-before-semi.stderr
index f1960ae..e6bade1 100644
--- a/src/test/ui/parser/doc-before-semi.stderr
+++ b/src/test/ui/parser/doc-before-semi.stderr
@@ -1,5 +1,5 @@
 error[E0585]: found a documentation comment that doesn't document anything
-  --> $DIR/doc-before-semi.rs:4:5
+  --> $DIR/doc-before-semi.rs:2:5
    |
 LL |     /// hi
    |     ^^^^^^
diff --git a/src/test/ui/parser/doc-before-struct-rbrace-1.rs b/src/test/ui/parser/doc-before-struct-rbrace-1.rs
index b67fc28..e7055f6 100644
--- a/src/test/ui/parser/doc-before-struct-rbrace-1.rs
+++ b/src/test/ui/parser/doc-before-struct-rbrace-1.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct X {
     a: u8,
diff --git a/src/test/ui/parser/doc-before-struct-rbrace-2.rs b/src/test/ui/parser/doc-before-struct-rbrace-2.rs
index e0e9868..d5c2a31 100644
--- a/src/test/ui/parser/doc-before-struct-rbrace-2.rs
+++ b/src/test/ui/parser/doc-before-struct-rbrace-2.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct X {
     a: u8 /// document
diff --git a/src/test/ui/parser/duplicate-visibility.rs b/src/test/ui/parser/duplicate-visibility.rs
index 0c08af6..bb17e97 100644
--- a/src/test/ui/parser/duplicate-visibility.rs
+++ b/src/test/ui/parser/duplicate-visibility.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected one of `(`, `fn`, `static`, or `type`
 extern {
     pub pub fn foo();
diff --git a/src/test/ui/parser/duplicate-visibility.stderr b/src/test/ui/parser/duplicate-visibility.stderr
index 7b16cdd..880b536 100644
--- a/src/test/ui/parser/duplicate-visibility.stderr
+++ b/src/test/ui/parser/duplicate-visibility.stderr
@@ -1,5 +1,5 @@
 error: expected one of `(`, `fn`, `static`, or `type`, found `pub`
-  --> $DIR/duplicate-visibility.rs:5:9
+  --> $DIR/duplicate-visibility.rs:3:9
    |
 LL |     pub pub fn foo();
    |         ^^^ expected one of `(`, `fn`, `static`, or `type` here
diff --git a/src/test/ui/parser/empty-impl-semicolon.rs b/src/test/ui/parser/empty-impl-semicolon.rs
index 57fad0e..207ebef 100644
--- a/src/test/ui/parser/empty-impl-semicolon.rs
+++ b/src/test/ui/parser/empty-impl-semicolon.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 impl Foo; //~ ERROR expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `;`
diff --git a/src/test/ui/parser/empty-impl-semicolon.stderr b/src/test/ui/parser/empty-impl-semicolon.stderr
index 770eab3..965a8a4 100644
--- a/src/test/ui/parser/empty-impl-semicolon.stderr
+++ b/src/test/ui/parser/empty-impl-semicolon.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `;`
-  --> $DIR/empty-impl-semicolon.rs:3:9
+  --> $DIR/empty-impl-semicolon.rs:1:9
    |
 LL | impl Foo; //~ ERROR expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `;`
    |         ^ expected one of 8 possible tokens here
diff --git a/src/test/ui/parser/extern-crate-unexpected-token.rs b/src/test/ui/parser/extern-crate-unexpected-token.rs
index c383de6..58b2fa1 100644
--- a/src/test/ui/parser/extern-crate-unexpected-token.rs
+++ b/src/test/ui/parser/extern-crate-unexpected-token.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 extern crte foo; //~ ERROR expected one of `crate`, `fn`, or `{`, found `crte`
diff --git a/src/test/ui/parser/extern-crate-unexpected-token.stderr b/src/test/ui/parser/extern-crate-unexpected-token.stderr
index b45920a..ed888eb 100644
--- a/src/test/ui/parser/extern-crate-unexpected-token.stderr
+++ b/src/test/ui/parser/extern-crate-unexpected-token.stderr
@@ -1,5 +1,5 @@
 error: expected one of `crate`, `fn`, or `{`, found `crte`
-  --> $DIR/extern-crate-unexpected-token.rs:3:8
+  --> $DIR/extern-crate-unexpected-token.rs:1:8
    |
 LL | extern crte foo; //~ ERROR expected one of `crate`, `fn`, or `{`, found `crte`
    |        ^^^^ expected one of `crate`, `fn`, or `{` here
diff --git a/src/test/ui/parser/extern-expected-fn-or-brace.rs b/src/test/ui/parser/extern-expected-fn-or-brace.rs
index 1371332..dd46b87 100644
--- a/src/test/ui/parser/extern-expected-fn-or-brace.rs
+++ b/src/test/ui/parser/extern-expected-fn-or-brace.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Verifies that the expected token errors for `extern crate` are
 // raised
 
diff --git a/src/test/ui/parser/extern-expected-fn-or-brace.stderr b/src/test/ui/parser/extern-expected-fn-or-brace.stderr
index 4bd95db..94b2d1d 100644
--- a/src/test/ui/parser/extern-expected-fn-or-brace.stderr
+++ b/src/test/ui/parser/extern-expected-fn-or-brace.stderr
@@ -1,5 +1,5 @@
 error: expected one of `fn` or `{`, found `mod`
-  --> $DIR/extern-expected-fn-or-brace.rs:6:12
+  --> $DIR/extern-expected-fn-or-brace.rs:4:12
    |
 LL | extern "C" mod foo; //~ERROR expected one of `fn` or `{`, found `mod`
    |            ^^^ expected one of `fn` or `{` here
diff --git a/src/test/ui/parser/extern-foreign-crate.rs b/src/test/ui/parser/extern-foreign-crate.rs
index d770b66..a5da77d 100644
--- a/src/test/ui/parser/extern-foreign-crate.rs
+++ b/src/test/ui/parser/extern-foreign-crate.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Verifies that the expected token errors for `extern crate` are
 // raised
 
diff --git a/src/test/ui/parser/extern-foreign-crate.stderr b/src/test/ui/parser/extern-foreign-crate.stderr
index 32b2667..d2fe8b7 100644
--- a/src/test/ui/parser/extern-foreign-crate.stderr
+++ b/src/test/ui/parser/extern-foreign-crate.stderr
@@ -1,5 +1,5 @@
 error: expected one of `;` or `as`, found `{`
-  --> $DIR/extern-foreign-crate.rs:6:18
+  --> $DIR/extern-foreign-crate.rs:4:18
    |
 LL | extern crate foo {} //~ERROR expected one of `;` or `as`, found `{`
    |                  ^ expected one of `;` or `as` here
diff --git a/src/test/ui/parser/extern-no-fn.rs b/src/test/ui/parser/extern-no-fn.rs
index 2836ec7..c37ddd6 100644
--- a/src/test/ui/parser/extern-no-fn.rs
+++ b/src/test/ui/parser/extern-no-fn.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 extern { //~ ERROR missing `fn`, `type`, or `static` for extern-item declaration
     f();
 }
diff --git a/src/test/ui/parser/extern-no-fn.stderr b/src/test/ui/parser/extern-no-fn.stderr
index 5a3618c..e764cd0 100644
--- a/src/test/ui/parser/extern-no-fn.stderr
+++ b/src/test/ui/parser/extern-no-fn.stderr
@@ -1,5 +1,5 @@
 error: missing `fn`, `type`, or `static` for extern-item declaration
-  --> $DIR/extern-no-fn.rs:3:9
+  --> $DIR/extern-no-fn.rs:1:9
    |
 LL |   extern { //~ ERROR missing `fn`, `type`, or `static` for extern-item declaration
    |  _________^
diff --git a/src/test/ui/parser/if-in-in.rs b/src/test/ui/parser/if-in-in.rs
index 7008863..212378c2 100644
--- a/src/test/ui/parser/if-in-in.rs
+++ b/src/test/ui/parser/if-in-in.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     for i in in 1..2 { //~ ERROR expected iterable, found keyword `in`
         println!("{}", i);
diff --git a/src/test/ui/parser/if-in-in.stderr b/src/test/ui/parser/if-in-in.stderr
index d741c70..2938bba 100644
--- a/src/test/ui/parser/if-in-in.stderr
+++ b/src/test/ui/parser/if-in-in.stderr
@@ -1,5 +1,5 @@
 error: expected iterable, found keyword `in`
-  --> $DIR/if-in-in.rs:4:14
+  --> $DIR/if-in-in.rs:2:14
    |
 LL |     for i in in 1..2 { //~ ERROR expected iterable, found keyword `in`
    |           ---^^
diff --git a/src/test/ui/parser/impl-parsing.rs b/src/test/ui/parser/impl-parsing.rs
index 4bfdb24..c2a80e8 100644
--- a/src/test/ui/parser/impl-parsing.rs
+++ b/src/test/ui/parser/impl-parsing.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 impl ! {} // OK
 impl ! where u8: Copy {} // OK
diff --git a/src/test/ui/parser/import-from-path.rs b/src/test/ui/parser/import-from-path.rs
index e3fee98..3fce082 100644
--- a/src/test/ui/parser/import-from-path.rs
+++ b/src/test/ui/parser/import-from-path.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected
 use foo::{bar}::baz
diff --git a/src/test/ui/parser/import-from-path.stderr b/src/test/ui/parser/import-from-path.stderr
index 0afc178..5842037 100644
--- a/src/test/ui/parser/import-from-path.stderr
+++ b/src/test/ui/parser/import-from-path.stderr
@@ -1,5 +1,5 @@
 error: expected `;`, found `::`
-  --> $DIR/import-from-path.rs:4:15
+  --> $DIR/import-from-path.rs:2:15
    |
 LL | use foo::{bar}::baz
    |               ^^ expected `;`
diff --git a/src/test/ui/parser/import-from-rename.rs b/src/test/ui/parser/import-from-rename.rs
index 498bbd6..27425a3 100644
--- a/src/test/ui/parser/import-from-rename.rs
+++ b/src/test/ui/parser/import-from-rename.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected
 
 use foo::{bar} as baz;
diff --git a/src/test/ui/parser/import-from-rename.stderr b/src/test/ui/parser/import-from-rename.stderr
index 6afdc24..a966e99 100644
--- a/src/test/ui/parser/import-from-rename.stderr
+++ b/src/test/ui/parser/import-from-rename.stderr
@@ -1,5 +1,5 @@
 error: expected `;`, found keyword `as`
-  --> $DIR/import-from-rename.rs:5:16
+  --> $DIR/import-from-rename.rs:3:16
    |
 LL | use foo::{bar} as baz;
    |                ^^ expected `;`
diff --git a/src/test/ui/parser/import-glob-path.rs b/src/test/ui/parser/import-glob-path.rs
index 5a3a581..de4c07a 100644
--- a/src/test/ui/parser/import-glob-path.rs
+++ b/src/test/ui/parser/import-glob-path.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected
 use foo::*::bar
diff --git a/src/test/ui/parser/import-glob-path.stderr b/src/test/ui/parser/import-glob-path.stderr
index a8426b7..ebca2db 100644
--- a/src/test/ui/parser/import-glob-path.stderr
+++ b/src/test/ui/parser/import-glob-path.stderr
@@ -1,5 +1,5 @@
 error: expected `;`, found `::`
-  --> $DIR/import-glob-path.rs:4:11
+  --> $DIR/import-glob-path.rs:2:11
    |
 LL | use foo::*::bar
    |           ^^ expected `;`
diff --git a/src/test/ui/parser/import-glob-rename.rs b/src/test/ui/parser/import-glob-rename.rs
index f96f48d..b9b753dc 100644
--- a/src/test/ui/parser/import-glob-rename.rs
+++ b/src/test/ui/parser/import-glob-rename.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected
 
 use foo::* as baz;
diff --git a/src/test/ui/parser/import-glob-rename.stderr b/src/test/ui/parser/import-glob-rename.stderr
index 475c8d7..2853873 100644
--- a/src/test/ui/parser/import-glob-rename.stderr
+++ b/src/test/ui/parser/import-glob-rename.stderr
@@ -1,5 +1,5 @@
 error: expected `;`, found keyword `as`
-  --> $DIR/import-glob-rename.rs:5:12
+  --> $DIR/import-glob-rename.rs:3:12
    |
 LL | use foo::* as baz;
    |            ^^ expected `;`
diff --git a/src/test/ui/parser/inner-attr-after-doc-comment.rs b/src/test/ui/parser/inner-attr-after-doc-comment.rs
index 1c72ed0..36f4191 100644
--- a/src/test/ui/parser/inner-attr-after-doc-comment.rs
+++ b/src/test/ui/parser/inner-attr-after-doc-comment.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 #![feature(lang_items)]
 /**
  * My module
diff --git a/src/test/ui/parser/inner-attr-after-doc-comment.stderr b/src/test/ui/parser/inner-attr-after-doc-comment.stderr
index 8ce82b5..0dde49a 100644
--- a/src/test/ui/parser/inner-attr-after-doc-comment.stderr
+++ b/src/test/ui/parser/inner-attr-after-doc-comment.stderr
@@ -1,5 +1,5 @@
 error: an inner attribute is not permitted following an outer doc comment
-  --> $DIR/inner-attr-after-doc-comment.rs:8:3
+  --> $DIR/inner-attr-after-doc-comment.rs:6:3
    |
 LL | #![recursion_limit="100"]
    |   ^
diff --git a/src/test/ui/parser/inner-attr.rs b/src/test/ui/parser/inner-attr.rs
index 07bcf07..1b405e2 100644
--- a/src/test/ui/parser/inner-attr.rs
+++ b/src/test/ui/parser/inner-attr.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 #[feature(lang_items)]
 
 #![recursion_limit="100"] //~ ERROR an inner attribute is not permitted following an outer attribute
diff --git a/src/test/ui/parser/inner-attr.stderr b/src/test/ui/parser/inner-attr.stderr
index bce0b74..001eab2 100644
--- a/src/test/ui/parser/inner-attr.stderr
+++ b/src/test/ui/parser/inner-attr.stderr
@@ -1,5 +1,5 @@
 error: an inner attribute is not permitted following an outer attribute
-  --> $DIR/inner-attr.rs:5:3
+  --> $DIR/inner-attr.rs:3:3
    |
 LL | #![recursion_limit="100"] //~ ERROR an inner attribute is not permitted following an outer attribute
    |   ^
diff --git a/src/test/ui/parser/int-literal-too-large-span.rs b/src/test/ui/parser/int-literal-too-large-span.rs
index 0de7139..206242c 100644
--- a/src/test/ui/parser/int-literal-too-large-span.rs
+++ b/src/test/ui/parser/int-literal-too-large-span.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // issue #17123
 
 fn main() {
diff --git a/src/test/ui/parser/int-literal-too-large-span.stderr b/src/test/ui/parser/int-literal-too-large-span.stderr
index 26e115e..d7774c3 100644
--- a/src/test/ui/parser/int-literal-too-large-span.stderr
+++ b/src/test/ui/parser/int-literal-too-large-span.stderr
@@ -1,5 +1,5 @@
 error: int literal is too large
-  --> $DIR/int-literal-too-large-span.rs:6:5
+  --> $DIR/int-literal-too-large-span.rs:4:5
    |
 LL |     9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/inverted-parameters.rs b/src/test/ui/parser/inverted-parameters.rs
index c0d9523..4243027 100644
--- a/src/test/ui/parser/inverted-parameters.rs
+++ b/src/test/ui/parser/inverted-parameters.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct S;
 
 impl S {
diff --git a/src/test/ui/parser/inverted-parameters.stderr b/src/test/ui/parser/inverted-parameters.stderr
index f733424..bdb8faa 100644
--- a/src/test/ui/parser/inverted-parameters.stderr
+++ b/src/test/ui/parser/inverted-parameters.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:` or `@`, found `bar`
-  --> $DIR/inverted-parameters.rs:6:24
+  --> $DIR/inverted-parameters.rs:4:24
    |
 LL |     fn foo(&self, &str bar) {}
    |                   -----^^^
@@ -8,7 +8,7 @@
    |                   help: declare the type after the parameter binding: `<identifier>: <type>`
 
 error: expected one of `:` or `@`, found `quux`
-  --> $DIR/inverted-parameters.rs:12:10
+  --> $DIR/inverted-parameters.rs:10:10
    |
 LL | fn baz(S quux, xyzzy: i32) {}
    |        --^^^^
@@ -17,25 +17,25 @@
    |        help: declare the type after the parameter binding: `<identifier>: <type>`
 
 error: expected one of `:` or `@`, found `a`
-  --> $DIR/inverted-parameters.rs:17:12
+  --> $DIR/inverted-parameters.rs:15:12
    |
 LL | fn one(i32 a b) {}
    |            ^ expected one of `:` or `@` here
 
 error: expected `:`, found `(`
-  --> $DIR/inverted-parameters.rs:20:23
+  --> $DIR/inverted-parameters.rs:18:23
    |
 LL | fn pattern((i32, i32) (a, b)) {}
    |                       ^ expected `:`
 
 error: expected one of `:` or `@`, found `)`
-  --> $DIR/inverted-parameters.rs:23:12
+  --> $DIR/inverted-parameters.rs:21:12
    |
 LL | fn fizz(i32) {}
    |            ^ expected one of `:` or `@` here
 
 error: expected one of `:` or `@`, found `S`
-  --> $DIR/inverted-parameters.rs:26:23
+  --> $DIR/inverted-parameters.rs:24:23
    |
 LL | fn missing_colon(quux S) {}
    |                  -----^
diff --git a/src/test/ui/parser/issue-10392-2.rs b/src/test/ui/parser/issue-10392-2.rs
index 63d3f4c..3b5e319 100644
--- a/src/test/ui/parser/issue-10392-2.rs
+++ b/src/test/ui/parser/issue-10392-2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct A { foo: isize }
 
 fn a() -> A { panic!() }
diff --git a/src/test/ui/parser/issue-10392-2.stderr b/src/test/ui/parser/issue-10392-2.stderr
index 9c04ba3..47e1f7a 100644
--- a/src/test/ui/parser/issue-10392-2.stderr
+++ b/src/test/ui/parser/issue-10392-2.stderr
@@ -1,5 +1,5 @@
 error: expected `}`, found `,`
-  --> $DIR/issue-10392-2.rs:8:15
+  --> $DIR/issue-10392-2.rs:6:15
    |
 LL |     let A { .., } = a(); //~ ERROR: expected `}`
    |             --^
diff --git a/src/test/ui/parser/issue-10392.rs b/src/test/ui/parser/issue-10392.rs
index 41f6e34..dd84af3 100644
--- a/src/test/ui/parser/issue-10392.rs
+++ b/src/test/ui/parser/issue-10392.rs
@@ -1,9 +1,8 @@
-// compile-flags: -Z parse-only
-
 struct A { foo: isize }
 
 fn a() -> A { panic!() }
 
 fn main() {
-    let A { , } = a(); //~ ERROR: expected ident
+    let A { , } = a(); //~ ERROR expected ident
+                       //~| ERROR pattern does not mention field `foo`
 }
diff --git a/src/test/ui/parser/issue-10392.stderr b/src/test/ui/parser/issue-10392.stderr
index e8af009..9c9858a 100644
--- a/src/test/ui/parser/issue-10392.stderr
+++ b/src/test/ui/parser/issue-10392.stderr
@@ -1,8 +1,15 @@
 error: expected identifier, found `,`
-  --> $DIR/issue-10392.rs:8:13
+  --> $DIR/issue-10392.rs:6:13
    |
-LL |     let A { , } = a(); //~ ERROR: expected ident
+LL |     let A { , } = a(); //~ ERROR expected ident
    |             ^ expected identifier
 
-error: aborting due to previous error
+error[E0027]: pattern does not mention field `foo`
+  --> $DIR/issue-10392.rs:6:9
+   |
+LL |     let A { , } = a(); //~ ERROR expected ident
+   |         ^^^^^^^ missing field `foo`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0027`.
diff --git a/src/test/ui/parser/issue-10636-1.rs b/src/test/ui/parser/issue-10636-1.rs
index 0bb55cc..e495c04 100644
--- a/src/test/ui/parser/issue-10636-1.rs
+++ b/src/test/ui/parser/issue-10636-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Obj {
     //~^ NOTE: un-closed delimiter
     member: usize
diff --git a/src/test/ui/parser/issue-10636-1.stderr b/src/test/ui/parser/issue-10636-1.stderr
index 233f37c..894139f 100644
--- a/src/test/ui/parser/issue-10636-1.stderr
+++ b/src/test/ui/parser/issue-10636-1.stderr
@@ -1,5 +1,5 @@
 error: incorrect close delimiter: `)`
-  --> $DIR/issue-10636-1.rs:6:1
+  --> $DIR/issue-10636-1.rs:4:1
    |
 LL | struct Obj {
    |            - un-closed delimiter
diff --git a/src/test/ui/parser/issue-10636-2.rs b/src/test/ui/parser/issue-10636-2.rs
index de3208e..a02fd41 100644
--- a/src/test/ui/parser/issue-10636-2.rs
+++ b/src/test/ui/parser/issue-10636-2.rs
@@ -1,8 +1,6 @@
 // FIXME(31528) we emit a bunch of silly errors here due to continuing past the
 // first one. This would be easy-ish to address by better recovery in tokenisation.
 
-// compile-flags: -Z parse-only
-
 pub fn trace_option(option: Option<isize>) {
     option.map(|some| 42;
                           //~^ ERROR: expected one of
diff --git a/src/test/ui/parser/issue-10636-2.stderr b/src/test/ui/parser/issue-10636-2.stderr
index d6a8b52..9b3115c 100644
--- a/src/test/ui/parser/issue-10636-2.stderr
+++ b/src/test/ui/parser/issue-10636-2.stderr
@@ -1,5 +1,5 @@
 error: incorrect close delimiter: `}`
-  --> $DIR/issue-10636-2.rs:10:1
+  --> $DIR/issue-10636-2.rs:8:1
    |
 LL | pub fn trace_option(option: Option<isize>) {
    |                                            - close delimiter possibly meant for this
@@ -10,13 +10,13 @@
    | ^ incorrect close delimiter
 
 error: expected one of `)`, `,`, `.`, `?`, or an operator, found `;`
-  --> $DIR/issue-10636-2.rs:7:25
+  --> $DIR/issue-10636-2.rs:5:25
    |
 LL |     option.map(|some| 42;
    |                         ^ expected one of `)`, `,`, `.`, `?`, or an operator here
 
 error: expected expression, found `)`
-  --> $DIR/issue-10636-2.rs:10:1
+  --> $DIR/issue-10636-2.rs:8:1
    |
 LL | } //~ ERROR: incorrect close delimiter
    | ^ expected expression
diff --git a/src/test/ui/parser/issue-14303-enum.rs b/src/test/ui/parser/issue-14303-enum.rs
index c111959..a610615 100644
--- a/src/test/ui/parser/issue-14303-enum.rs
+++ b/src/test/ui/parser/issue-14303-enum.rs
@@ -1,6 +1,6 @@
-// compile-flags: -Z parse-only
-
 enum X<'a, T, 'b> {
 //~^ ERROR lifetime parameters must be declared prior to type parameters
-    A(&'a T)
+    A(&'a &'b T)
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-enum.stderr b/src/test/ui/parser/issue-14303-enum.stderr
index f691295..a31429e 100644
--- a/src/test/ui/parser/issue-14303-enum.stderr
+++ b/src/test/ui/parser/issue-14303-enum.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-enum.rs:3:15
+  --> $DIR/issue-14303-enum.rs:1:15
    |
 LL | enum X<'a, T, 'b> {
    |               ^^
diff --git a/src/test/ui/parser/issue-14303-fn-def.rs b/src/test/ui/parser/issue-14303-fn-def.rs
index 1ad15f9..221bd31 100644
--- a/src/test/ui/parser/issue-14303-fn-def.rs
+++ b/src/test/ui/parser/issue-14303-fn-def.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn foo<'a, T, 'b>(x: &'a T) {}
 //~^ ERROR lifetime parameters must be declared prior to type parameters
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-fn-def.stderr b/src/test/ui/parser/issue-14303-fn-def.stderr
index 4fe3856..4582aee 100644
--- a/src/test/ui/parser/issue-14303-fn-def.stderr
+++ b/src/test/ui/parser/issue-14303-fn-def.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-fn-def.rs:3:15
+  --> $DIR/issue-14303-fn-def.rs:1:15
    |
 LL | fn foo<'a, T, 'b>(x: &'a T) {}
    |               ^^
diff --git a/src/test/ui/parser/issue-14303-fncall.rs b/src/test/ui/parser/issue-14303-fncall.rs
index 3642b80..f589434 100644
--- a/src/test/ui/parser/issue-14303-fncall.rs
+++ b/src/test/ui/parser/issue-14303-fncall.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     (0..4)
     .map(|x| x * 2)
diff --git a/src/test/ui/parser/issue-14303-fncall.stderr b/src/test/ui/parser/issue-14303-fncall.stderr
index cde0847..1cc82f5 100644
--- a/src/test/ui/parser/issue-14303-fncall.stderr
+++ b/src/test/ui/parser/issue-14303-fncall.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-fncall.rs:6:31
+  --> $DIR/issue-14303-fncall.rs:4:31
    |
 LL |     .collect::<Vec<'a, usize, 'b>>()
    |                               ^^
diff --git a/src/test/ui/parser/issue-14303-impl.rs b/src/test/ui/parser/issue-14303-impl.rs
index 6430153..4dc2c66 100644
--- a/src/test/ui/parser/issue-14303-impl.rs
+++ b/src/test/ui/parser/issue-14303-impl.rs
@@ -1,6 +1,6 @@
-// compile-flags: -Z parse-only
+struct X<T>(T);
 
-struct X { x: isize }
-
-impl<'a, T, 'b> X {}
+impl<'a, T, 'b> X<T> {}
 //~^ ERROR lifetime parameters must be declared prior to type parameters
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-impl.stderr b/src/test/ui/parser/issue-14303-impl.stderr
index f4ea550..a195339 100644
--- a/src/test/ui/parser/issue-14303-impl.stderr
+++ b/src/test/ui/parser/issue-14303-impl.stderr
@@ -1,11 +1,11 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-impl.rs:5:13
+  --> $DIR/issue-14303-impl.rs:3:13
    |
-LL | impl<'a, T, 'b> X {}
+LL | impl<'a, T, 'b> X<T> {}
    |             ^^
 help: move the lifetime parameter prior to the first type parameter
    |
-LL | impl<'a, 'b, T> X {}
+LL | impl<'a, 'b, T> X<T> {}
    |          ^^^ --
 
 error: aborting due to previous error
diff --git a/src/test/ui/parser/issue-14303-path.rs b/src/test/ui/parser/issue-14303-path.rs
index 0f0641e..f61cb6b 100644
--- a/src/test/ui/parser/issue-14303-path.rs
+++ b/src/test/ui/parser/issue-14303-path.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn bar<'a, T>(x: mymodule::X<'a, T, 'b, 'c>) {}
 //~^ ERROR lifetime parameters must be declared prior to type parameters
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-path.stderr b/src/test/ui/parser/issue-14303-path.stderr
index 155fa46..3de8a16 100644
--- a/src/test/ui/parser/issue-14303-path.stderr
+++ b/src/test/ui/parser/issue-14303-path.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-path.rs:3:37
+  --> $DIR/issue-14303-path.rs:1:37
    |
 LL | fn bar<'a, T>(x: mymodule::X<'a, T, 'b, 'c>) {}
    |                                     ^^
diff --git a/src/test/ui/parser/issue-14303-struct.rs b/src/test/ui/parser/issue-14303-struct.rs
index d9d5859..0bd10b4 100644
--- a/src/test/ui/parser/issue-14303-struct.rs
+++ b/src/test/ui/parser/issue-14303-struct.rs
@@ -1,6 +1,6 @@
-// compile-flags: -Z parse-only
-
 struct X<'a, T, 'b> {
 //~^ ERROR lifetime parameters must be declared prior to type parameters
-    x: &'a T
+    x: &'a &'b T
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-struct.stderr b/src/test/ui/parser/issue-14303-struct.stderr
index 3d8c74c..668b8d1 100644
--- a/src/test/ui/parser/issue-14303-struct.stderr
+++ b/src/test/ui/parser/issue-14303-struct.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-struct.rs:3:17
+  --> $DIR/issue-14303-struct.rs:1:17
    |
 LL | struct X<'a, T, 'b> {
    |                 ^^
diff --git a/src/test/ui/parser/issue-14303-trait.rs b/src/test/ui/parser/issue-14303-trait.rs
index fb4c01a..f253de9 100644
--- a/src/test/ui/parser/issue-14303-trait.rs
+++ b/src/test/ui/parser/issue-14303-trait.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 trait Foo<'a, T, 'b> {}
 //~^ ERROR lifetime parameters must be declared prior to type parameters
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-14303-trait.stderr b/src/test/ui/parser/issue-14303-trait.stderr
index 4f6b18d..11ce0c4 100644
--- a/src/test/ui/parser/issue-14303-trait.stderr
+++ b/src/test/ui/parser/issue-14303-trait.stderr
@@ -1,5 +1,5 @@
 error: lifetime parameters must be declared prior to type parameters
-  --> $DIR/issue-14303-trait.rs:3:18
+  --> $DIR/issue-14303-trait.rs:1:18
    |
 LL | trait Foo<'a, T, 'b> {}
    |                  ^^
diff --git a/src/test/ui/parser/issue-15914.rs b/src/test/ui/parser/issue-15914.rs
index c82e2b6..4a5606a 100644
--- a/src/test/ui/parser/issue-15914.rs
+++ b/src/test/ui/parser/issue-15914.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let ref
         (); //~ ERROR expected identifier, found `(`
diff --git a/src/test/ui/parser/issue-15914.stderr b/src/test/ui/parser/issue-15914.stderr
index 0c70a7f..3a886c4 100644
--- a/src/test/ui/parser/issue-15914.stderr
+++ b/src/test/ui/parser/issue-15914.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `(`
-  --> $DIR/issue-15914.rs:5:9
+  --> $DIR/issue-15914.rs:3:9
    |
 LL |         (); //~ ERROR expected identifier, found `(`
    |         ^ expected identifier
diff --git a/src/test/ui/parser/issue-15980.rs b/src/test/ui/parser/issue-15980.rs
index 4400021..ba874fb 100644
--- a/src/test/ui/parser/issue-15980.rs
+++ b/src/test/ui/parser/issue-15980.rs
@@ -1,9 +1,7 @@
-// compile-flags: -Z parse-only
-
 use std::io;
 
 fn main(){
-    let x: io::IoResult<()> = Ok(());
+    let x: io::Result<()> = Ok(());
     match x {
         Err(ref e) if e.kind == io::EndOfFile {
             //~^ NOTE while parsing this struct
diff --git a/src/test/ui/parser/issue-15980.stderr b/src/test/ui/parser/issue-15980.stderr
index 96f3b03..c915952 100644
--- a/src/test/ui/parser/issue-15980.stderr
+++ b/src/test/ui/parser/issue-15980.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found keyword `return`
-  --> $DIR/issue-15980.rs:10:13
+  --> $DIR/issue-15980.rs:8:13
    |
 LL |         Err(ref e) if e.kind == io::EndOfFile {
    |                                 ------------- while parsing this struct
@@ -12,7 +12,7 @@
    |
 
 error: expected one of `.`, `=>`, `?`, or an operator, found `_`
-  --> $DIR/issue-15980.rs:15:9
+  --> $DIR/issue-15980.rs:13:9
    |
 LL |         }
    |          - expected one of `.`, `=>`, `?`, or an operator here
diff --git a/src/test/ui/parser/issue-1655.rs b/src/test/ui/parser/issue-1655.rs
index 2be809b..3d0bf3c 100644
--- a/src/test/ui/parser/issue-1655.rs
+++ b/src/test/ui/parser/issue-1655.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:expected `[`, found `vec`
 mod blade_runner {
     #vec[doc(
diff --git a/src/test/ui/parser/issue-1655.stderr b/src/test/ui/parser/issue-1655.stderr
index 8a8e100..3f656b6 100644
--- a/src/test/ui/parser/issue-1655.stderr
+++ b/src/test/ui/parser/issue-1655.stderr
@@ -1,5 +1,5 @@
 error: expected `[`, found `vec`
-  --> $DIR/issue-1655.rs:5:6
+  --> $DIR/issue-1655.rs:3:6
    |
 LL |     #vec[doc(
    |      ^^^ expected `[`
diff --git a/src/test/ui/parser/issue-17383.rs b/src/test/ui/parser/issue-17383.rs
index bbe3a9b..9c00289 100644
--- a/src/test/ui/parser/issue-17383.rs
+++ b/src/test/ui/parser/issue-17383.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 enum X {
     A =
         b'a' //~ ERROR discriminator values can only be used with a field-less enum
diff --git a/src/test/ui/parser/issue-17383.stderr b/src/test/ui/parser/issue-17383.stderr
index 808e399..b225e11 100644
--- a/src/test/ui/parser/issue-17383.stderr
+++ b/src/test/ui/parser/issue-17383.stderr
@@ -1,5 +1,5 @@
 error: discriminator values can only be used with a field-less enum
-  --> $DIR/issue-17383.rs:5:9
+  --> $DIR/issue-17383.rs:3:9
    |
 LL |         b'a' //~ ERROR discriminator values can only be used with a field-less enum
    |         ^^^^
diff --git a/src/test/ui/parser/issue-17718-const-mut.rs b/src/test/ui/parser/issue-17718-const-mut.rs
index f9b8d31..4e74516 100644
--- a/src/test/ui/parser/issue-17718-const-mut.rs
+++ b/src/test/ui/parser/issue-17718-const-mut.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 const
 mut //~ ERROR: const globals cannot be mutable
 //~^ HELP did you mean to declare a static?
diff --git a/src/test/ui/parser/issue-17718-const-mut.stderr b/src/test/ui/parser/issue-17718-const-mut.stderr
index d54a570..29a65eb 100644
--- a/src/test/ui/parser/issue-17718-const-mut.stderr
+++ b/src/test/ui/parser/issue-17718-const-mut.stderr
@@ -1,5 +1,5 @@
 error: const globals cannot be mutable
-  --> $DIR/issue-17718-const-mut.rs:4:1
+  --> $DIR/issue-17718-const-mut.rs:2:1
    |
 LL | mut //~ ERROR: const globals cannot be mutable
    | ^^^
diff --git a/src/test/ui/parser/issue-17904-2.rs b/src/test/ui/parser/issue-17904-2.rs
index 487abd3..d3f3225 100644
--- a/src/test/ui/parser/issue-17904-2.rs
+++ b/src/test/ui/parser/issue-17904-2.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct Bar<T> { x: T } where T: Copy //~ ERROR expected item, found keyword `where`
 
diff --git a/src/test/ui/parser/issue-17904.rs b/src/test/ui/parser/issue-17904.rs
index 2fe897e..6112623 100644
--- a/src/test/ui/parser/issue-17904.rs
+++ b/src/test/ui/parser/issue-17904.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct Baz<U> where U: Eq(U); //This is parsed as the new Fn* style parenthesis syntax.
 struct Baz<U> where U: Eq(U) -> R; // Notice this parses as well.
diff --git a/src/test/ui/parser/issue-1802-1.rs b/src/test/ui/parser/issue-1802-1.rs
index 207298c..050e9a2 100644
--- a/src/test/ui/parser/issue-1802-1.rs
+++ b/src/test/ui/parser/issue-1802-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:no valid digits found for number
 fn main() {
     log(error, 0b);
diff --git a/src/test/ui/parser/issue-1802-1.stderr b/src/test/ui/parser/issue-1802-1.stderr
index b7d003d..5cd6a4f 100644
--- a/src/test/ui/parser/issue-1802-1.stderr
+++ b/src/test/ui/parser/issue-1802-1.stderr
@@ -1,5 +1,5 @@
 error: no valid digits found for number
-  --> $DIR/issue-1802-1.rs:5:16
+  --> $DIR/issue-1802-1.rs:3:16
    |
 LL |     log(error, 0b);
    |                ^^
diff --git a/src/test/ui/parser/issue-1802-2.rs b/src/test/ui/parser/issue-1802-2.rs
index 28094ed..796db66 100644
--- a/src/test/ui/parser/issue-1802-2.rs
+++ b/src/test/ui/parser/issue-1802-2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:no valid digits found for number
 fn main() {
     log(error, 0b_usize);
diff --git a/src/test/ui/parser/issue-1802-2.stderr b/src/test/ui/parser/issue-1802-2.stderr
index e57871a..c6c0427 100644
--- a/src/test/ui/parser/issue-1802-2.stderr
+++ b/src/test/ui/parser/issue-1802-2.stderr
@@ -1,5 +1,5 @@
 error: no valid digits found for number
-  --> $DIR/issue-1802-2.rs:5:16
+  --> $DIR/issue-1802-2.rs:3:16
    |
 LL |     log(error, 0b_usize);
    |                ^^^
diff --git a/src/test/ui/parser/issue-19096.rs b/src/test/ui/parser/issue-19096.rs
index 8b68273..edc69e6 100644
--- a/src/test/ui/parser/issue-19096.rs
+++ b/src/test/ui/parser/issue-19096.rs
@@ -1,6 +1,5 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let t = (42, 42);
     t.0::<isize>; //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
+                  //~| ERROR mismatched types
 }
diff --git a/src/test/ui/parser/issue-19096.stderr b/src/test/ui/parser/issue-19096.stderr
index 922cfe0..f92604d 100644
--- a/src/test/ui/parser/issue-19096.stderr
+++ b/src/test/ui/parser/issue-19096.stderr
@@ -1,8 +1,21 @@
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
-  --> $DIR/issue-19096.rs:5:8
+  --> $DIR/issue-19096.rs:3:8
    |
 LL |     t.0::<isize>; //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
    |        ^^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to previous error
+error[E0308]: mismatched types
+  --> $DIR/issue-19096.rs:3:5
+   |
+LL | fn main() {
+   |           - expected `()` because of default return type
+LL |     let t = (42, 42);
+LL |     t.0::<isize>; //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `::`
+   |     ^^^ expected (), found integer
+   |
+   = note: expected type `()`
+              found type `{integer}`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/src/test/ui/parser/issue-19398.rs b/src/test/ui/parser/issue-19398.rs
index d31d31c..822f4a6 100644
--- a/src/test/ui/parser/issue-19398.rs
+++ b/src/test/ui/parser/issue-19398.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait T {
     extern "Rust" unsafe fn foo(); //~ ERROR expected `fn`, found `unsafe`
 }
diff --git a/src/test/ui/parser/issue-19398.stderr b/src/test/ui/parser/issue-19398.stderr
index b9eabf0..627b74f 100644
--- a/src/test/ui/parser/issue-19398.stderr
+++ b/src/test/ui/parser/issue-19398.stderr
@@ -1,5 +1,5 @@
 error: expected `fn`, found `unsafe`
-  --> $DIR/issue-19398.rs:4:19
+  --> $DIR/issue-19398.rs:2:19
    |
 LL |     extern "Rust" unsafe fn foo(); //~ ERROR expected `fn`, found `unsafe`
    |                   ^^^^^^ expected `fn` here
diff --git a/src/test/ui/parser/issue-20711-2.rs b/src/test/ui/parser/issue-20711-2.rs
index e9f26cb..49b8de0 100644
--- a/src/test/ui/parser/issue-20711-2.rs
+++ b/src/test/ui/parser/issue-20711-2.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 // ignore-tidy-linelength
 
 struct Foo;
diff --git a/src/test/ui/parser/issue-20711-2.stderr b/src/test/ui/parser/issue-20711-2.stderr
index a677a7e..e06eb7a 100644
--- a/src/test/ui/parser/issue-20711-2.stderr
+++ b/src/test/ui/parser/issue-20711-2.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `crate`, `default`, `existential`, `extern`, `fn`, `pub`, `type`, or `unsafe`, found `}`
-  --> $DIR/issue-20711-2.rs:10:1
+  --> $DIR/issue-20711-2.rs:9:1
    |
 LL |     #[stable(feature = "rust1", since = "1.0.0")]
    |                                                  - expected one of 10 possible tokens here
diff --git a/src/test/ui/parser/issue-20711.rs b/src/test/ui/parser/issue-20711.rs
index 5459847..8d8401d 100644
--- a/src/test/ui/parser/issue-20711.rs
+++ b/src/test/ui/parser/issue-20711.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 // ignore-tidy-linelength
 
 struct Foo;
diff --git a/src/test/ui/parser/issue-20711.stderr b/src/test/ui/parser/issue-20711.stderr
index da925b5..6cf3960 100644
--- a/src/test/ui/parser/issue-20711.stderr
+++ b/src/test/ui/parser/issue-20711.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `crate`, `default`, `existential`, `extern`, `fn`, `pub`, `type`, or `unsafe`, found `}`
-  --> $DIR/issue-20711.rs:8:1
+  --> $DIR/issue-20711.rs:7:1
    |
 LL |     #[stable(feature = "rust1", since = "1.0.0")]
    |                                                  - expected one of 10 possible tokens here
diff --git a/src/test/ui/parser/issue-21153.rs b/src/test/ui/parser/issue-21153.rs
index 13a5cc3..46cd45f 100644
--- a/src/test/ui/parser/issue-21153.rs
+++ b/src/test/ui/parser/issue-21153.rs
@@ -1,5 +1,5 @@
-// compile-flags: -Z parse-only
-
 trait MyTrait<T>: Iterator { //~ ERROR missing `fn`, `type`, or `const`
     Item = T;
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-21153.stderr b/src/test/ui/parser/issue-21153.stderr
index ae8b106..1e0244c 100644
--- a/src/test/ui/parser/issue-21153.stderr
+++ b/src/test/ui/parser/issue-21153.stderr
@@ -1,5 +1,5 @@
 error: missing `fn`, `type`, or `const` for trait-item declaration
-  --> $DIR/issue-21153.rs:3:29
+  --> $DIR/issue-21153.rs:1:29
    |
 LL |   trait MyTrait<T>: Iterator { //~ ERROR missing `fn`, `type`, or `const`
    |  _____________________________^
diff --git a/src/test/ui/parser/issue-22647.rs b/src/test/ui/parser/issue-22647.rs
index 3b9bad2..25cd7ff 100644
--- a/src/test/ui/parser/issue-22647.rs
+++ b/src/test/ui/parser/issue-22647.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let caller<F> = |f: F|  //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `<`
     where F: Fn() -> i32
diff --git a/src/test/ui/parser/issue-22647.stderr b/src/test/ui/parser/issue-22647.stderr
index e8ae163..8935ea9 100644
--- a/src/test/ui/parser/issue-22647.stderr
+++ b/src/test/ui/parser/issue-22647.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `<`
-  --> $DIR/issue-22647.rs:4:15
+  --> $DIR/issue-22647.rs:2:15
    |
 LL |     let caller<F> = |f: F|  //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `<`
    |               ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/issue-22712.rs b/src/test/ui/parser/issue-22712.rs
index a34b2b5..b03d578 100644
--- a/src/test/ui/parser/issue-22712.rs
+++ b/src/test/ui/parser/issue-22712.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo<B> {
     buffer: B
 }
diff --git a/src/test/ui/parser/issue-22712.stderr b/src/test/ui/parser/issue-22712.stderr
index b668e49..3a4fa9a 100644
--- a/src/test/ui/parser/issue-22712.stderr
+++ b/src/test/ui/parser/issue-22712.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `<`
-  --> $DIR/issue-22712.rs:8:12
+  --> $DIR/issue-22712.rs:6:12
    |
 LL |     let Foo<Vec<u8>>  //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `<`
    |            ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/issue-2354-1.rs b/src/test/ui/parser/issue-2354-1.rs
index 50e166c..7e4e24f 100644
--- a/src/test/ui/parser/issue-2354-1.rs
+++ b/src/test/ui/parser/issue-2354-1.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 static foo: isize = 2; } //~ ERROR unexpected close delimiter:
diff --git a/src/test/ui/parser/issue-2354-1.stderr b/src/test/ui/parser/issue-2354-1.stderr
index 6ca5ff7..da25aac 100644
--- a/src/test/ui/parser/issue-2354-1.stderr
+++ b/src/test/ui/parser/issue-2354-1.stderr
@@ -1,5 +1,5 @@
 error: unexpected close delimiter: `}`
-  --> $DIR/issue-2354-1.rs:3:24
+  --> $DIR/issue-2354-1.rs:1:24
    |
 LL | static foo: isize = 2; } //~ ERROR unexpected close delimiter:
    |                        ^ unexpected close delimiter
diff --git a/src/test/ui/parser/issue-2354.rs b/src/test/ui/parser/issue-2354.rs
index 19308e1..565f848 100644
--- a/src/test/ui/parser/issue-2354.rs
+++ b/src/test/ui/parser/issue-2354.rs
@@ -1,7 +1,5 @@
-// compile-flags: -Z parse-only
-
 fn foo() { //~ NOTE un-closed delimiter
-  match Some(x) {
+  match Some(10) {
   //~^ NOTE this delimiter might not be properly closed...
       Some(y) => { panic!(); }
       None => { panic!(); }
@@ -13,4 +11,5 @@
     while (i < 1000) {}
 }
 
-fn main() {} //~ ERROR this file contains an un-closed delimiter
+fn main() {} //~ NOTE here is a function named 'main'
+             //~ ERROR this file contains an un-closed delimiter
diff --git a/src/test/ui/parser/issue-2354.stderr b/src/test/ui/parser/issue-2354.stderr
index a416968..0f4cd57 100644
--- a/src/test/ui/parser/issue-2354.stderr
+++ b/src/test/ui/parser/issue-2354.stderr
@@ -1,16 +1,26 @@
 error: this file contains an un-closed delimiter
-  --> $DIR/issue-2354.rs:16:66
+  --> $DIR/issue-2354.rs:15:66
    |
 LL | fn foo() { //~ NOTE un-closed delimiter
    |          - un-closed delimiter
-LL |   match Some(x) {
-   |                 - this delimiter might not be properly closed...
+LL |   match Some(10) {
+   |                  - this delimiter might not be properly closed...
 ...
 LL | }
    | - ...as it matches this but it has different indentation
 ...
-LL | fn main() {} //~ ERROR this file contains an un-closed delimiter
+LL |              //~ ERROR this file contains an un-closed delimiter
    |                                                                  ^
 
-error: aborting due to previous error
+error[E0601]: `main` function not found in crate `issue_2354`
+   |
+   = note: the main function must be defined at the crate level but you have one or more functions named 'main' that are not defined at the crate level. Either move the definition or attach the `#[main]` attribute to override this behavior.
+note: here is a function named 'main'
+  --> $DIR/issue-2354.rs:14:1
+   |
+LL | fn main() {} //~ NOTE here is a function named 'main'
+   | ^^^^^^^^^^^^
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0601`.
diff --git a/src/test/ui/parser/issue-23620-invalid-escapes.rs b/src/test/ui/parser/issue-23620-invalid-escapes.rs
index f8a2f1c..b4b8f1f 100644
--- a/src/test/ui/parser/issue-23620-invalid-escapes.rs
+++ b/src/test/ui/parser/issue-23620-invalid-escapes.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     let _ = b"\u{a66e}";
diff --git a/src/test/ui/parser/issue-24197.rs b/src/test/ui/parser/issue-24197.rs
index a5c2c0c..005ff9f 100644
--- a/src/test/ui/parser/issue-24197.rs
+++ b/src/test/ui/parser/issue-24197.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let buf[0] = 0; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `[`
 }
diff --git a/src/test/ui/parser/issue-24197.stderr b/src/test/ui/parser/issue-24197.stderr
index 0f684ca..4e073d8 100644
--- a/src/test/ui/parser/issue-24197.stderr
+++ b/src/test/ui/parser/issue-24197.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `[`
-  --> $DIR/issue-24197.rs:4:12
+  --> $DIR/issue-24197.rs:2:12
    |
 LL |     let buf[0] = 0; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `[`
    |            ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/issue-24375.rs b/src/test/ui/parser/issue-24375.rs
index f8b5a64..1d128d3 100644
--- a/src/test/ui/parser/issue-24375.rs
+++ b/src/test/ui/parser/issue-24375.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 static tmp : [&'static str; 2]  = ["hello", "he"];
 
 fn main() {
diff --git a/src/test/ui/parser/issue-24375.stderr b/src/test/ui/parser/issue-24375.stderr
index 5a0244b..f773a7d 100644
--- a/src/test/ui/parser/issue-24375.stderr
+++ b/src/test/ui/parser/issue-24375.stderr
@@ -1,5 +1,5 @@
 error: expected one of `=>`, `@`, `if`, or `|`, found `[`
-  --> $DIR/issue-24375.rs:8:12
+  --> $DIR/issue-24375.rs:6:12
    |
 LL |         tmp[0] => {} //~ ERROR expected one of `=>`, `@`, `if`, or `|`, found `[`
    |            ^ expected one of `=>`, `@`, `if`, or `|` here
diff --git a/src/test/ui/parser/issue-24780.rs b/src/test/ui/parser/issue-24780.rs
index 58500ff..799cdd8 100644
--- a/src/test/ui/parser/issue-24780.rs
+++ b/src/test/ui/parser/issue-24780.rs
@@ -1,8 +1,6 @@
 // Verify that '>' is not both expected and found at the same time, as it used
 // to happen in #24780. For example, following should be an error:
 // expected one of ..., `>`, ... found `>`
-//
-// compile-flags: -Z parse-only
 
 fn foo() -> Vec<usize>> {
     //~^ ERROR expected one of `!`, `+`, `::`, `where`, or `{`, found `>`
diff --git a/src/test/ui/parser/issue-24780.stderr b/src/test/ui/parser/issue-24780.stderr
index b3e1a96..469c034 100644
--- a/src/test/ui/parser/issue-24780.stderr
+++ b/src/test/ui/parser/issue-24780.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `+`, `::`, `where`, or `{`, found `>`
-  --> $DIR/issue-24780.rs:7:23
+  --> $DIR/issue-24780.rs:5:23
    |
 LL | fn foo() -> Vec<usize>> {
    |                       ^ expected one of `!`, `+`, `::`, `where`, or `{` here
diff --git a/src/test/ui/parser/issue-27255.rs b/src/test/ui/parser/issue-27255.rs
index 08674c7..c0ff331 100644
--- a/src/test/ui/parser/issue-27255.rs
+++ b/src/test/ui/parser/issue-27255.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 impl A .. {} //~ ERROR
 
 fn main() {}
diff --git a/src/test/ui/parser/issue-27255.stderr b/src/test/ui/parser/issue-27255.stderr
index 2ad0bbf..6d09d82 100644
--- a/src/test/ui/parser/issue-27255.stderr
+++ b/src/test/ui/parser/issue-27255.stderr
@@ -1,5 +1,5 @@
 error: missing `for` in a trait impl
-  --> $DIR/issue-27255.rs:3:7
+  --> $DIR/issue-27255.rs:1:7
    |
 LL | impl A .. {} //~ ERROR
    |       ^
diff --git a/src/test/ui/parser/issue-30318.rs b/src/test/ui/parser/issue-30318.rs
index 5a44b3f..38e30de 100644
--- a/src/test/ui/parser/issue-30318.rs
+++ b/src/test/ui/parser/issue-30318.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn foo() { }
 
 //! Misplaced comment...
diff --git a/src/test/ui/parser/issue-30318.stderr b/src/test/ui/parser/issue-30318.stderr
index 6d46388..489451b 100644
--- a/src/test/ui/parser/issue-30318.stderr
+++ b/src/test/ui/parser/issue-30318.stderr
@@ -1,5 +1,5 @@
 error: expected outer doc comment
-  --> $DIR/issue-30318.rs:5:1
+  --> $DIR/issue-30318.rs:3:1
    |
 LL | //! Misplaced comment...
    | ^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/issue-3036.rs b/src/test/ui/parser/issue-3036.rs
index 66f4b5f..00b241b 100644
--- a/src/test/ui/parser/issue-3036.rs
+++ b/src/test/ui/parser/issue-3036.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Testing that semicolon tokens are printed correctly in errors
 
 fn main()
diff --git a/src/test/ui/parser/issue-3036.stderr b/src/test/ui/parser/issue-3036.stderr
index 41905b0..eadf554 100644
--- a/src/test/ui/parser/issue-3036.stderr
+++ b/src/test/ui/parser/issue-3036.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `;`, `?`, or an operator, found `}`
-  --> $DIR/issue-3036.rs:8:1
+  --> $DIR/issue-3036.rs:6:1
    |
 LL |     let x = 3
    |              - expected one of `.`, `;`, `?`, or an operator here
diff --git a/src/test/ui/parser/issue-32214.rs b/src/test/ui/parser/issue-32214.rs
index 2ca1699..7e55bc0 100644
--- a/src/test/ui/parser/issue-32214.rs
+++ b/src/test/ui/parser/issue-32214.rs
@@ -1,6 +1,8 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
-pub fn test<W, I: Iterator<Item=(), W> >() {}
+trait Trait<T> { type Item; }
+
+pub fn test<W, I: Trait<Item=(), W> >() {}
 //~^ ERROR type parameters must be declared prior to associated type bindings
 
 fn main() { }
diff --git a/src/test/ui/parser/issue-32214.stderr b/src/test/ui/parser/issue-32214.stderr
index 96677be8..a01517d 100644
--- a/src/test/ui/parser/issue-32214.stderr
+++ b/src/test/ui/parser/issue-32214.stderr
@@ -1,8 +1,8 @@
 error: type parameters must be declared prior to associated type bindings
-  --> $DIR/issue-32214.rs:3:37
+  --> $DIR/issue-32214.rs:5:34
    |
-LL | pub fn test<W, I: Iterator<Item=(), W> >() {}
-   |                                     ^
+LL | pub fn test<W, I: Trait<Item=(), W> >() {}
+   |                                  ^
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/parser/issue-32446.rs b/src/test/ui/parser/issue-32446.rs
index 264ea35..53e519a 100644
--- a/src/test/ui/parser/issue-32446.rs
+++ b/src/test/ui/parser/issue-32446.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {}
 
 // This used to end up in an infite loop trying to bump past EOF.
diff --git a/src/test/ui/parser/issue-32446.stderr b/src/test/ui/parser/issue-32446.stderr
index 931bef3..07eafdd 100644
--- a/src/test/ui/parser/issue-32446.stderr
+++ b/src/test/ui/parser/issue-32446.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `...`
-  --> $DIR/issue-32446.rs:6:11
+  --> $DIR/issue-32446.rs:4:11
    |
 LL | trait T { ... } //~ ERROR
    |           ^^^ expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/issue-32501.rs b/src/test/ui/parser/issue-32501.rs
index 40ed028..9c01a5c 100644
--- a/src/test/ui/parser/issue-32501.rs
+++ b/src/test/ui/parser/issue-32501.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let a = 0;
     let _b = 0;
diff --git a/src/test/ui/parser/issue-32501.stderr b/src/test/ui/parser/issue-32501.stderr
index f03be3d..d74c539 100644
--- a/src/test/ui/parser/issue-32501.stderr
+++ b/src/test/ui/parser/issue-32501.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found reserved identifier `_`
-  --> $DIR/issue-32501.rs:9:13
+  --> $DIR/issue-32501.rs:7:13
    |
 LL |     let mut _ = 0; //~ ERROR expected identifier, found reserved identifier `_`
    |             ^ expected identifier, found reserved identifier
diff --git a/src/test/ui/parser/issue-32505.rs b/src/test/ui/parser/issue-32505.rs
index 94fe70d..49e7a2f 100644
--- a/src/test/ui/parser/issue-32505.rs
+++ b/src/test/ui/parser/issue-32505.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 pub fn test() {
     foo(|_|) //~ ERROR expected expression, found `)`
diff --git a/src/test/ui/parser/issue-33262.rs b/src/test/ui/parser/issue-33262.rs
index 72c75ce..3a612f9 100644
--- a/src/test/ui/parser/issue-33262.rs
+++ b/src/test/ui/parser/issue-33262.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Issue #33262
 
 pub fn main() {
diff --git a/src/test/ui/parser/issue-33262.stderr b/src/test/ui/parser/issue-33262.stderr
index 11cdf62..c2491df 100644
--- a/src/test/ui/parser/issue-33262.stderr
+++ b/src/test/ui/parser/issue-33262.stderr
@@ -1,5 +1,5 @@
 error: expected type, found `{`
-  --> $DIR/issue-33262.rs:6:22
+  --> $DIR/issue-33262.rs:4:22
    |
 LL |     for i in 0..a as { }
    |                      ^
diff --git a/src/test/ui/parser/issue-33413.rs b/src/test/ui/parser/issue-33413.rs
index a25c7d2..2ec8695 100644
--- a/src/test/ui/parser/issue-33413.rs
+++ b/src/test/ui/parser/issue-33413.rs
@@ -1,6 +1,8 @@
-// compile-flags: -Z parse-only
+struct S;
 
 impl S {
     fn f(*, a: u8) -> u8 {}
     //~^ ERROR expected argument name, found `*`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/issue-33455.rs b/src/test/ui/parser/issue-33455.rs
index 162bd8e..6dff63f 100644
--- a/src/test/ui/parser/issue-33455.rs
+++ b/src/test/ui/parser/issue-33455.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 use foo.bar; //~ ERROR expected one of `::`, `;`, or `as`, found `.`
diff --git a/src/test/ui/parser/issue-33455.stderr b/src/test/ui/parser/issue-33455.stderr
index 70d48f8..38d00a0 100644
--- a/src/test/ui/parser/issue-33455.stderr
+++ b/src/test/ui/parser/issue-33455.stderr
@@ -1,5 +1,5 @@
 error: expected one of `::`, `;`, or `as`, found `.`
-  --> $DIR/issue-33455.rs:3:8
+  --> $DIR/issue-33455.rs:1:8
    |
 LL | use foo.bar; //~ ERROR expected one of `::`, `;`, or `as`, found `.`
    |        ^ expected one of `::`, `;`, or `as` here
diff --git a/src/test/ui/parser/issue-41155.rs b/src/test/ui/parser/issue-41155.rs
index 2f6202e..3c24d2b 100644
--- a/src/test/ui/parser/issue-41155.rs
+++ b/src/test/ui/parser/issue-41155.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
+struct S;
 
 impl S {
     pub
diff --git a/src/test/ui/parser/issue-43692.rs b/src/test/ui/parser/issue-43692.rs
index c34f55ec..baf8baf 100644
--- a/src/test/ui/parser/issue-43692.rs
+++ b/src/test/ui/parser/issue-43692.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     '\u{_10FFFF}'; //~ ERROR invalid start of unicode escape
 }
diff --git a/src/test/ui/parser/issue-43692.stderr b/src/test/ui/parser/issue-43692.stderr
index f92f6a1..780f63a 100644
--- a/src/test/ui/parser/issue-43692.stderr
+++ b/src/test/ui/parser/issue-43692.stderr
@@ -1,5 +1,5 @@
 error: invalid start of unicode escape
-  --> $DIR/issue-43692.rs:4:9
+  --> $DIR/issue-43692.rs:2:9
    |
 LL |     '/u{_10FFFF}'; //~ ERROR invalid start of unicode escape
    |         ^
diff --git a/src/test/ui/parser/issue-5544-a.rs b/src/test/ui/parser/issue-5544-a.rs
index 72cc222..303b902 100644
--- a/src/test/ui/parser/issue-5544-a.rs
+++ b/src/test/ui/parser/issue-5544-a.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let __isize = 340282366920938463463374607431768211456; // 2^128
     //~^ ERROR int literal is too large
diff --git a/src/test/ui/parser/issue-5544-a.stderr b/src/test/ui/parser/issue-5544-a.stderr
index cd52da8..bc48853 100644
--- a/src/test/ui/parser/issue-5544-a.stderr
+++ b/src/test/ui/parser/issue-5544-a.stderr
@@ -1,5 +1,5 @@
 error: int literal is too large
-  --> $DIR/issue-5544-a.rs:4:19
+  --> $DIR/issue-5544-a.rs:2:19
    |
 LL |     let __isize = 340282366920938463463374607431768211456; // 2^128
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/issue-5544-b.rs b/src/test/ui/parser/issue-5544-b.rs
index 9c87b61..fa40f15 100644
--- a/src/test/ui/parser/issue-5544-b.rs
+++ b/src/test/ui/parser/issue-5544-b.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let __isize = 0xffff_ffff_ffff_ffff_ffff_ffff_ffff_ffff_ff;
     //~^ ERROR int literal is too large
diff --git a/src/test/ui/parser/issue-5544-b.stderr b/src/test/ui/parser/issue-5544-b.stderr
index 835887f..3f15c0c 100644
--- a/src/test/ui/parser/issue-5544-b.stderr
+++ b/src/test/ui/parser/issue-5544-b.stderr
@@ -1,5 +1,5 @@
 error: int literal is too large
-  --> $DIR/issue-5544-b.rs:4:19
+  --> $DIR/issue-5544-b.rs:2:19
    |
 LL |     let __isize = 0xffff_ffff_ffff_ffff_ffff_ffff_ffff_ffff_ff;
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/issue-5806.rs b/src/test/ui/parser/issue-5806.rs
index 298247e..b694642 100644
--- a/src/test/ui/parser/issue-5806.rs
+++ b/src/test/ui/parser/issue-5806.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 // normalize-stderr-test: "parser:.*\(" -> "parser: $$ACCESS_DENIED_MSG ("
 // normalize-stderr-test: "os error \d+" -> "os error $$ACCESS_DENIED_CODE"
 
diff --git a/src/test/ui/parser/issue-5806.stderr b/src/test/ui/parser/issue-5806.stderr
index 5c67bba..f9f00f7 100644
--- a/src/test/ui/parser/issue-5806.stderr
+++ b/src/test/ui/parser/issue-5806.stderr
@@ -1,5 +1,5 @@
 error: couldn't read $DIR/../parser: $ACCESS_DENIED_MSG (os error $ACCESS_DENIED_CODE)
-  --> $DIR/issue-5806.rs:6:5
+  --> $DIR/issue-5806.rs:5:5
    |
 LL | mod foo; //~ ERROR couldn't read
    |     ^^^
diff --git a/src/test/ui/parser/issue-6610.rs b/src/test/ui/parser/issue-6610.rs
index d2e4d38..2dfa08f 100644
--- a/src/test/ui/parser/issue-6610.rs
+++ b/src/test/ui/parser/issue-6610.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait Foo { fn a() } //~ ERROR expected `;` or `{`, found `}`
 
 fn main() {}
diff --git a/src/test/ui/parser/issue-6610.stderr b/src/test/ui/parser/issue-6610.stderr
index 5814e80..b476016 100644
--- a/src/test/ui/parser/issue-6610.stderr
+++ b/src/test/ui/parser/issue-6610.stderr
@@ -1,5 +1,5 @@
 error: expected `;` or `{`, found `}`
-  --> $DIR/issue-6610.rs:3:20
+  --> $DIR/issue-6610.rs:1:20
    |
 LL | trait Foo { fn a() } //~ ERROR expected `;` or `{`, found `}`
    |                    ^ expected `;` or `{`
diff --git a/src/test/ui/parser/issue-8537.rs b/src/test/ui/parser/issue-8537.rs
index 387cf99..9d0cbce 100644
--- a/src/test/ui/parser/issue-8537.rs
+++ b/src/test/ui/parser/issue-8537.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 pub extern
   "invalid-ab_isize" //~ ERROR invalid ABI
 fn foo() {}
diff --git a/src/test/ui/parser/issue-8537.stderr b/src/test/ui/parser/issue-8537.stderr
index 7b3d3b2..4442cd0 100644
--- a/src/test/ui/parser/issue-8537.stderr
+++ b/src/test/ui/parser/issue-8537.stderr
@@ -1,5 +1,5 @@
 error[E0703]: invalid ABI: found `invalid-ab_isize`
-  --> $DIR/issue-8537.rs:4:3
+  --> $DIR/issue-8537.rs:2:3
    |
 LL |   "invalid-ab_isize" //~ ERROR invalid ABI
    |   ^^^^^^^^^^^^^^^^^^ invalid ABI
diff --git a/src/test/ui/parser/keyword-abstract.rs b/src/test/ui/parser/keyword-abstract.rs
index 14f92ee..890802a 100644
--- a/src/test/ui/parser/keyword-abstract.rs
+++ b/src/test/ui/parser/keyword-abstract.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let abstract = (); //~ ERROR expected pattern, found reserved keyword `abstract`
 }
diff --git a/src/test/ui/parser/keyword-abstract.stderr b/src/test/ui/parser/keyword-abstract.stderr
index 3f94b31..4185ae0 100644
--- a/src/test/ui/parser/keyword-abstract.stderr
+++ b/src/test/ui/parser/keyword-abstract.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found reserved keyword `abstract`
-  --> $DIR/keyword-abstract.rs:4:9
+  --> $DIR/keyword-abstract.rs:2:9
    |
 LL |     let abstract = (); //~ ERROR expected pattern, found reserved keyword `abstract`
    |         ^^^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-as-as-identifier.rs b/src/test/ui/parser/keyword-as-as-identifier.rs
index d2a38a4..23ff259 100644
--- a/src/test/ui/parser/keyword-as-as-identifier.rs
+++ b/src/test/ui/parser/keyword-as-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py as'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-as-as-identifier.stderr b/src/test/ui/parser/keyword-as-as-identifier.stderr
index c14dfc4..6eaf5e2 100644
--- a/src/test/ui/parser/keyword-as-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-as-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `as`
-  --> $DIR/keyword-as-as-identifier.rs:6:9
+  --> $DIR/keyword-as-as-identifier.rs:4:9
    |
 LL |     let as = "foo"; //~ error: expected pattern, found keyword `as`
    |         ^^ expected pattern
diff --git a/src/test/ui/parser/keyword-box-as-identifier.rs b/src/test/ui/parser/keyword-box-as-identifier.rs
index acbd4a8..33961bb 100644
--- a/src/test/ui/parser/keyword-box-as-identifier.rs
+++ b/src/test/ui/parser/keyword-box-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let box = "foo"; //~ error: expected pattern, found `=`
 }
diff --git a/src/test/ui/parser/keyword-box-as-identifier.stderr b/src/test/ui/parser/keyword-box-as-identifier.stderr
index 5e1ad39..07a1344 100644
--- a/src/test/ui/parser/keyword-box-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-box-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found `=`
-  --> $DIR/keyword-box-as-identifier.rs:4:13
+  --> $DIR/keyword-box-as-identifier.rs:2:13
    |
 LL |     let box = "foo"; //~ error: expected pattern, found `=`
    |             ^ expected pattern
diff --git a/src/test/ui/parser/keyword-break-as-identifier.rs b/src/test/ui/parser/keyword-break-as-identifier.rs
index 02affe0..5ee111d 100644
--- a/src/test/ui/parser/keyword-break-as-identifier.rs
+++ b/src/test/ui/parser/keyword-break-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py break'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-break-as-identifier.stderr b/src/test/ui/parser/keyword-break-as-identifier.stderr
index 6e17e34..69af973 100644
--- a/src/test/ui/parser/keyword-break-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-break-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `break`
-  --> $DIR/keyword-break-as-identifier.rs:6:9
+  --> $DIR/keyword-break-as-identifier.rs:4:9
    |
 LL |     let break = "foo"; //~ error: expected pattern, found keyword `break`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-const-as-identifier.rs b/src/test/ui/parser/keyword-const-as-identifier.rs
index cd86858..48fc142 100644
--- a/src/test/ui/parser/keyword-const-as-identifier.rs
+++ b/src/test/ui/parser/keyword-const-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py const'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-const-as-identifier.stderr b/src/test/ui/parser/keyword-const-as-identifier.stderr
index c3a4238..c727f17 100644
--- a/src/test/ui/parser/keyword-const-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-const-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `const`
-  --> $DIR/keyword-const-as-identifier.rs:6:9
+  --> $DIR/keyword-const-as-identifier.rs:4:9
    |
 LL |     let const = "foo"; //~ error: expected pattern, found keyword `const`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-continue-as-identifier.rs b/src/test/ui/parser/keyword-continue-as-identifier.rs
index 58683a3..06315a4 100644
--- a/src/test/ui/parser/keyword-continue-as-identifier.rs
+++ b/src/test/ui/parser/keyword-continue-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py continue'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-continue-as-identifier.stderr b/src/test/ui/parser/keyword-continue-as-identifier.stderr
index d26e524..7fd2761 100644
--- a/src/test/ui/parser/keyword-continue-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-continue-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `continue`
-  --> $DIR/keyword-continue-as-identifier.rs:6:9
+  --> $DIR/keyword-continue-as-identifier.rs:4:9
    |
 LL |     let continue = "foo"; //~ error: expected pattern, found keyword `continue`
    |         ^^^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-else-as-identifier.rs b/src/test/ui/parser/keyword-else-as-identifier.rs
index 61e64c7..0c69105 100644
--- a/src/test/ui/parser/keyword-else-as-identifier.rs
+++ b/src/test/ui/parser/keyword-else-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py else'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-else-as-identifier.stderr b/src/test/ui/parser/keyword-else-as-identifier.stderr
index cdb8cb7..6d180bb 100644
--- a/src/test/ui/parser/keyword-else-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-else-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `else`
-  --> $DIR/keyword-else-as-identifier.rs:6:9
+  --> $DIR/keyword-else-as-identifier.rs:4:9
    |
 LL |     let else = "foo"; //~ error: expected pattern, found keyword `else`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-enum-as-identifier.rs b/src/test/ui/parser/keyword-enum-as-identifier.rs
index 2fb1a6d..d167580 100644
--- a/src/test/ui/parser/keyword-enum-as-identifier.rs
+++ b/src/test/ui/parser/keyword-enum-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py enum'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-enum-as-identifier.stderr b/src/test/ui/parser/keyword-enum-as-identifier.stderr
index 3c247f7..dc7e378 100644
--- a/src/test/ui/parser/keyword-enum-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-enum-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `enum`
-  --> $DIR/keyword-enum-as-identifier.rs:6:9
+  --> $DIR/keyword-enum-as-identifier.rs:4:9
    |
 LL |     let enum = "foo"; //~ error: expected pattern, found keyword `enum`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-final.rs b/src/test/ui/parser/keyword-final.rs
index 7350f5a..e1cecd0 100644
--- a/src/test/ui/parser/keyword-final.rs
+++ b/src/test/ui/parser/keyword-final.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let final = (); //~ ERROR expected pattern, found reserved keyword `final`
 }
diff --git a/src/test/ui/parser/keyword-final.stderr b/src/test/ui/parser/keyword-final.stderr
index ab85d73..8976242 100644
--- a/src/test/ui/parser/keyword-final.stderr
+++ b/src/test/ui/parser/keyword-final.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found reserved keyword `final`
-  --> $DIR/keyword-final.rs:4:9
+  --> $DIR/keyword-final.rs:2:9
    |
 LL |     let final = (); //~ ERROR expected pattern, found reserved keyword `final`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-fn-as-identifier.rs b/src/test/ui/parser/keyword-fn-as-identifier.rs
index dfeb444..bca2d59 100644
--- a/src/test/ui/parser/keyword-fn-as-identifier.rs
+++ b/src/test/ui/parser/keyword-fn-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py fn'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-fn-as-identifier.stderr b/src/test/ui/parser/keyword-fn-as-identifier.stderr
index c1297ca..945fc77 100644
--- a/src/test/ui/parser/keyword-fn-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-fn-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `fn`
-  --> $DIR/keyword-fn-as-identifier.rs:6:9
+  --> $DIR/keyword-fn-as-identifier.rs:4:9
    |
 LL |     let fn = "foo"; //~ error: expected pattern, found keyword `fn`
    |         ^^ expected pattern
diff --git a/src/test/ui/parser/keyword-for-as-identifier.rs b/src/test/ui/parser/keyword-for-as-identifier.rs
index 806156f..ce49fd9 100644
--- a/src/test/ui/parser/keyword-for-as-identifier.rs
+++ b/src/test/ui/parser/keyword-for-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py for'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-for-as-identifier.stderr b/src/test/ui/parser/keyword-for-as-identifier.stderr
index ae081dc..32263e9 100644
--- a/src/test/ui/parser/keyword-for-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-for-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `for`
-  --> $DIR/keyword-for-as-identifier.rs:6:9
+  --> $DIR/keyword-for-as-identifier.rs:4:9
    |
 LL |     let for = "foo"; //~ error: expected pattern, found keyword `for`
    |         ^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-if-as-identifier.rs b/src/test/ui/parser/keyword-if-as-identifier.rs
index d71b77f..a130297 100644
--- a/src/test/ui/parser/keyword-if-as-identifier.rs
+++ b/src/test/ui/parser/keyword-if-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py if'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-if-as-identifier.stderr b/src/test/ui/parser/keyword-if-as-identifier.stderr
index 7eaab12..11ba410 100644
--- a/src/test/ui/parser/keyword-if-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-if-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `if`
-  --> $DIR/keyword-if-as-identifier.rs:6:9
+  --> $DIR/keyword-if-as-identifier.rs:4:9
    |
 LL |     let if = "foo"; //~ error: expected pattern, found keyword `if`
    |         ^^ expected pattern
diff --git a/src/test/ui/parser/keyword-impl-as-identifier.rs b/src/test/ui/parser/keyword-impl-as-identifier.rs
index a151b08..95a3448 100644
--- a/src/test/ui/parser/keyword-impl-as-identifier.rs
+++ b/src/test/ui/parser/keyword-impl-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py impl'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-impl-as-identifier.stderr b/src/test/ui/parser/keyword-impl-as-identifier.stderr
index 97442a2..960a42d 100644
--- a/src/test/ui/parser/keyword-impl-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-impl-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `impl`
-  --> $DIR/keyword-impl-as-identifier.rs:6:9
+  --> $DIR/keyword-impl-as-identifier.rs:4:9
    |
 LL |     let impl = "foo"; //~ error: expected pattern, found keyword `impl`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-in-as-identifier.rs b/src/test/ui/parser/keyword-in-as-identifier.rs
index 4cd0d88..e4499de 100644
--- a/src/test/ui/parser/keyword-in-as-identifier.rs
+++ b/src/test/ui/parser/keyword-in-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py in'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-in-as-identifier.stderr b/src/test/ui/parser/keyword-in-as-identifier.stderr
index c776aa4..2300a25 100644
--- a/src/test/ui/parser/keyword-in-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-in-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `in`
-  --> $DIR/keyword-in-as-identifier.rs:6:9
+  --> $DIR/keyword-in-as-identifier.rs:4:9
    |
 LL |     let in = "foo"; //~ error: expected pattern, found keyword `in`
    |         ^^ expected pattern
diff --git a/src/test/ui/parser/keyword-let-as-identifier.rs b/src/test/ui/parser/keyword-let-as-identifier.rs
index 690a6bd..07c0ddf 100644
--- a/src/test/ui/parser/keyword-let-as-identifier.rs
+++ b/src/test/ui/parser/keyword-let-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py let'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-let-as-identifier.stderr b/src/test/ui/parser/keyword-let-as-identifier.stderr
index 1c05bb8..ed2c8a4 100644
--- a/src/test/ui/parser/keyword-let-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-let-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `let`
-  --> $DIR/keyword-let-as-identifier.rs:6:9
+  --> $DIR/keyword-let-as-identifier.rs:4:9
    |
 LL |     let let = "foo"; //~ error: expected pattern, found keyword `let`
    |         ^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-loop-as-identifier.rs b/src/test/ui/parser/keyword-loop-as-identifier.rs
index 9be7373..8643ffe 100644
--- a/src/test/ui/parser/keyword-loop-as-identifier.rs
+++ b/src/test/ui/parser/keyword-loop-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py loop'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-loop-as-identifier.stderr b/src/test/ui/parser/keyword-loop-as-identifier.stderr
index 9168fbb..f91cab0 100644
--- a/src/test/ui/parser/keyword-loop-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-loop-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `loop`
-  --> $DIR/keyword-loop-as-identifier.rs:6:9
+  --> $DIR/keyword-loop-as-identifier.rs:4:9
    |
 LL |     let loop = "foo"; //~ error: expected pattern, found keyword `loop`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-match-as-identifier.rs b/src/test/ui/parser/keyword-match-as-identifier.rs
index 02a0d75..8ef6b68 100644
--- a/src/test/ui/parser/keyword-match-as-identifier.rs
+++ b/src/test/ui/parser/keyword-match-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py match'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-match-as-identifier.stderr b/src/test/ui/parser/keyword-match-as-identifier.stderr
index 5a3cc7f..4c8e766 100644
--- a/src/test/ui/parser/keyword-match-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-match-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `match`
-  --> $DIR/keyword-match-as-identifier.rs:6:9
+  --> $DIR/keyword-match-as-identifier.rs:4:9
    |
 LL |     let match = "foo"; //~ error: expected pattern, found keyword `match`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-mod-as-identifier.rs b/src/test/ui/parser/keyword-mod-as-identifier.rs
index 1f9ffc8..96bcdcc 100644
--- a/src/test/ui/parser/keyword-mod-as-identifier.rs
+++ b/src/test/ui/parser/keyword-mod-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py mod'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-mod-as-identifier.stderr b/src/test/ui/parser/keyword-mod-as-identifier.stderr
index 89b7319..8aeebce 100644
--- a/src/test/ui/parser/keyword-mod-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-mod-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `mod`
-  --> $DIR/keyword-mod-as-identifier.rs:6:9
+  --> $DIR/keyword-mod-as-identifier.rs:4:9
    |
 LL |     let mod = "foo"; //~ error: expected pattern, found keyword `mod`
    |         ^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-move-as-identifier.rs b/src/test/ui/parser/keyword-move-as-identifier.rs
index 7b7e350..2193af5 100644
--- a/src/test/ui/parser/keyword-move-as-identifier.rs
+++ b/src/test/ui/parser/keyword-move-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py move'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-move-as-identifier.stderr b/src/test/ui/parser/keyword-move-as-identifier.stderr
index daabace..37e0670 100644
--- a/src/test/ui/parser/keyword-move-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-move-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `move`
-  --> $DIR/keyword-move-as-identifier.rs:6:9
+  --> $DIR/keyword-move-as-identifier.rs:4:9
    |
 LL |     let move = "foo"; //~ error: expected pattern, found keyword `move`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-mut-as-identifier.rs b/src/test/ui/parser/keyword-mut-as-identifier.rs
index 41b86b0..9b919d2 100644
--- a/src/test/ui/parser/keyword-mut-as-identifier.rs
+++ b/src/test/ui/parser/keyword-mut-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let mut = "foo"; //~ error: expected identifier, found `=`
 }
diff --git a/src/test/ui/parser/keyword-mut-as-identifier.stderr b/src/test/ui/parser/keyword-mut-as-identifier.stderr
index c3a4525..b026606 100644
--- a/src/test/ui/parser/keyword-mut-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-mut-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `=`
-  --> $DIR/keyword-mut-as-identifier.rs:4:13
+  --> $DIR/keyword-mut-as-identifier.rs:2:13
    |
 LL |     let mut = "foo"; //~ error: expected identifier, found `=`
    |             ^ expected identifier
diff --git a/src/test/ui/parser/keyword-override.rs b/src/test/ui/parser/keyword-override.rs
index 423fbaf..948a200 100644
--- a/src/test/ui/parser/keyword-override.rs
+++ b/src/test/ui/parser/keyword-override.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let override = (); //~ ERROR expected pattern, found reserved keyword `override`
 }
diff --git a/src/test/ui/parser/keyword-override.stderr b/src/test/ui/parser/keyword-override.stderr
index 03e6b39..69a6415 100644
--- a/src/test/ui/parser/keyword-override.stderr
+++ b/src/test/ui/parser/keyword-override.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found reserved keyword `override`
-  --> $DIR/keyword-override.rs:4:9
+  --> $DIR/keyword-override.rs:2:9
    |
 LL |     let override = (); //~ ERROR expected pattern, found reserved keyword `override`
    |         ^^^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-pub-as-identifier.rs b/src/test/ui/parser/keyword-pub-as-identifier.rs
index 6e5d84c..2ed8cc6 100644
--- a/src/test/ui/parser/keyword-pub-as-identifier.rs
+++ b/src/test/ui/parser/keyword-pub-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py pub'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-pub-as-identifier.stderr b/src/test/ui/parser/keyword-pub-as-identifier.stderr
index 9353914..8b59567 100644
--- a/src/test/ui/parser/keyword-pub-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-pub-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `pub`
-  --> $DIR/keyword-pub-as-identifier.rs:6:9
+  --> $DIR/keyword-pub-as-identifier.rs:4:9
    |
 LL |     let pub = "foo"; //~ error: expected pattern, found keyword `pub`
    |         ^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-ref-as-identifier.rs b/src/test/ui/parser/keyword-ref-as-identifier.rs
index fc2a98a..f5e04b5 100644
--- a/src/test/ui/parser/keyword-ref-as-identifier.rs
+++ b/src/test/ui/parser/keyword-ref-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let ref = "foo"; //~ error: expected identifier, found `=`
 }
diff --git a/src/test/ui/parser/keyword-ref-as-identifier.stderr b/src/test/ui/parser/keyword-ref-as-identifier.stderr
index f5805bf..656df19 100644
--- a/src/test/ui/parser/keyword-ref-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-ref-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `=`
-  --> $DIR/keyword-ref-as-identifier.rs:4:13
+  --> $DIR/keyword-ref-as-identifier.rs:2:13
    |
 LL |     let ref = "foo"; //~ error: expected identifier, found `=`
    |             ^ expected identifier
diff --git a/src/test/ui/parser/keyword-return-as-identifier.rs b/src/test/ui/parser/keyword-return-as-identifier.rs
index e85e818..920931b 100644
--- a/src/test/ui/parser/keyword-return-as-identifier.rs
+++ b/src/test/ui/parser/keyword-return-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py return'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-return-as-identifier.stderr b/src/test/ui/parser/keyword-return-as-identifier.stderr
index f659632..9031375 100644
--- a/src/test/ui/parser/keyword-return-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-return-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `return`
-  --> $DIR/keyword-return-as-identifier.rs:6:9
+  --> $DIR/keyword-return-as-identifier.rs:4:9
    |
 LL |     let return = "foo"; //~ error: expected pattern, found keyword `return`
    |         ^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-static-as-identifier.rs b/src/test/ui/parser/keyword-static-as-identifier.rs
index ae55d30..3ccbfcc 100644
--- a/src/test/ui/parser/keyword-static-as-identifier.rs
+++ b/src/test/ui/parser/keyword-static-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py static'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-static-as-identifier.stderr b/src/test/ui/parser/keyword-static-as-identifier.stderr
index 23f4325..4830e6f 100644
--- a/src/test/ui/parser/keyword-static-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-static-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `static`
-  --> $DIR/keyword-static-as-identifier.rs:6:9
+  --> $DIR/keyword-static-as-identifier.rs:4:9
    |
 LL |     let static = "foo"; //~ error: expected pattern, found keyword `static`
    |         ^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-struct-as-identifier.rs b/src/test/ui/parser/keyword-struct-as-identifier.rs
index 593db01..69d8f19 100644
--- a/src/test/ui/parser/keyword-struct-as-identifier.rs
+++ b/src/test/ui/parser/keyword-struct-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py struct'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-struct-as-identifier.stderr b/src/test/ui/parser/keyword-struct-as-identifier.stderr
index a700116..50ac690 100644
--- a/src/test/ui/parser/keyword-struct-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-struct-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `struct`
-  --> $DIR/keyword-struct-as-identifier.rs:6:9
+  --> $DIR/keyword-struct-as-identifier.rs:4:9
    |
 LL |     let struct = "foo"; //~ error: expected pattern, found keyword `struct`
    |         ^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-trait-as-identifier.rs b/src/test/ui/parser/keyword-trait-as-identifier.rs
index c53cf2f..f628584 100644
--- a/src/test/ui/parser/keyword-trait-as-identifier.rs
+++ b/src/test/ui/parser/keyword-trait-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py trait'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-trait-as-identifier.stderr b/src/test/ui/parser/keyword-trait-as-identifier.stderr
index d96b465..3736f36 100644
--- a/src/test/ui/parser/keyword-trait-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-trait-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `trait`
-  --> $DIR/keyword-trait-as-identifier.rs:6:9
+  --> $DIR/keyword-trait-as-identifier.rs:4:9
    |
 LL |     let trait = "foo"; //~ error: expected pattern, found keyword `trait`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-try-as-identifier-edition2018.rs b/src/test/ui/parser/keyword-try-as-identifier-edition2018.rs
index a2782d4..13a938b 100644
--- a/src/test/ui/parser/keyword-try-as-identifier-edition2018.rs
+++ b/src/test/ui/parser/keyword-try-as-identifier-edition2018.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only --edition 2018
+// compile-flags: --edition 2018
 
 fn main() {
     let try = "foo"; //~ error: expected pattern, found reserved keyword `try`
diff --git a/src/test/ui/parser/keyword-type-as-identifier.rs b/src/test/ui/parser/keyword-type-as-identifier.rs
index 1639558..992547e 100644
--- a/src/test/ui/parser/keyword-type-as-identifier.rs
+++ b/src/test/ui/parser/keyword-type-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py type'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-type-as-identifier.stderr b/src/test/ui/parser/keyword-type-as-identifier.stderr
index 13ffbec..f7db200 100644
--- a/src/test/ui/parser/keyword-type-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-type-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `type`
-  --> $DIR/keyword-type-as-identifier.rs:6:9
+  --> $DIR/keyword-type-as-identifier.rs:4:9
    |
 LL |     let type = "foo"; //~ error: expected pattern, found keyword `type`
    |         ^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-typeof.rs b/src/test/ui/parser/keyword-typeof.rs
index 667caf1..4ef1026 100644
--- a/src/test/ui/parser/keyword-typeof.rs
+++ b/src/test/ui/parser/keyword-typeof.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let typeof = (); //~ ERROR expected pattern, found reserved keyword `typeof`
 }
diff --git a/src/test/ui/parser/keyword-typeof.stderr b/src/test/ui/parser/keyword-typeof.stderr
index feedd63..07c9f88 100644
--- a/src/test/ui/parser/keyword-typeof.stderr
+++ b/src/test/ui/parser/keyword-typeof.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found reserved keyword `typeof`
-  --> $DIR/keyword-typeof.rs:4:9
+  --> $DIR/keyword-typeof.rs:2:9
    |
 LL |     let typeof = (); //~ ERROR expected pattern, found reserved keyword `typeof`
    |         ^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-unsafe-as-identifier.rs b/src/test/ui/parser/keyword-unsafe-as-identifier.rs
index d3530a3..adb20eb 100644
--- a/src/test/ui/parser/keyword-unsafe-as-identifier.rs
+++ b/src/test/ui/parser/keyword-unsafe-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py unsafe'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-unsafe-as-identifier.stderr b/src/test/ui/parser/keyword-unsafe-as-identifier.stderr
index b7c0cfd..ddd5e4d 100644
--- a/src/test/ui/parser/keyword-unsafe-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-unsafe-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `unsafe`
-  --> $DIR/keyword-unsafe-as-identifier.rs:6:9
+  --> $DIR/keyword-unsafe-as-identifier.rs:4:9
    |
 LL |     let unsafe = "foo"; //~ error: expected pattern, found keyword `unsafe`
    |         ^^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-use-as-identifier.rs b/src/test/ui/parser/keyword-use-as-identifier.rs
index 08c69e4..198444b 100644
--- a/src/test/ui/parser/keyword-use-as-identifier.rs
+++ b/src/test/ui/parser/keyword-use-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py use'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-use-as-identifier.stderr b/src/test/ui/parser/keyword-use-as-identifier.stderr
index a2896ca..7e798a3 100644
--- a/src/test/ui/parser/keyword-use-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-use-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `use`
-  --> $DIR/keyword-use-as-identifier.rs:6:9
+  --> $DIR/keyword-use-as-identifier.rs:4:9
    |
 LL |     let use = "foo"; //~ error: expected pattern, found keyword `use`
    |         ^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-where-as-identifier.rs b/src/test/ui/parser/keyword-where-as-identifier.rs
index 8283cf5..5624a8f 100644
--- a/src/test/ui/parser/keyword-where-as-identifier.rs
+++ b/src/test/ui/parser/keyword-where-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py where'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-where-as-identifier.stderr b/src/test/ui/parser/keyword-where-as-identifier.stderr
index 3807084..5285520 100644
--- a/src/test/ui/parser/keyword-where-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-where-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `where`
-  --> $DIR/keyword-where-as-identifier.rs:6:9
+  --> $DIR/keyword-where-as-identifier.rs:4:9
    |
 LL |     let where = "foo"; //~ error: expected pattern, found keyword `where`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword-while-as-identifier.rs b/src/test/ui/parser/keyword-while-as-identifier.rs
index 7c70087..c0a539d 100644
--- a/src/test/ui/parser/keyword-while-as-identifier.rs
+++ b/src/test/ui/parser/keyword-while-as-identifier.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // This file was auto-generated using 'src/etc/generate-keyword-tests.py while'
 
 fn main() {
diff --git a/src/test/ui/parser/keyword-while-as-identifier.stderr b/src/test/ui/parser/keyword-while-as-identifier.stderr
index eac17de..b84a652 100644
--- a/src/test/ui/parser/keyword-while-as-identifier.stderr
+++ b/src/test/ui/parser/keyword-while-as-identifier.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found keyword `while`
-  --> $DIR/keyword-while-as-identifier.rs:6:9
+  --> $DIR/keyword-while-as-identifier.rs:4:9
    |
 LL |     let while = "foo"; //~ error: expected pattern, found keyword `while`
    |         ^^^^^ expected pattern
diff --git a/src/test/ui/parser/keyword.rs b/src/test/ui/parser/keyword.rs
index 92c05e5..1eb7886 100644
--- a/src/test/ui/parser/keyword.rs
+++ b/src/test/ui/parser/keyword.rs
@@ -1,5 +1,5 @@
-// compile-flags: -Z parse-only
-
 pub mod break {
     //~^ ERROR expected identifier, found keyword `break`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/keyword.stderr b/src/test/ui/parser/keyword.stderr
index 1c729ff..262467b 100644
--- a/src/test/ui/parser/keyword.stderr
+++ b/src/test/ui/parser/keyword.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found keyword `break`
-  --> $DIR/keyword.rs:3:9
+  --> $DIR/keyword.rs:1:9
    |
 LL | pub mod break {
    |         ^^^^^ expected identifier, found keyword
diff --git a/src/test/ui/parser/keywords-followed-by-double-colon.rs b/src/test/ui/parser/keywords-followed-by-double-colon.rs
index cdcfa74..5c7049f 100644
--- a/src/test/ui/parser/keywords-followed-by-double-colon.rs
+++ b/src/test/ui/parser/keywords-followed-by-double-colon.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     struct::foo();
     //~^ ERROR expected identifier
diff --git a/src/test/ui/parser/keywords-followed-by-double-colon.stderr b/src/test/ui/parser/keywords-followed-by-double-colon.stderr
index b4b7647..4c4d5e5d 100644
--- a/src/test/ui/parser/keywords-followed-by-double-colon.stderr
+++ b/src/test/ui/parser/keywords-followed-by-double-colon.stderr
@@ -1,11 +1,11 @@
 error: expected identifier, found `::`
-  --> $DIR/keywords-followed-by-double-colon.rs:4:11
+  --> $DIR/keywords-followed-by-double-colon.rs:2:11
    |
 LL |     struct::foo();
    |           ^^ expected identifier
 
 error: expected expression, found keyword `mut`
-  --> $DIR/keywords-followed-by-double-colon.rs:8:5
+  --> $DIR/keywords-followed-by-double-colon.rs:6:5
    |
 LL |     mut::baz();
    |     ^^^ expected expression
diff --git a/src/test/ui/parser/lex-bad-binary-literal.rs b/src/test/ui/parser/lex-bad-binary-literal.rs
index 316e739..da36537 100644
--- a/src/test/ui/parser/lex-bad-binary-literal.rs
+++ b/src/test/ui/parser/lex-bad-binary-literal.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     0b121; //~ ERROR invalid digit for a base 2 literal
diff --git a/src/test/ui/parser/lex-bad-char-literals-1.rs b/src/test/ui/parser/lex-bad-char-literals-1.rs
index 6620c9b..54d75ed 100644
--- a/src/test/ui/parser/lex-bad-char-literals-1.rs
+++ b/src/test/ui/parser/lex-bad-char-literals-1.rs
@@ -1,9 +1,9 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 static c3: char =
     '\x1' //~ ERROR: numeric character escape is too short
 ;
 
-static s: &'static str =
+static s3: &'static str =
     "\x1" //~ ERROR: numeric character escape is too short
 ;
 
@@ -15,3 +15,4 @@
     "\●" //~ ERROR: unknown character escape
 ;
 
+fn main() {}
diff --git a/src/test/ui/parser/lex-bad-char-literals-2.rs b/src/test/ui/parser/lex-bad-char-literals-2.rs
index 0579302..7f85999 100644
--- a/src/test/ui/parser/lex-bad-char-literals-2.rs
+++ b/src/test/ui/parser/lex-bad-char-literals-2.rs
@@ -1,7 +1,4 @@
-// compile-flags: -Z parse-only
-
 // This test needs to the last one appearing in this file as it kills the parser
 static c: char =
     'nope' //~ ERROR: character literal may only contain one codepoint: 'nope'
 ;
-
diff --git a/src/test/ui/parser/lex-bad-char-literals-2.stderr b/src/test/ui/parser/lex-bad-char-literals-2.stderr
index 99c7147..a7075b7 100644
--- a/src/test/ui/parser/lex-bad-char-literals-2.stderr
+++ b/src/test/ui/parser/lex-bad-char-literals-2.stderr
@@ -1,5 +1,5 @@
 error: character literal may only contain one codepoint: 'nope'
-  --> $DIR/lex-bad-char-literals-2.rs:5:5
+  --> $DIR/lex-bad-char-literals-2.rs:3:5
    |
 LL |     'nope' //~ ERROR: character literal may only contain one codepoint: 'nope'
    |     ^^^^^^
diff --git a/src/test/ui/parser/lex-bad-char-literals-3.rs b/src/test/ui/parser/lex-bad-char-literals-3.rs
index 0ea8290..f874970 100644
--- a/src/test/ui/parser/lex-bad-char-literals-3.rs
+++ b/src/test/ui/parser/lex-bad-char-literals-3.rs
@@ -1,6 +1,7 @@
-// compile-flags: -Z parse-only
-
 // This test needs to the last one appearing in this file as it kills the parser
 static c: char =
     '●●' //~ ERROR: character literal may only contain one codepoint
+         //~| ERROR: mismatched types
 ;
+
+fn main() {}
diff --git a/src/test/ui/parser/lex-bad-char-literals-3.stderr b/src/test/ui/parser/lex-bad-char-literals-3.stderr
index 7b96252..89f18e3 100644
--- a/src/test/ui/parser/lex-bad-char-literals-3.stderr
+++ b/src/test/ui/parser/lex-bad-char-literals-3.stderr
@@ -1,5 +1,5 @@
 error: character literal may only contain one codepoint
-  --> $DIR/lex-bad-char-literals-3.rs:5:5
+  --> $DIR/lex-bad-char-literals-3.rs:3:5
    |
 LL |     '●●' //~ ERROR: character literal may only contain one codepoint
    |     ^^^^
@@ -8,5 +8,15 @@
 LL |     "●●" //~ ERROR: character literal may only contain one codepoint
    |     ^^^^
 
-error: aborting due to previous error
+error[E0308]: mismatched types
+  --> $DIR/lex-bad-char-literals-3.rs:3:5
+   |
+LL |     '●●' //~ ERROR: character literal may only contain one codepoint
+   |     ^^^^ expected char, found reference
+   |
+   = note: expected type `char`
+              found type `&'static str`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/src/test/ui/parser/lex-bad-char-literals-4.rs b/src/test/ui/parser/lex-bad-char-literals-4.rs
index 8ac2d90..966e2bb 100644
--- a/src/test/ui/parser/lex-bad-char-literals-4.rs
+++ b/src/test/ui/parser/lex-bad-char-literals-4.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 //
 // This test needs to the last one appearing in this file as it kills the parser
 static c: char =
diff --git a/src/test/ui/parser/lex-bad-char-literals-4.stderr b/src/test/ui/parser/lex-bad-char-literals-4.stderr
index 7ad4001..550cb54 100644
--- a/src/test/ui/parser/lex-bad-char-literals-4.stderr
+++ b/src/test/ui/parser/lex-bad-char-literals-4.stderr
@@ -1,5 +1,5 @@
 error: character literal may only contain one codepoint: '●
-  --> $DIR/lex-bad-char-literals-4.rs:5:5
+  --> $DIR/lex-bad-char-literals-4.rs:4:5
    |
 LL |     '●  //~ ERROR: character literal may only contain one codepoint: '●
    |     ^^
diff --git a/src/test/ui/parser/lex-bad-char-literals-5.rs b/src/test/ui/parser/lex-bad-char-literals-5.rs
index 3c7bcf0..247289e 100644
--- a/src/test/ui/parser/lex-bad-char-literals-5.rs
+++ b/src/test/ui/parser/lex-bad-char-literals-5.rs
@@ -1,6 +1,8 @@
-// compile-flags: -Z parse-only
 //
 // This test needs to the last one appearing in this file as it kills the parser
 static c: char =
     '\x10\x10'  //~ ERROR: character literal may only contain one codepoint
+                //~| ERROR: mismatched types
 ;
+
+fn main() {}
diff --git a/src/test/ui/parser/lex-bad-char-literals-5.stderr b/src/test/ui/parser/lex-bad-char-literals-5.stderr
index 59acc48..523d71f 100644
--- a/src/test/ui/parser/lex-bad-char-literals-5.stderr
+++ b/src/test/ui/parser/lex-bad-char-literals-5.stderr
@@ -1,5 +1,5 @@
 error: character literal may only contain one codepoint
-  --> $DIR/lex-bad-char-literals-5.rs:5:5
+  --> $DIR/lex-bad-char-literals-5.rs:4:5
    |
 LL |     '/x10/x10'  //~ ERROR: character literal may only contain one codepoint
    |     ^^^^^^^^^^
@@ -8,5 +8,15 @@
 LL |     "/x10/x10"  //~ ERROR: character literal may only contain one codepoint
    |     ^^^^^^^^^^
 
-error: aborting due to previous error
+error[E0308]: mismatched types
+  --> $DIR/lex-bad-char-literals-5.rs:4:5
+   |
+LL |     '/x10/x10'  //~ ERROR: character literal may only contain one codepoint
+   |     ^^^^^^^^^^ expected char, found reference
+   |
+   = note: expected type `char`
+              found type `&'static str`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/src/test/ui/parser/lex-bad-numeric-literals.rs b/src/test/ui/parser/lex-bad-numeric-literals.rs
index f478c15..9496ad3 100644
--- a/src/test/ui/parser/lex-bad-numeric-literals.rs
+++ b/src/test/ui/parser/lex-bad-numeric-literals.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     0o1.0; //~ ERROR: octal float literal is not supported
diff --git a/src/test/ui/parser/lex-bad-octal-literal.rs b/src/test/ui/parser/lex-bad-octal-literal.rs
index 70f1aa4..f4cc2c5 100644
--- a/src/test/ui/parser/lex-bad-octal-literal.rs
+++ b/src/test/ui/parser/lex-bad-octal-literal.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     0o18; //~ ERROR invalid digit for a base 8 literal
diff --git a/src/test/ui/parser/lex-bad-token.rs b/src/test/ui/parser/lex-bad-token.rs
index 6bcc138..feb670c 100644
--- a/src/test/ui/parser/lex-bad-token.rs
+++ b/src/test/ui/parser/lex-bad-token.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 ● //~ ERROR: unknown start of token
diff --git a/src/test/ui/parser/lex-bad-token.stderr b/src/test/ui/parser/lex-bad-token.stderr
index 7476bf3..284ffde 100644
--- a/src/test/ui/parser/lex-bad-token.stderr
+++ b/src/test/ui/parser/lex-bad-token.stderr
@@ -1,5 +1,5 @@
 error: unknown start of token: /u{25cf}
-  --> $DIR/lex-bad-token.rs:3:1
+  --> $DIR/lex-bad-token.rs:1:1
    |
 LL | ● //~ ERROR: unknown start of token
    | ^
diff --git a/src/test/ui/parser/lex-bare-cr-string-literal-doc-comment.rs b/src/test/ui/parser/lex-bare-cr-string-literal-doc-comment.rs
index 21fbfe7..b588b00 100644
--- a/src/test/ui/parser/lex-bare-cr-string-literal-doc-comment.rs
+++ b/src/test/ui/parser/lex-bare-cr-string-literal-doc-comment.rs
Binary files differ
diff --git a/src/test/ui/parser/lex-stray-backslash.rs b/src/test/ui/parser/lex-stray-backslash.rs
index d6cccfa..90d3592 100644
--- a/src/test/ui/parser/lex-stray-backslash.rs
+++ b/src/test/ui/parser/lex-stray-backslash.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 \ //~ ERROR: unknown start of token: \
diff --git a/src/test/ui/parser/lex-stray-backslash.stderr b/src/test/ui/parser/lex-stray-backslash.stderr
index 0fd05d7..40e0cc1 100644
--- a/src/test/ui/parser/lex-stray-backslash.stderr
+++ b/src/test/ui/parser/lex-stray-backslash.stderr
@@ -1,5 +1,5 @@
 error: unknown start of token: /
-  --> $DIR/lex-stray-backslash.rs:3:1
+  --> $DIR/lex-stray-backslash.rs:1:1
    |
 LL | / //~ ERROR: unknown start of token: /
    | ^
diff --git a/src/test/ui/parser/lifetime-in-pattern.rs b/src/test/ui/parser/lifetime-in-pattern.rs
index 1535cfe..afee685 100644
--- a/src/test/ui/parser/lifetime-in-pattern.rs
+++ b/src/test/ui/parser/lifetime-in-pattern.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn test(&'a str) {
     //~^ ERROR unexpected lifetime `'a` in pattern
 }
diff --git a/src/test/ui/parser/lifetime-in-pattern.stderr b/src/test/ui/parser/lifetime-in-pattern.stderr
index 782b6c1..e525c7b 100644
--- a/src/test/ui/parser/lifetime-in-pattern.stderr
+++ b/src/test/ui/parser/lifetime-in-pattern.stderr
@@ -1,5 +1,5 @@
 error: unexpected lifetime `'a` in pattern
-  --> $DIR/lifetime-in-pattern.rs:3:10
+  --> $DIR/lifetime-in-pattern.rs:1:10
    |
 LL | fn test(&'a str) {
    |          ^^ unexpected lifetime
diff --git a/src/test/ui/parser/lifetime-semicolon.rs b/src/test/ui/parser/lifetime-semicolon.rs
index ede3eae..1f14721 100644
--- a/src/test/ui/parser/lifetime-semicolon.rs
+++ b/src/test/ui/parser/lifetime-semicolon.rs
@@ -1,8 +1,8 @@
-// compile-flags: -Z parse-only
-
 struct Foo<'a, 'b> {
     a: &'a &'b i32
 }
 
 fn foo<'a, 'b>(x: &mut Foo<'a; 'b>) {}
 //~^ ERROR expected one of `,` or `>`, found `;`
+
+fn main() {}
diff --git a/src/test/ui/parser/lifetime-semicolon.stderr b/src/test/ui/parser/lifetime-semicolon.stderr
index acc5e92..71ed820 100644
--- a/src/test/ui/parser/lifetime-semicolon.stderr
+++ b/src/test/ui/parser/lifetime-semicolon.stderr
@@ -1,5 +1,5 @@
 error: expected one of `,` or `>`, found `;`
-  --> $DIR/lifetime-semicolon.rs:7:30
+  --> $DIR/lifetime-semicolon.rs:5:30
    |
 LL | fn foo<'a, 'b>(x: &mut Foo<'a; 'b>) {}
    |                              ^ expected one of `,` or `>` here
diff --git a/src/test/ui/parser/macro-bad-delimiter-ident.rs b/src/test/ui/parser/macro-bad-delimiter-ident.rs
index 56eb976..987c955 100644
--- a/src/test/ui/parser/macro-bad-delimiter-ident.rs
+++ b/src/test/ui/parser/macro-bad-delimiter-ident.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     foo! bar < //~ ERROR expected `(` or `{`, found `<`
 }
diff --git a/src/test/ui/parser/macro-bad-delimiter-ident.stderr b/src/test/ui/parser/macro-bad-delimiter-ident.stderr
index c6d1382..59762e0 100644
--- a/src/test/ui/parser/macro-bad-delimiter-ident.stderr
+++ b/src/test/ui/parser/macro-bad-delimiter-ident.stderr
@@ -1,5 +1,5 @@
 error: expected `(` or `{`, found `<`
-  --> $DIR/macro-bad-delimiter-ident.rs:4:14
+  --> $DIR/macro-bad-delimiter-ident.rs:2:14
    |
 LL |     foo! bar < //~ ERROR expected `(` or `{`, found `<`
    |              ^ expected `(` or `{`
diff --git a/src/test/ui/parser/macro-keyword.rs b/src/test/ui/parser/macro-keyword.rs
index cb1898e..58489fb 100644
--- a/src/test/ui/parser/macro-keyword.rs
+++ b/src/test/ui/parser/macro-keyword.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn macro() {  //~ ERROR expected identifier, found reserved keyword `macro`
 }
 
diff --git a/src/test/ui/parser/macro-keyword.stderr b/src/test/ui/parser/macro-keyword.stderr
index d3edb04..4a10dd5 100644
--- a/src/test/ui/parser/macro-keyword.stderr
+++ b/src/test/ui/parser/macro-keyword.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found reserved keyword `macro`
-  --> $DIR/macro-keyword.rs:3:4
+  --> $DIR/macro-keyword.rs:1:4
    |
 LL | fn macro() {  //~ ERROR expected identifier, found reserved keyword `macro`
    |    ^^^^^ expected identifier, found reserved keyword
diff --git a/src/test/ui/parser/macro-mismatched-delim-brace-paren.rs b/src/test/ui/parser/macro-mismatched-delim-brace-paren.rs
index 29fdd9e..3f3e997 100644
--- a/src/test/ui/parser/macro-mismatched-delim-brace-paren.rs
+++ b/src/test/ui/parser/macro-mismatched-delim-brace-paren.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
+macro_rules! foo { ($($tt:tt)*) => () }
 
 fn main() {
     foo! {
diff --git a/src/test/ui/parser/macro-mismatched-delim-paren-brace.rs b/src/test/ui/parser/macro-mismatched-delim-paren-brace.rs
index 38e5393..1185f88 100644
--- a/src/test/ui/parser/macro-mismatched-delim-paren-brace.rs
+++ b/src/test/ui/parser/macro-mismatched-delim-paren-brace.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     foo! (
         bar, "baz", 1, 2.0
diff --git a/src/test/ui/parser/macro-mismatched-delim-paren-brace.stderr b/src/test/ui/parser/macro-mismatched-delim-paren-brace.stderr
index c25e5fe..805ba8b 100644
--- a/src/test/ui/parser/macro-mismatched-delim-paren-brace.stderr
+++ b/src/test/ui/parser/macro-mismatched-delim-paren-brace.stderr
@@ -1,5 +1,5 @@
 error: incorrect close delimiter: `}`
-  --> $DIR/macro-mismatched-delim-paren-brace.rs:6:5
+  --> $DIR/macro-mismatched-delim-paren-brace.rs:4:5
    |
 LL |     foo! (
    |          - un-closed delimiter
@@ -8,7 +8,7 @@
    |     ^ incorrect close delimiter
 
 error: unexpected close delimiter: `}`
-  --> $DIR/macro-mismatched-delim-paren-brace.rs:7:1
+  --> $DIR/macro-mismatched-delim-paren-brace.rs:5:1
    |
 LL | } //~ ERROR unexpected close delimiter: `}`
    | ^ unexpected close delimiter
diff --git a/src/test/ui/parser/macros-no-semicolon-items.rs b/src/test/ui/parser/macros-no-semicolon-items.rs
index 2c3284b..a727caf 100644
--- a/src/test/ui/parser/macros-no-semicolon-items.rs
+++ b/src/test/ui/parser/macros-no-semicolon-items.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 macro_rules! foo()  //~ ERROR semicolon
 
 fn main() {
diff --git a/src/test/ui/parser/macros-no-semicolon-items.stderr b/src/test/ui/parser/macros-no-semicolon-items.stderr
index efdca38..84dd302 100644
--- a/src/test/ui/parser/macros-no-semicolon-items.stderr
+++ b/src/test/ui/parser/macros-no-semicolon-items.stderr
@@ -1,5 +1,5 @@
 error: macros that expand to items must either be surrounded with braces or followed by a semicolon
-  --> $DIR/macros-no-semicolon-items.rs:3:17
+  --> $DIR/macros-no-semicolon-items.rs:1:17
    |
 LL | macro_rules! foo()  //~ ERROR semicolon
    |                 ^^
diff --git a/src/test/ui/parser/macros-no-semicolon.rs b/src/test/ui/parser/macros-no-semicolon.rs
index 0ad5b8d..fd79fa8 100644
--- a/src/test/ui/parser/macros-no-semicolon.rs
+++ b/src/test/ui/parser/macros-no-semicolon.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     assert_eq!(1, 2)
     assert_eq!(3, 4) //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `assert_eq`
diff --git a/src/test/ui/parser/macros-no-semicolon.stderr b/src/test/ui/parser/macros-no-semicolon.stderr
index 01ca2a6..4f9e7fb 100644
--- a/src/test/ui/parser/macros-no-semicolon.stderr
+++ b/src/test/ui/parser/macros-no-semicolon.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `assert_eq`
-  --> $DIR/macros-no-semicolon.rs:5:5
+  --> $DIR/macros-no-semicolon.rs:3:5
    |
 LL |     assert_eq!(1, 2)
    |                     - expected one of `.`, `;`, `?`, `}`, or an operator here
diff --git a/src/test/ui/parser/match-arrows-block-then-binop.rs b/src/test/ui/parser/match-arrows-block-then-binop.rs
index 1a79da3..1a40d67 100644
--- a/src/test/ui/parser/match-arrows-block-then-binop.rs
+++ b/src/test/ui/parser/match-arrows-block-then-binop.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
 
     match 0 {
diff --git a/src/test/ui/parser/match-arrows-block-then-binop.stderr b/src/test/ui/parser/match-arrows-block-then-binop.stderr
index 4ba87ef..2782af4 100644
--- a/src/test/ui/parser/match-arrows-block-then-binop.stderr
+++ b/src/test/ui/parser/match-arrows-block-then-binop.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found `+`
-  --> $DIR/match-arrows-block-then-binop.rs:7:9
+  --> $DIR/match-arrows-block-then-binop.rs:5:9
    |
 LL |       } + 5 //~ ERROR expected pattern, found `+`
    |         ^ expected pattern
diff --git a/src/test/ui/parser/match-refactor-to-expr.rs b/src/test/ui/parser/match-refactor-to-expr.rs
index ac7fe5f..09ebb2e 100644
--- a/src/test/ui/parser/match-refactor-to-expr.rs
+++ b/src/test/ui/parser/match-refactor-to-expr.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let foo =
         match //~ NOTE while parsing this match expression
diff --git a/src/test/ui/parser/match-refactor-to-expr.stderr b/src/test/ui/parser/match-refactor-to-expr.stderr
index f6fcefe..692b116 100644
--- a/src/test/ui/parser/match-refactor-to-expr.stderr
+++ b/src/test/ui/parser/match-refactor-to-expr.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `?`, `{`, or an operator, found `;`
-  --> $DIR/match-refactor-to-expr.rs:8:9
+  --> $DIR/match-refactor-to-expr.rs:6:9
    |
 LL |         match //~ NOTE while parsing this match expression
    |         -----
diff --git a/src/test/ui/parser/match-vec-invalid.rs b/src/test/ui/parser/match-vec-invalid.rs
index 9c8fb1e..e5e85ba 100644
--- a/src/test/ui/parser/match-vec-invalid.rs
+++ b/src/test/ui/parser/match-vec-invalid.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let a = Vec::new();
     match a {
diff --git a/src/test/ui/parser/match-vec-invalid.stderr b/src/test/ui/parser/match-vec-invalid.stderr
index 7168f0b..5a5fc9c 100644
--- a/src/test/ui/parser/match-vec-invalid.stderr
+++ b/src/test/ui/parser/match-vec-invalid.stderr
@@ -1,5 +1,5 @@
 error: expected one of `,` or `@`, found `..`
-  --> $DIR/match-vec-invalid.rs:6:25
+  --> $DIR/match-vec-invalid.rs:4:25
    |
 LL |         [1, tail.., tail..] => {}, //~ ERROR: expected one of `,` or `@`, found `..`
    |                         ^^ expected one of `,` or `@` here
diff --git a/src/test/ui/parser/mod_file_not_exist.rs b/src/test/ui/parser/mod_file_not_exist.rs
index a6c1028..e662c70 100644
--- a/src/test/ui/parser/mod_file_not_exist.rs
+++ b/src/test/ui/parser/mod_file_not_exist.rs
@@ -1,5 +1,4 @@
 // ignore-windows
-// compile-flags: -Z parse-only
 
 mod not_a_real_file; //~ ERROR file not found for module `not_a_real_file`
 //~^ HELP name the file either not_a_real_file.rs or not_a_real_file/mod.rs inside the directory
diff --git a/src/test/ui/parser/mod_file_not_exist.stderr b/src/test/ui/parser/mod_file_not_exist.stderr
index 3e06a5d..f7f0e2d 100644
--- a/src/test/ui/parser/mod_file_not_exist.stderr
+++ b/src/test/ui/parser/mod_file_not_exist.stderr
@@ -1,5 +1,5 @@
 error[E0583]: file not found for module `not_a_real_file`
-  --> $DIR/mod_file_not_exist.rs:4:5
+  --> $DIR/mod_file_not_exist.rs:3:5
    |
 LL | mod not_a_real_file; //~ ERROR file not found for module `not_a_real_file`
    |     ^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/mod_file_not_exist_windows.rs b/src/test/ui/parser/mod_file_not_exist_windows.rs
index c7ffe7b..0cd9e9c 100644
--- a/src/test/ui/parser/mod_file_not_exist_windows.rs
+++ b/src/test/ui/parser/mod_file_not_exist_windows.rs
@@ -1,5 +1,4 @@
 // only-windows
-// compile-flags: -Z parse-only
 
 mod not_a_real_file; //~ ERROR file not found for module `not_a_real_file`
 //~^ HELP name the file either not_a_real_file.rs or not_a_real_file\mod.rs inside the directory
diff --git a/src/test/ui/parser/mod_file_not_exist_windows.stderr b/src/test/ui/parser/mod_file_not_exist_windows.stderr
index 0f8b9c0..67abd63 100644
--- a/src/test/ui/parser/mod_file_not_exist_windows.stderr
+++ b/src/test/ui/parser/mod_file_not_exist_windows.stderr
@@ -1,5 +1,5 @@
 error[E0583]: file not found for module `not_a_real_file`
-  --> $DIR/mod_file_not_exist_windows.rs:4:5
+  --> $DIR/mod_file_not_exist_windows.rs:3:5
    |
 LL | mod not_a_real_file; //~ ERROR file not found for module `not_a_real_file`
    |     ^^^^^^^^^^^^^^^
diff --git a/src/test/ui/parser/mod_file_with_path_attr.rs b/src/test/ui/parser/mod_file_with_path_attr.rs
index 6f355ae..9450d89 100644
--- a/src/test/ui/parser/mod_file_with_path_attr.rs
+++ b/src/test/ui/parser/mod_file_with_path_attr.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 // normalize-stderr-test: "not_a_real_file.rs:.*\(" -> "not_a_real_file.rs: $$FILE_NOT_FOUND_MSG ("
 
 #[path = "not_a_real_file.rs"]
diff --git a/src/test/ui/parser/mod_file_with_path_attr.stderr b/src/test/ui/parser/mod_file_with_path_attr.stderr
index 22bd811..a3a3486 100644
--- a/src/test/ui/parser/mod_file_with_path_attr.stderr
+++ b/src/test/ui/parser/mod_file_with_path_attr.stderr
@@ -1,5 +1,5 @@
 error: couldn't read $DIR/not_a_real_file.rs: $FILE_NOT_FOUND_MSG (os error 2)
-  --> $DIR/mod_file_with_path_attr.rs:5:5
+  --> $DIR/mod_file_with_path_attr.rs:4:5
    |
 LL | mod m; //~ ERROR not_a_real_file.rs
    |     ^
diff --git a/src/test/ui/parser/multiline-comment-line-tracking.rs b/src/test/ui/parser/multiline-comment-line-tracking.rs
index e528819..d4735e8 100644
--- a/src/test/ui/parser/multiline-comment-line-tracking.rs
+++ b/src/test/ui/parser/multiline-comment-line-tracking.rs
@@ -1,10 +1,9 @@
-// compile-flags: -Z parse-only
-// error-pattern:9:3
+// Parse error on line X, but is reported on line Y instead.
 
 /* 1
  * 2
  * 3
  */
 fn main() {
-  %; // parse error on line 19, but is reported on line 6 instead.
+  %; //~ ERROR expected expression, found `%`
 }
diff --git a/src/test/ui/parser/multiline-comment-line-tracking.stderr b/src/test/ui/parser/multiline-comment-line-tracking.stderr
index 500b342..c9404d8 100644
--- a/src/test/ui/parser/multiline-comment-line-tracking.stderr
+++ b/src/test/ui/parser/multiline-comment-line-tracking.stderr
@@ -1,7 +1,7 @@
 error: expected expression, found `%`
-  --> $DIR/multiline-comment-line-tracking.rs:9:3
+  --> $DIR/multiline-comment-line-tracking.rs:8:3
    |
-LL |   %; // parse error on line 19, but is reported on line 6 instead.
+LL |   %; //~ ERROR expected expression, found `%`
    |   ^ expected expression
 
 error: aborting due to previous error
diff --git a/src/test/ui/parser/multitrait.rs b/src/test/ui/parser/multitrait.rs
index 2c62756..f9b4b37 100644
--- a/src/test/ui/parser/multitrait.rs
+++ b/src/test/ui/parser/multitrait.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct S {
  y: isize
 }
diff --git a/src/test/ui/parser/multitrait.stderr b/src/test/ui/parser/multitrait.stderr
index c9400c0..61dbc82 100644
--- a/src/test/ui/parser/multitrait.stderr
+++ b/src/test/ui/parser/multitrait.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `<`, `for`, `where`, or `{`, found `,`
-  --> $DIR/multitrait.rs:7:9
+  --> $DIR/multitrait.rs:5:9
    |
 LL | impl Cmp, ToString for S {
    |         ^ expected one of 8 possible tokens here
diff --git a/src/test/ui/parser/mut-patterns.rs b/src/test/ui/parser/mut-patterns.rs
index 9c4384c..a5eb482 100644
--- a/src/test/ui/parser/mut-patterns.rs
+++ b/src/test/ui/parser/mut-patterns.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Can't put mut in non-ident pattern
 
 pub fn main() {
diff --git a/src/test/ui/parser/mut-patterns.stderr b/src/test/ui/parser/mut-patterns.stderr
index 09a21d8..5bbb4ce 100644
--- a/src/test/ui/parser/mut-patterns.stderr
+++ b/src/test/ui/parser/mut-patterns.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `{`
-  --> $DIR/mut-patterns.rs:7:17
+  --> $DIR/mut-patterns.rs:5:17
    |
 LL |     let mut Foo { x: x } = Foo { x: 3 }; //~ ERROR: expected one of `:`, `;`, `=`, or `@`, found `{`
    |                 ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/new-unicode-escapes-1.rs b/src/test/ui/parser/new-unicode-escapes-1.rs
index cf75cda..0e14212 100644
--- a/src/test/ui/parser/new-unicode-escapes-1.rs
+++ b/src/test/ui/parser/new-unicode-escapes-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 pub fn main() {
     let s = "\u{2603"; //~ ERROR unterminated unicode escape (needed a `}`)
 }
diff --git a/src/test/ui/parser/new-unicode-escapes-1.stderr b/src/test/ui/parser/new-unicode-escapes-1.stderr
index 77a7980..828e72e 100644
--- a/src/test/ui/parser/new-unicode-escapes-1.stderr
+++ b/src/test/ui/parser/new-unicode-escapes-1.stderr
@@ -1,5 +1,5 @@
 error: unterminated unicode escape (needed a `}`)
-  --> $DIR/new-unicode-escapes-1.rs:4:21
+  --> $DIR/new-unicode-escapes-1.rs:2:21
    |
 LL |     let s = "/u{2603"; //~ ERROR unterminated unicode escape (needed a `}`)
    |                     ^
diff --git a/src/test/ui/parser/new-unicode-escapes-2.rs b/src/test/ui/parser/new-unicode-escapes-2.rs
index 228518f..b30b3db 100644
--- a/src/test/ui/parser/new-unicode-escapes-2.rs
+++ b/src/test/ui/parser/new-unicode-escapes-2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 pub fn main() {
     let s = "\u{260311111111}"; //~ ERROR overlong unicode escape (must have at most 6 hex digits)
 }
diff --git a/src/test/ui/parser/new-unicode-escapes-2.stderr b/src/test/ui/parser/new-unicode-escapes-2.stderr
index 4f5bef1..97ba3fb 100644
--- a/src/test/ui/parser/new-unicode-escapes-2.stderr
+++ b/src/test/ui/parser/new-unicode-escapes-2.stderr
@@ -1,5 +1,5 @@
 error: overlong unicode escape (must have at most 6 hex digits)
-  --> $DIR/new-unicode-escapes-2.rs:4:17
+  --> $DIR/new-unicode-escapes-2.rs:2:17
    |
 LL |     let s = "/u{260311111111}"; //~ ERROR overlong unicode escape (must have at most 6 hex digits)
    |                 ^^^^^^^^^^^^
diff --git a/src/test/ui/parser/new-unicode-escapes-3.rs b/src/test/ui/parser/new-unicode-escapes-3.rs
index 8a38e14..295ab08 100644
--- a/src/test/ui/parser/new-unicode-escapes-3.rs
+++ b/src/test/ui/parser/new-unicode-escapes-3.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 pub fn main() {
     let s1 = "\u{d805}"; //~ ERROR invalid unicode character escape
     let s2 = "\u{ffffff}"; //~ ERROR invalid unicode character escape
diff --git a/src/test/ui/parser/new-unicode-escapes-3.stderr b/src/test/ui/parser/new-unicode-escapes-3.stderr
index 158b3a1..038002a 100644
--- a/src/test/ui/parser/new-unicode-escapes-3.stderr
+++ b/src/test/ui/parser/new-unicode-escapes-3.stderr
@@ -1,5 +1,5 @@
 error: invalid unicode character escape
-  --> $DIR/new-unicode-escapes-3.rs:4:14
+  --> $DIR/new-unicode-escapes-3.rs:2:14
    |
 LL |     let s1 = "/u{d805}"; //~ ERROR invalid unicode character escape
    |              ^^^^^^^^^^
@@ -7,7 +7,7 @@
    = help: unicode escape must not be a surrogate
 
 error: invalid unicode character escape
-  --> $DIR/new-unicode-escapes-3.rs:5:14
+  --> $DIR/new-unicode-escapes-3.rs:3:14
    |
 LL |     let s2 = "/u{ffffff}"; //~ ERROR invalid unicode character escape
    |              ^^^^^^^^^^^^
diff --git a/src/test/ui/parser/new-unicode-escapes-4.rs b/src/test/ui/parser/new-unicode-escapes-4.rs
index 49a3566..b871000 100644
--- a/src/test/ui/parser/new-unicode-escapes-4.rs
+++ b/src/test/ui/parser/new-unicode-escapes-4.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 pub fn main() {
     let s = "\u{lol}";
diff --git a/src/test/ui/parser/no-binary-float-literal.rs b/src/test/ui/parser/no-binary-float-literal.rs
index c3ed2ac..c078bf5 100644
--- a/src/test/ui/parser/no-binary-float-literal.rs
+++ b/src/test/ui/parser/no-binary-float-literal.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:binary float literal is not supported
 
 fn main() {
diff --git a/src/test/ui/parser/no-binary-float-literal.stderr b/src/test/ui/parser/no-binary-float-literal.stderr
index c3eab54..7ff3e28 100644
--- a/src/test/ui/parser/no-binary-float-literal.stderr
+++ b/src/test/ui/parser/no-binary-float-literal.stderr
@@ -1,5 +1,5 @@
 error: binary float literal is not supported
-  --> $DIR/no-binary-float-literal.rs:7:5
+  --> $DIR/no-binary-float-literal.rs:5:5
    |
 LL |     0b101.010;
    |     ^^^^^^^^^
diff --git a/src/test/ui/parser/no-hex-float-literal.rs b/src/test/ui/parser/no-hex-float-literal.rs
index 4e56cc2..d830c96 100644
--- a/src/test/ui/parser/no-hex-float-literal.rs
+++ b/src/test/ui/parser/no-hex-float-literal.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern:hexadecimal float literal is not supported
 
 fn main() {
diff --git a/src/test/ui/parser/no-hex-float-literal.stderr b/src/test/ui/parser/no-hex-float-literal.stderr
index 7d9aa05..1668cfe 100644
--- a/src/test/ui/parser/no-hex-float-literal.stderr
+++ b/src/test/ui/parser/no-hex-float-literal.stderr
@@ -1,5 +1,5 @@
 error: hexadecimal float literal is not supported
-  --> $DIR/no-hex-float-literal.rs:7:5
+  --> $DIR/no-hex-float-literal.rs:5:5
    |
 LL |     0x567.89;
    |     ^^^^^^^^
diff --git a/src/test/ui/parser/no-unsafe-self.rs b/src/test/ui/parser/no-unsafe-self.rs
index c74fc8c..57201f2 100644
--- a/src/test/ui/parser/no-unsafe-self.rs
+++ b/src/test/ui/parser/no-unsafe-self.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 trait A {
     fn foo(*mut self); //~ ERROR cannot pass `self` by raw pointer
diff --git a/src/test/ui/parser/not-a-pred.rs b/src/test/ui/parser/not-a-pred.rs
index 8efd28b..e6a02d5 100644
--- a/src/test/ui/parser/not-a-pred.rs
+++ b/src/test/ui/parser/not-a-pred.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // error-pattern: lt
 
 fn f(a: isize, b: isize) : lt(a, b) { }
diff --git a/src/test/ui/parser/not-a-pred.stderr b/src/test/ui/parser/not-a-pred.stderr
index db6e069..46d6038 100644
--- a/src/test/ui/parser/not-a-pred.stderr
+++ b/src/test/ui/parser/not-a-pred.stderr
@@ -1,5 +1,5 @@
 error: expected one of `->`, `where`, or `{`, found `:`
-  --> $DIR/not-a-pred.rs:5:26
+  --> $DIR/not-a-pred.rs:3:26
    |
 LL | fn f(a: isize, b: isize) : lt(a, b) { }
    |                          ^ expected one of `->`, `where`, or `{` here
diff --git a/src/test/ui/parser/omitted-arg-in-item-fn.rs b/src/test/ui/parser/omitted-arg-in-item-fn.rs
index a9c0e91..5ee9daf 100644
--- a/src/test/ui/parser/omitted-arg-in-item-fn.rs
+++ b/src/test/ui/parser/omitted-arg-in-item-fn.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn foo(x) { //~ ERROR expected one of `:` or `@`, found `)`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/omitted-arg-in-item-fn.stderr b/src/test/ui/parser/omitted-arg-in-item-fn.stderr
index 0e3717f..b21a1bd 100644
--- a/src/test/ui/parser/omitted-arg-in-item-fn.stderr
+++ b/src/test/ui/parser/omitted-arg-in-item-fn.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:` or `@`, found `)`
-  --> $DIR/omitted-arg-in-item-fn.rs:3:9
+  --> $DIR/omitted-arg-in-item-fn.rs:1:9
    |
 LL | fn foo(x) { //~ ERROR expected one of `:` or `@`, found `)`
    |         ^ expected one of `:` or `@` here
diff --git a/src/test/ui/parser/paamayim-nekudotayim.rs b/src/test/ui/parser/paamayim-nekudotayim.rs
index 9ae5722..cb151d6 100644
--- a/src/test/ui/parser/paamayim-nekudotayim.rs
+++ b/src/test/ui/parser/paamayim-nekudotayim.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // http://phpsadness.com/sad/1
 
 fn main() {
diff --git a/src/test/ui/parser/paamayim-nekudotayim.stderr b/src/test/ui/parser/paamayim-nekudotayim.stderr
index dfab02e..6423aa2 100644
--- a/src/test/ui/parser/paamayim-nekudotayim.stderr
+++ b/src/test/ui/parser/paamayim-nekudotayim.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `;`
-  --> $DIR/paamayim-nekudotayim.rs:6:7
+  --> $DIR/paamayim-nekudotayim.rs:4:7
    |
 LL |     ::; //~ ERROR expected identifier, found `;`
    |       ^ expected identifier
diff --git a/src/test/ui/parser/paren-after-qualified-path-in-match.rs b/src/test/ui/parser/paren-after-qualified-path-in-match.rs
index dec0ba8..68b1c2b 100644
--- a/src/test/ui/parser/paren-after-qualified-path-in-match.rs
+++ b/src/test/ui/parser/paren-after-qualified-path-in-match.rs
@@ -1,7 +1,5 @@
-// compile-flags: -Z parse-only
-
-fn foo() {
-    match x {
+fn main() {
+    match 10 {
         <T as Trait>::Type(2) => (),
         //~^ ERROR unexpected `(` after qualified path
         _ => (),
diff --git a/src/test/ui/parser/paren-after-qualified-path-in-match.stderr b/src/test/ui/parser/paren-after-qualified-path-in-match.stderr
index bee6865..79460e0 100644
--- a/src/test/ui/parser/paren-after-qualified-path-in-match.stderr
+++ b/src/test/ui/parser/paren-after-qualified-path-in-match.stderr
@@ -1,5 +1,5 @@
 error: unexpected `(` after qualified path
-  --> $DIR/paren-after-qualified-path-in-match.rs:5:27
+  --> $DIR/paren-after-qualified-path-in-match.rs:3:27
    |
 LL |         <T as Trait>::Type(2) => (),
    |                           ^ unexpected `(` after qualified path
diff --git a/src/test/ui/parser/pat-lt-bracket-1.rs b/src/test/ui/parser/pat-lt-bracket-1.rs
index 5ef43ab..2e20014 100644
--- a/src/test/ui/parser/pat-lt-bracket-1.rs
+++ b/src/test/ui/parser/pat-lt-bracket-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
   match 42 {
     x < 7 => (),
diff --git a/src/test/ui/parser/pat-lt-bracket-1.stderr b/src/test/ui/parser/pat-lt-bracket-1.stderr
index a420931..1bf2716 100644
--- a/src/test/ui/parser/pat-lt-bracket-1.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-1.stderr
@@ -1,5 +1,5 @@
 error: expected one of `=>`, `@`, `if`, or `|`, found `<`
-  --> $DIR/pat-lt-bracket-1.rs:5:7
+  --> $DIR/pat-lt-bracket-1.rs:3:7
    |
 LL |     x < 7 => (),
    |       ^ expected one of `=>`, `@`, `if`, or `|` here
diff --git a/src/test/ui/parser/pat-lt-bracket-2.rs b/src/test/ui/parser/pat-lt-bracket-2.rs
index 3459c73..6eb01c1 100644
--- a/src/test/ui/parser/pat-lt-bracket-2.rs
+++ b/src/test/ui/parser/pat-lt-bracket-2.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn a(B<) {}
    //~^ error: expected one of `:` or `@`, found `<`
+
+fn main() {}
diff --git a/src/test/ui/parser/pat-lt-bracket-2.stderr b/src/test/ui/parser/pat-lt-bracket-2.stderr
index d235767..cce1a17 100644
--- a/src/test/ui/parser/pat-lt-bracket-2.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-2.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:` or `@`, found `<`
-  --> $DIR/pat-lt-bracket-2.rs:3:7
+  --> $DIR/pat-lt-bracket-2.rs:1:7
    |
 LL | fn a(B<) {}
    |       ^ expected one of `:` or `@` here
diff --git a/src/test/ui/parser/pat-lt-bracket-3.rs b/src/test/ui/parser/pat-lt-bracket-3.rs
index 349ea9b..a8bdfd3 100644
--- a/src/test/ui/parser/pat-lt-bracket-3.rs
+++ b/src/test/ui/parser/pat-lt-bracket-3.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo<T>(T, T);
 
 impl<T> Foo<T> {
@@ -12,3 +10,5 @@
         }
     }
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/pat-lt-bracket-3.stderr b/src/test/ui/parser/pat-lt-bracket-3.stderr
index 9c0448f..536d14e 100644
--- a/src/test/ui/parser/pat-lt-bracket-3.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-3.stderr
@@ -1,5 +1,5 @@
 error: expected one of `=>`, `@`, `if`, or `|`, found `<`
-  --> $DIR/pat-lt-bracket-3.rs:8:16
+  --> $DIR/pat-lt-bracket-3.rs:6:16
    |
 LL |             Foo<T>(x, y) => {
    |                ^ expected one of `=>`, `@`, `if`, or `|` here
diff --git a/src/test/ui/parser/pat-lt-bracket-4.rs b/src/test/ui/parser/pat-lt-bracket-4.rs
index 9608422..de314f6 100644
--- a/src/test/ui/parser/pat-lt-bracket-4.rs
+++ b/src/test/ui/parser/pat-lt-bracket-4.rs
@@ -1,12 +1,10 @@
-// compile-flags: -Z parse-only
-
 enum BtNode {
     Node(u32,Box<BtNode>,Box<BtNode>),
     Leaf(u32),
 }
 
 fn main() {
-    let y = match x {
+    let y = match 10 {
         Foo<T>::A(value) => value, //~ error: expected one of `=>`, `@`, `if`, or `|`, found `<`
         Foo<T>::B => 7,
     };
diff --git a/src/test/ui/parser/pat-lt-bracket-4.stderr b/src/test/ui/parser/pat-lt-bracket-4.stderr
index 85f5bb9..18e0e9e 100644
--- a/src/test/ui/parser/pat-lt-bracket-4.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-4.stderr
@@ -1,5 +1,5 @@
 error: expected one of `=>`, `@`, `if`, or `|`, found `<`
-  --> $DIR/pat-lt-bracket-4.rs:10:12
+  --> $DIR/pat-lt-bracket-4.rs:8:12
    |
 LL |         Foo<T>::A(value) => value, //~ error: expected one of `=>`, `@`, `if`, or `|`, found `<`
    |            ^ expected one of `=>`, `@`, `if`, or `|` here
diff --git a/src/test/ui/parser/pat-lt-bracket-5.rs b/src/test/ui/parser/pat-lt-bracket-5.rs
index f5253ad..c4b9dd4 100644
--- a/src/test/ui/parser/pat-lt-bracket-5.rs
+++ b/src/test/ui/parser/pat-lt-bracket-5.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let v[0] = v[1]; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `[`
 }
diff --git a/src/test/ui/parser/pat-lt-bracket-5.stderr b/src/test/ui/parser/pat-lt-bracket-5.stderr
index 3dcace5..7e76a04 100644
--- a/src/test/ui/parser/pat-lt-bracket-5.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-5.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, `=`, or `@`, found `[`
-  --> $DIR/pat-lt-bracket-5.rs:4:10
+  --> $DIR/pat-lt-bracket-5.rs:2:10
    |
 LL |     let v[0] = v[1]; //~ ERROR expected one of `:`, `;`, `=`, or `@`, found `[`
    |          ^ expected one of `:`, `;`, `=`, or `@` here
diff --git a/src/test/ui/parser/pat-lt-bracket-6.rs b/src/test/ui/parser/pat-lt-bracket-6.rs
index d4639b3..9bad0cb 100644
--- a/src/test/ui/parser/pat-lt-bracket-6.rs
+++ b/src/test/ui/parser/pat-lt-bracket-6.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let Test(&desc[..]) = x; //~ ERROR: expected one of `)`, `,`, or `@`, found `[`
 }
diff --git a/src/test/ui/parser/pat-lt-bracket-6.stderr b/src/test/ui/parser/pat-lt-bracket-6.stderr
index ea17dc4..bf5b619 100644
--- a/src/test/ui/parser/pat-lt-bracket-6.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-6.stderr
@@ -1,5 +1,5 @@
 error: expected one of `)`, `,`, or `@`, found `[`
-  --> $DIR/pat-lt-bracket-6.rs:4:19
+  --> $DIR/pat-lt-bracket-6.rs:2:19
    |
 LL |     let Test(&desc[..]) = x; //~ ERROR: expected one of `)`, `,`, or `@`, found `[`
    |                   ^ expected one of `)`, `,`, or `@` here
diff --git a/src/test/ui/parser/pat-lt-bracket-7.rs b/src/test/ui/parser/pat-lt-bracket-7.rs
index 69b97e7..36c0d77 100644
--- a/src/test/ui/parser/pat-lt-bracket-7.rs
+++ b/src/test/ui/parser/pat-lt-bracket-7.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     for thing(x[]) in foo {} //~ ERROR: expected one of `)`, `,`, or `@`, found `[`
 }
diff --git a/src/test/ui/parser/pat-lt-bracket-7.stderr b/src/test/ui/parser/pat-lt-bracket-7.stderr
index c04a7a2..44394c3 100644
--- a/src/test/ui/parser/pat-lt-bracket-7.stderr
+++ b/src/test/ui/parser/pat-lt-bracket-7.stderr
@@ -1,5 +1,5 @@
 error: expected one of `)`, `,`, or `@`, found `[`
-  --> $DIR/pat-lt-bracket-7.rs:4:16
+  --> $DIR/pat-lt-bracket-7.rs:2:16
    |
 LL |     for thing(x[]) in foo {} //~ ERROR: expected one of `)`, `,`, or `@`, found `[`
    |                ^ expected one of `)`, `,`, or `@` here
diff --git a/src/test/ui/parser/pat-ranges-1.rs b/src/test/ui/parser/pat-ranges-1.rs
index 1c8b04b..ce953b2 100644
--- a/src/test/ui/parser/pat-ranges-1.rs
+++ b/src/test/ui/parser/pat-ranges-1.rs
@@ -1,7 +1,5 @@
 // Parsing of range patterns
 
-// compile-flags: -Z parse-only
-
 fn main() {
     let macropus!() ..= 11 = 12; //~ error: expected one of `:`, `;`, or `=`, found `..=`
 }
diff --git a/src/test/ui/parser/pat-ranges-1.stderr b/src/test/ui/parser/pat-ranges-1.stderr
index 1106caf..378caf6 100644
--- a/src/test/ui/parser/pat-ranges-1.stderr
+++ b/src/test/ui/parser/pat-ranges-1.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, or `=`, found `..=`
-  --> $DIR/pat-ranges-1.rs:6:21
+  --> $DIR/pat-ranges-1.rs:4:21
    |
 LL |     let macropus!() ..= 11 = 12; //~ error: expected one of `:`, `;`, or `=`, found `..=`
    |                     ^^^ expected one of `:`, `;`, or `=` here
diff --git a/src/test/ui/parser/pat-ranges-2.rs b/src/test/ui/parser/pat-ranges-2.rs
index 858d22a..9f736ed 100644
--- a/src/test/ui/parser/pat-ranges-2.rs
+++ b/src/test/ui/parser/pat-ranges-2.rs
@@ -1,7 +1,5 @@
 // Parsing of range patterns
 
-// compile-flags: -Z parse-only
-
 fn main() {
     let 10 ..= makropulos!() = 12; //~ error: expected one of `::`, `:`, `;`, or `=`, found `!`
 }
diff --git a/src/test/ui/parser/pat-ranges-2.stderr b/src/test/ui/parser/pat-ranges-2.stderr
index fd92c31..ef8b4f9 100644
--- a/src/test/ui/parser/pat-ranges-2.stderr
+++ b/src/test/ui/parser/pat-ranges-2.stderr
@@ -1,5 +1,5 @@
 error: expected one of `::`, `:`, `;`, or `=`, found `!`
-  --> $DIR/pat-ranges-2.rs:6:26
+  --> $DIR/pat-ranges-2.rs:4:26
    |
 LL |     let 10 ..= makropulos!() = 12; //~ error: expected one of `::`, `:`, `;`, or `=`, found `!`
    |                          ^ expected one of `::`, `:`, `;`, or `=` here
diff --git a/src/test/ui/parser/pat-ranges-3.rs b/src/test/ui/parser/pat-ranges-3.rs
index 407483f..65da55e 100644
--- a/src/test/ui/parser/pat-ranges-3.rs
+++ b/src/test/ui/parser/pat-ranges-3.rs
@@ -1,7 +1,5 @@
 // Parsing of range patterns
 
-// compile-flags: -Z parse-only
-
 fn main() {
     let 10 ..= 10 + 3 = 12; //~ expected one of `:`, `;`, or `=`, found `+`
 }
diff --git a/src/test/ui/parser/pat-ranges-3.stderr b/src/test/ui/parser/pat-ranges-3.stderr
index 5f1eacc..f923228 100644
--- a/src/test/ui/parser/pat-ranges-3.stderr
+++ b/src/test/ui/parser/pat-ranges-3.stderr
@@ -1,5 +1,5 @@
 error: expected one of `:`, `;`, or `=`, found `+`
-  --> $DIR/pat-ranges-3.rs:6:19
+  --> $DIR/pat-ranges-3.rs:4:19
    |
 LL |     let 10 ..= 10 + 3 = 12; //~ expected one of `:`, `;`, or `=`, found `+`
    |                   ^ expected one of `:`, `;`, or `=` here
diff --git a/src/test/ui/parser/pat-ranges-4.rs b/src/test/ui/parser/pat-ranges-4.rs
index 5cc869c..7f4a5f3 100644
--- a/src/test/ui/parser/pat-ranges-4.rs
+++ b/src/test/ui/parser/pat-ranges-4.rs
@@ -1,7 +1,5 @@
 // Parsing of range patterns
 
-// compile-flags: -Z parse-only
-
 fn main() {
     let 10 - 3 ..= 10 = 8;
     //~^ error: expected one of `...`, `..=`, `..`, `:`, `;`, or `=`, found `-`
diff --git a/src/test/ui/parser/pat-ranges-4.stderr b/src/test/ui/parser/pat-ranges-4.stderr
index 62dea79..0a1d7a1 100644
--- a/src/test/ui/parser/pat-ranges-4.stderr
+++ b/src/test/ui/parser/pat-ranges-4.stderr
@@ -1,5 +1,5 @@
 error: expected one of `...`, `..=`, `..`, `:`, `;`, or `=`, found `-`
-  --> $DIR/pat-ranges-4.rs:6:12
+  --> $DIR/pat-ranges-4.rs:4:12
    |
 LL |     let 10 - 3 ..= 10 = 8;
    |            ^ expected one of `...`, `..=`, `..`, `:`, `;`, or `=` here
diff --git a/src/test/ui/parser/pat-ref-enum.rs b/src/test/ui/parser/pat-ref-enum.rs
index 85bb6ba..412dd14 100644
--- a/src/test/ui/parser/pat-ref-enum.rs
+++ b/src/test/ui/parser/pat-ref-enum.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn matcher(x: Option<isize>) {
     match x {
       ref Some(i) => {} //~ ERROR expected identifier, found enum pattern
diff --git a/src/test/ui/parser/pat-ref-enum.stderr b/src/test/ui/parser/pat-ref-enum.stderr
index 545b949..8729e8c 100644
--- a/src/test/ui/parser/pat-ref-enum.stderr
+++ b/src/test/ui/parser/pat-ref-enum.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found enum pattern
-  --> $DIR/pat-ref-enum.rs:5:11
+  --> $DIR/pat-ref-enum.rs:3:11
    |
 LL |       ref Some(i) => {} //~ ERROR expected identifier, found enum pattern
    |           ^^^^
diff --git a/src/test/ui/parser/pat-tuple-1.rs b/src/test/ui/parser/pat-tuple-1.rs
index 8dad6e2..213fbe3 100644
--- a/src/test/ui/parser/pat-tuple-1.rs
+++ b/src/test/ui/parser/pat-tuple-1.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     match 0 {
         (, ..) => {} //~ ERROR expected pattern, found `,`
diff --git a/src/test/ui/parser/pat-tuple-1.stderr b/src/test/ui/parser/pat-tuple-1.stderr
index a867a3e..33c69de 100644
--- a/src/test/ui/parser/pat-tuple-1.stderr
+++ b/src/test/ui/parser/pat-tuple-1.stderr
@@ -1,5 +1,5 @@
 error: expected pattern, found `,`
-  --> $DIR/pat-tuple-1.rs:5:10
+  --> $DIR/pat-tuple-1.rs:3:10
    |
 LL |         (, ..) => {} //~ ERROR expected pattern, found `,`
    |          ^ expected pattern
diff --git a/src/test/ui/parser/pat-tuple-2.rs b/src/test/ui/parser/pat-tuple-2.rs
index b52ecdf..108278f 100644
--- a/src/test/ui/parser/pat-tuple-2.rs
+++ b/src/test/ui/parser/pat-tuple-2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     match 0 {
         (pat, ..,) => {} //~ ERROR trailing comma is not permitted after `..`
diff --git a/src/test/ui/parser/pat-tuple-2.stderr b/src/test/ui/parser/pat-tuple-2.stderr
index 4bf495a..ec12336 100644
--- a/src/test/ui/parser/pat-tuple-2.stderr
+++ b/src/test/ui/parser/pat-tuple-2.stderr
@@ -1,5 +1,5 @@
 error: trailing comma is not permitted after `..`
-  --> $DIR/pat-tuple-2.rs:5:17
+  --> $DIR/pat-tuple-2.rs:3:17
    |
 LL |         (pat, ..,) => {} //~ ERROR trailing comma is not permitted after `..`
    |                 ^
diff --git a/src/test/ui/parser/pat-tuple-3.rs b/src/test/ui/parser/pat-tuple-3.rs
index 1562447..63dcde4 100644
--- a/src/test/ui/parser/pat-tuple-3.rs
+++ b/src/test/ui/parser/pat-tuple-3.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     match 0 {
         (.., pat, ..) => {} //~ ERROR `..` can only be used once per tuple or tuple struct pattern
diff --git a/src/test/ui/parser/pat-tuple-3.stderr b/src/test/ui/parser/pat-tuple-3.stderr
index c015341..90940eb 100644
--- a/src/test/ui/parser/pat-tuple-3.stderr
+++ b/src/test/ui/parser/pat-tuple-3.stderr
@@ -1,5 +1,5 @@
 error: `..` can only be used once per tuple or tuple struct pattern
-  --> $DIR/pat-tuple-3.rs:5:19
+  --> $DIR/pat-tuple-3.rs:3:19
    |
 LL |         (.., pat, ..) => {} //~ ERROR `..` can only be used once per tuple or tuple struct pattern
    |                   ^^
diff --git a/src/test/ui/parser/pat-tuple-4.rs b/src/test/ui/parser/pat-tuple-4.rs
index 7058495..76f60d9 100644
--- a/src/test/ui/parser/pat-tuple-4.rs
+++ b/src/test/ui/parser/pat-tuple-4.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     match 0 {
         (.. pat) => {} //~ ERROR expected one of `)` or `,`, found `pat`
diff --git a/src/test/ui/parser/pat-tuple-4.stderr b/src/test/ui/parser/pat-tuple-4.stderr
index 665254c..fe4b4de 100644
--- a/src/test/ui/parser/pat-tuple-4.stderr
+++ b/src/test/ui/parser/pat-tuple-4.stderr
@@ -1,5 +1,5 @@
 error: expected one of `)` or `,`, found `pat`
-  --> $DIR/pat-tuple-4.rs:5:13
+  --> $DIR/pat-tuple-4.rs:3:13
    |
 LL |         (.. pat) => {} //~ ERROR expected one of `)` or `,`, found `pat`
    |             ^^^ expected one of `)` or `,` here
diff --git a/src/test/ui/parser/pat-tuple-5.rs b/src/test/ui/parser/pat-tuple-5.rs
index 6bd5775..03176ab 100644
--- a/src/test/ui/parser/pat-tuple-5.rs
+++ b/src/test/ui/parser/pat-tuple-5.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     match 0 {
         (pat ..) => {} //~ ERROR unexpected token: `)`
diff --git a/src/test/ui/parser/pat-tuple-5.stderr b/src/test/ui/parser/pat-tuple-5.stderr
index 7d12e19..2ca10f6 100644
--- a/src/test/ui/parser/pat-tuple-5.stderr
+++ b/src/test/ui/parser/pat-tuple-5.stderr
@@ -1,5 +1,5 @@
 error: unexpected token: `)`
-  --> $DIR/pat-tuple-5.rs:5:14
+  --> $DIR/pat-tuple-5.rs:3:14
    |
 LL |         (pat ..) => {} //~ ERROR unexpected token: `)`
    |              ^^
diff --git a/src/test/ui/parser/pub-method-macro.rs b/src/test/ui/parser/pub-method-macro.rs
index 9eb64cd..f04af1a 100644
--- a/src/test/ui/parser/pub-method-macro.rs
+++ b/src/test/ui/parser/pub-method-macro.rs
@@ -1,7 +1,5 @@
 // Issue #18317
 
-// compile-flags: -Z parse-only
-
 mod bleh {
     macro_rules! defn {
         ($n:ident) => (
diff --git a/src/test/ui/parser/pub-method-macro.stderr b/src/test/ui/parser/pub-method-macro.stderr
index 354f04c..2b4920a 100644
--- a/src/test/ui/parser/pub-method-macro.stderr
+++ b/src/test/ui/parser/pub-method-macro.stderr
@@ -1,5 +1,5 @@
 error: can't qualify macro invocation with `pub`
-  --> $DIR/pub-method-macro.rs:19:9
+  --> $DIR/pub-method-macro.rs:17:9
    |
 LL |         pub defn!(f); //~ ERROR can't qualify macro invocation with `pub`
    |         ^^^
diff --git a/src/test/ui/parser/range-3.rs b/src/test/ui/parser/range-3.rs
index 4e9c3e1..931839f 100644
--- a/src/test/ui/parser/range-3.rs
+++ b/src/test/ui/parser/range-3.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Test range syntax - syntax errors.
 
 pub fn main() {
diff --git a/src/test/ui/parser/range-3.stderr b/src/test/ui/parser/range-3.stderr
index 9f893ac..92c3348 100644
--- a/src/test/ui/parser/range-3.stderr
+++ b/src/test/ui/parser/range-3.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `;`, `?`, or an operator, found `..`
-  --> $DIR/range-3.rs:6:17
+  --> $DIR/range-3.rs:4:17
    |
 LL |     let r = 1..2..3;
    |                 ^^ expected one of `.`, `;`, `?`, or an operator here
diff --git a/src/test/ui/parser/range-4.rs b/src/test/ui/parser/range-4.rs
index db6ae70..20af956 100644
--- a/src/test/ui/parser/range-4.rs
+++ b/src/test/ui/parser/range-4.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Test range syntax - syntax errors.
 
 pub fn main() {
diff --git a/src/test/ui/parser/range-4.stderr b/src/test/ui/parser/range-4.stderr
index 20915e4..90ec461 100644
--- a/src/test/ui/parser/range-4.stderr
+++ b/src/test/ui/parser/range-4.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `;`, `?`, or an operator, found `..`
-  --> $DIR/range-4.rs:6:16
+  --> $DIR/range-4.rs:4:16
    |
 LL |     let r = ..1..2;
    |                ^^ expected one of `.`, `;`, `?`, or an operator here
diff --git a/src/test/ui/parser/range_inclusive.rs b/src/test/ui/parser/range_inclusive.rs
index 1460010..bc61c5b 100644
--- a/src/test/ui/parser/range_inclusive.rs
+++ b/src/test/ui/parser/range_inclusive.rs
@@ -1,7 +1,5 @@
 // Make sure that inclusive ranges with no end point don't parse.
 
-// compile-flags: -Z parse-only
-
 pub fn main() {
     for _ in 1..= {} //~ERROR inclusive range with no end
                      //~^HELP bounded at the end
diff --git a/src/test/ui/parser/range_inclusive.stderr b/src/test/ui/parser/range_inclusive.stderr
index 0a0b9e5..f50b2fa 100644
--- a/src/test/ui/parser/range_inclusive.stderr
+++ b/src/test/ui/parser/range_inclusive.stderr
@@ -1,5 +1,5 @@
 error[E0586]: inclusive range with no end
-  --> $DIR/range_inclusive.rs:6:19
+  --> $DIR/range_inclusive.rs:4:19
    |
 LL |     for _ in 1..= {} //~ERROR inclusive range with no end
    |                   ^
diff --git a/src/test/ui/parser/range_inclusive_dotdotdot.rs b/src/test/ui/parser/range_inclusive_dotdotdot.rs
index 4f15727..a780304 100644
--- a/src/test/ui/parser/range_inclusive_dotdotdot.rs
+++ b/src/test/ui/parser/range_inclusive_dotdotdot.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 // Make sure that inclusive ranges with `...` syntax don't parse.
 
diff --git a/src/test/ui/parser/raw-byte-string-eof.rs b/src/test/ui/parser/raw-byte-string-eof.rs
index b30fe2e..b74907b 100644
--- a/src/test/ui/parser/raw-byte-string-eof.rs
+++ b/src/test/ui/parser/raw-byte-string-eof.rs
@@ -1,6 +1,3 @@
-// compile-flags: -Z parse-only
-
-
 pub fn main() {
     br##"a"#;  //~ unterminated raw string
 }
diff --git a/src/test/ui/parser/raw-byte-string-eof.stderr b/src/test/ui/parser/raw-byte-string-eof.stderr
index 9e45950..071cd62 100644
--- a/src/test/ui/parser/raw-byte-string-eof.stderr
+++ b/src/test/ui/parser/raw-byte-string-eof.stderr
@@ -1,5 +1,5 @@
 error: unterminated raw string
-  --> $DIR/raw-byte-string-eof.rs:5:6
+  --> $DIR/raw-byte-string-eof.rs:2:6
    |
 LL |     br##"a"#;  //~ unterminated raw string
    |      ^ unterminated raw string
diff --git a/src/test/ui/parser/raw-byte-string-literals.rs b/src/test/ui/parser/raw-byte-string-literals.rs
index 4d3f2528..2800e40 100644
--- a/src/test/ui/parser/raw-byte-string-literals.rs
+++ b/src/test/ui/parser/raw-byte-string-literals.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 
 pub fn main() {
diff --git a/src/test/ui/parser/raw-str-delim.rs b/src/test/ui/parser/raw-str-delim.rs
index a2f6b8c8..2f13893 100644
--- a/src/test/ui/parser/raw-str-delim.rs
+++ b/src/test/ui/parser/raw-str-delim.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 static s: &'static str =
     r#~"#"~# //~ ERROR found invalid character; only `#` is allowed in raw string delimitation
 ;
diff --git a/src/test/ui/parser/raw-str-delim.stderr b/src/test/ui/parser/raw-str-delim.stderr
index be165f4..47fd331 100644
--- a/src/test/ui/parser/raw-str-delim.stderr
+++ b/src/test/ui/parser/raw-str-delim.stderr
@@ -1,5 +1,5 @@
 error: found invalid character; only `#` is allowed in raw string delimitation: ~
-  --> $DIR/raw-str-delim.rs:4:5
+  --> $DIR/raw-str-delim.rs:2:5
    |
 LL |     r#~"#"~# //~ ERROR found invalid character; only `#` is allowed in raw string delimitation
    |     ^^
diff --git a/src/test/ui/parser/raw-str-unbalanced.rs b/src/test/ui/parser/raw-str-unbalanced.rs
index c38855c..5a1d1be 100644
--- a/src/test/ui/parser/raw-str-unbalanced.rs
+++ b/src/test/ui/parser/raw-str-unbalanced.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 static s: &'static str =
     r#"
       "## //~ ERROR expected one of `.`, `;`, `?`, or an operator, found `#`
diff --git a/src/test/ui/parser/raw-str-unbalanced.stderr b/src/test/ui/parser/raw-str-unbalanced.stderr
index c3e0386..6dedcfb 100644
--- a/src/test/ui/parser/raw-str-unbalanced.stderr
+++ b/src/test/ui/parser/raw-str-unbalanced.stderr
@@ -1,5 +1,5 @@
 error: expected one of `.`, `;`, `?`, or an operator, found `#`
-  --> $DIR/raw-str-unbalanced.rs:5:9
+  --> $DIR/raw-str-unbalanced.rs:3:9
    |
 LL |       "## //~ ERROR expected one of `.`, `;`, `?`, or an operator, found `#`
    |         ^ expected one of `.`, `;`, `?`, or an operator here
diff --git a/src/test/ui/parser/raw-str-unterminated.rs b/src/test/ui/parser/raw-str-unterminated.rs
index ef35aa4..fd31729 100644
--- a/src/test/ui/parser/raw-str-unterminated.rs
+++ b/src/test/ui/parser/raw-str-unterminated.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 static s: &'static str =
     r#" string literal goes on
         and on
diff --git a/src/test/ui/parser/raw-str-unterminated.stderr b/src/test/ui/parser/raw-str-unterminated.stderr
index f3d4d60..67792eb 100644
--- a/src/test/ui/parser/raw-str-unterminated.stderr
+++ b/src/test/ui/parser/raw-str-unterminated.stderr
@@ -1,5 +1,5 @@
 error: unterminated raw string
-  --> $DIR/raw-str-unterminated.rs:4:5
+  --> $DIR/raw-str-unterminated.rs:2:5
    |
 LL |     r#" string literal goes on
    |     ^ unterminated raw string
diff --git a/src/test/ui/parser/raw/raw-literal-keywords.rs b/src/test/ui/parser/raw/raw-literal-keywords.rs
index 896cfa0..f51e565 100644
--- a/src/test/ui/parser/raw/raw-literal-keywords.rs
+++ b/src/test/ui/parser/raw/raw-literal-keywords.rs
@@ -1,13 +1,16 @@
-// compile-flags: -Z parse-only
-
 fn test_if() {
     r#if true { } //~ ERROR found `true`
+                  //~| ERROR cannot find value `if` in this scope
 }
 
 fn test_struct() {
     r#struct Test; //~ ERROR found `Test`
+                   //~| ERROR cannot find value `struct` in this scope
 }
 
 fn test_union() {
     r#union Test; //~ ERROR found `Test`
+                  //~| ERROR cannot find value `union` in this scope
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/raw/raw-literal-keywords.stderr b/src/test/ui/parser/raw/raw-literal-keywords.stderr
index b73a7e4..8465b6a 100644
--- a/src/test/ui/parser/raw/raw-literal-keywords.stderr
+++ b/src/test/ui/parser/raw/raw-literal-keywords.stderr
@@ -1,11 +1,11 @@
 error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, `}`, or an operator, found `true`
-  --> $DIR/raw-literal-keywords.rs:4:10
+  --> $DIR/raw-literal-keywords.rs:2:10
    |
 LL |     r#if true { } //~ ERROR found `true`
    |          ^^^^ expected one of 8 possible tokens here
 
 error: expected one of `!`, `.`, `::`, `;`, `?`, `{`, `}`, or an operator, found `Test`
-  --> $DIR/raw-literal-keywords.rs:8:14
+  --> $DIR/raw-literal-keywords.rs:7:14
    |
 LL |     r#struct Test; //~ ERROR found `Test`
    |              ^^^^ expected one of 8 possible tokens here
@@ -16,5 +16,24 @@
 LL |     r#union Test; //~ ERROR found `Test`
    |             ^^^^ expected one of 8 possible tokens here
 
-error: aborting due to 3 previous errors
+error[E0425]: cannot find value `if` in this scope
+  --> $DIR/raw-literal-keywords.rs:2:5
+   |
+LL |     r#if true { } //~ ERROR found `true`
+   |     ^^^^ not found in this scope
 
+error[E0425]: cannot find value `struct` in this scope
+  --> $DIR/raw-literal-keywords.rs:7:5
+   |
+LL |     r#struct Test; //~ ERROR found `Test`
+   |     ^^^^^^^^ not found in this scope
+
+error[E0425]: cannot find value `union` in this scope
+  --> $DIR/raw-literal-keywords.rs:12:5
+   |
+LL |     r#union Test; //~ ERROR found `Test`
+   |     ^^^^^^^ not found in this scope
+
+error: aborting due to 6 previous errors
+
+For more information about this error, try `rustc --explain E0425`.
diff --git a/src/test/ui/parser/raw/raw-literal-self.rs b/src/test/ui/parser/raw/raw-literal-self.rs
index e033e48..d7b9553 100644
--- a/src/test/ui/parser/raw/raw-literal-self.rs
+++ b/src/test/ui/parser/raw/raw-literal-self.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn self_test(r#self: u32) {
     //~^ ERROR `r#self` is not currently supported.
 }
diff --git a/src/test/ui/parser/raw/raw-literal-self.stderr b/src/test/ui/parser/raw/raw-literal-self.stderr
index e5aee80..e643327 100644
--- a/src/test/ui/parser/raw/raw-literal-self.stderr
+++ b/src/test/ui/parser/raw/raw-literal-self.stderr
@@ -1,5 +1,5 @@
 error: `r#self` is not currently supported.
-  --> $DIR/raw-literal-self.rs:3:14
+  --> $DIR/raw-literal-self.rs:1:14
    |
 LL | fn self_test(r#self: u32) {
    |              ^^^^^^
diff --git a/src/test/ui/parser/raw/raw-literal-underscore.rs b/src/test/ui/parser/raw/raw-literal-underscore.rs
index d4d6bc4..bbedd39 100644
--- a/src/test/ui/parser/raw/raw-literal-underscore.rs
+++ b/src/test/ui/parser/raw/raw-literal-underscore.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn underscore_test(r#_: u32) {
     //~^ ERROR `r#_` is not currently supported.
 }
diff --git a/src/test/ui/parser/raw/raw-literal-underscore.stderr b/src/test/ui/parser/raw/raw-literal-underscore.stderr
index 067bfbc..9427b33 100644
--- a/src/test/ui/parser/raw/raw-literal-underscore.stderr
+++ b/src/test/ui/parser/raw/raw-literal-underscore.stderr
@@ -1,5 +1,5 @@
 error: `r#_` is not currently supported.
-  --> $DIR/raw-literal-underscore.rs:3:20
+  --> $DIR/raw-literal-underscore.rs:1:20
    |
 LL | fn underscore_test(r#_: u32) {
    |                    ^^^
diff --git a/src/test/ui/parser/raw/raw_string.rs b/src/test/ui/parser/raw/raw_string.rs
index a85de0a..84f07c4 100644
--- a/src/test/ui/parser/raw/raw_string.rs
+++ b/src/test/ui/parser/raw/raw_string.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let x = r##"lol"#;
     //~^ ERROR unterminated raw string
diff --git a/src/test/ui/parser/raw/raw_string.stderr b/src/test/ui/parser/raw/raw_string.stderr
index 1bc8c17..5572511 100644
--- a/src/test/ui/parser/raw/raw_string.stderr
+++ b/src/test/ui/parser/raw/raw_string.stderr
@@ -1,5 +1,5 @@
 error: unterminated raw string
-  --> $DIR/raw_string.rs:4:13
+  --> $DIR/raw_string.rs:2:13
    |
 LL |     let x = r##"lol"#;
    |             ^ unterminated raw string
diff --git a/src/test/ui/parser/recover-enum.rs b/src/test/ui/parser/recover-enum.rs
index a12da5b0..204ad85 100644
--- a/src/test/ui/parser/recover-enum.rs
+++ b/src/test/ui/parser/recover-enum.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     enum Test {
diff --git a/src/test/ui/parser/recover-enum2.rs b/src/test/ui/parser/recover-enum2.rs
index b96e427..65a1877 100644
--- a/src/test/ui/parser/recover-enum2.rs
+++ b/src/test/ui/parser/recover-enum2.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     enum Test {
diff --git a/src/test/ui/parser/recover-struct.rs b/src/test/ui/parser/recover-struct.rs
index f27320f..500591b 100644
--- a/src/test/ui/parser/recover-struct.rs
+++ b/src/test/ui/parser/recover-struct.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 fn main() {
     struct Test {
diff --git a/src/test/ui/parser/regions-out-of-scope-slice.rs b/src/test/ui/parser/regions-out-of-scope-slice.rs
index 67084e0..2cc9b1a 100644
--- a/src/test/ui/parser/regions-out-of-scope-slice.rs
+++ b/src/test/ui/parser/regions-out-of-scope-slice.rs
@@ -1,7 +1,5 @@
 // blk region isn't supported in the front-end
 
-// compile-flags: -Z parse-only
-
 fn foo(cond: bool) {
     // Here we will infer a type that uses the
     // region of the if stmt then block, but in the scope:
diff --git a/src/test/ui/parser/regions-out-of-scope-slice.stderr b/src/test/ui/parser/regions-out-of-scope-slice.stderr
index 385eac0..026d14c 100644
--- a/src/test/ui/parser/regions-out-of-scope-slice.stderr
+++ b/src/test/ui/parser/regions-out-of-scope-slice.stderr
@@ -1,5 +1,5 @@
 error: expected `:`, found `[`
-  --> $DIR/regions-out-of-scope-slice.rs:11:19
+  --> $DIR/regions-out-of-scope-slice.rs:9:19
    |
 LL |         x = &'blk [1,2,3]; //~ ERROR expected `:`, found `[`
    |                   ^ expected `:`
diff --git a/src/test/ui/parser/removed-syntax-closure-lifetime.rs b/src/test/ui/parser/removed-syntax-closure-lifetime.rs
index 50fde58..ceac940 100644
--- a/src/test/ui/parser/removed-syntax-closure-lifetime.rs
+++ b/src/test/ui/parser/removed-syntax-closure-lifetime.rs
@@ -1,4 +1,2 @@
-// compile-flags: -Z parse-only
-
 type closure = Box<lt/fn()>;
 //~^ ERROR expected one of `!`, `(`, `+`, `,`, `::`, `<`, or `>`, found `/`
diff --git a/src/test/ui/parser/removed-syntax-closure-lifetime.stderr b/src/test/ui/parser/removed-syntax-closure-lifetime.stderr
index 1ad4a48..f52988c 100644
--- a/src/test/ui/parser/removed-syntax-closure-lifetime.stderr
+++ b/src/test/ui/parser/removed-syntax-closure-lifetime.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `,`, `::`, `<`, or `>`, found `/`
-  --> $DIR/removed-syntax-closure-lifetime.rs:3:22
+  --> $DIR/removed-syntax-closure-lifetime.rs:1:22
    |
 LL | type closure = Box<lt/fn()>;
    |                      ^ expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/removed-syntax-enum-newtype.rs b/src/test/ui/parser/removed-syntax-enum-newtype.rs
index d8eb6c4..518f90b 100644
--- a/src/test/ui/parser/removed-syntax-enum-newtype.rs
+++ b/src/test/ui/parser/removed-syntax-enum-newtype.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 enum e = isize; //~ ERROR expected one of `<`, `where`, or `{`, found `=`
diff --git a/src/test/ui/parser/removed-syntax-enum-newtype.stderr b/src/test/ui/parser/removed-syntax-enum-newtype.stderr
index 2d9b3df..4c710de 100644
--- a/src/test/ui/parser/removed-syntax-enum-newtype.stderr
+++ b/src/test/ui/parser/removed-syntax-enum-newtype.stderr
@@ -1,5 +1,5 @@
 error: expected one of `<`, `where`, or `{`, found `=`
-  --> $DIR/removed-syntax-enum-newtype.rs:3:8
+  --> $DIR/removed-syntax-enum-newtype.rs:1:8
    |
 LL | enum e = isize; //~ ERROR expected one of `<`, `where`, or `{`, found `=`
    |        ^ expected one of `<`, `where`, or `{` here
diff --git a/src/test/ui/parser/removed-syntax-extern-const.rs b/src/test/ui/parser/removed-syntax-extern-const.rs
index c3dbd39..71c22e6 100644
--- a/src/test/ui/parser/removed-syntax-extern-const.rs
+++ b/src/test/ui/parser/removed-syntax-extern-const.rs
@@ -1,6 +1,6 @@
-// compile-flags: -Z parse-only
-
 extern {
     const i: isize;
     //~^ ERROR extern items cannot be `const`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/removed-syntax-extern-const.stderr b/src/test/ui/parser/removed-syntax-extern-const.stderr
index 9d8fefa..2bccbd9 100644
--- a/src/test/ui/parser/removed-syntax-extern-const.stderr
+++ b/src/test/ui/parser/removed-syntax-extern-const.stderr
@@ -1,5 +1,5 @@
 error: extern items cannot be `const`
-  --> $DIR/removed-syntax-extern-const.rs:4:5
+  --> $DIR/removed-syntax-extern-const.rs:2:5
    |
 LL |     const i: isize;
    |     ^^^^^ help: try using a static value: `static`
diff --git a/src/test/ui/parser/removed-syntax-field-let.rs b/src/test/ui/parser/removed-syntax-field-let.rs
index 70110bd..3412788 100644
--- a/src/test/ui/parser/removed-syntax-field-let.rs
+++ b/src/test/ui/parser/removed-syntax-field-let.rs
@@ -1,7 +1,9 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
-struct s {
+struct S {
     let foo: (),
     //~^  ERROR expected identifier, found keyword `let`
     //~^^ ERROR expected `:`, found `foo`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/removed-syntax-field-semicolon.rs b/src/test/ui/parser/removed-syntax-field-semicolon.rs
index 2ca6fbd..ac28e21 100644
--- a/src/test/ui/parser/removed-syntax-field-semicolon.rs
+++ b/src/test/ui/parser/removed-syntax-field-semicolon.rs
@@ -1,6 +1,6 @@
-// compile-flags: -Z parse-only
-
-struct s {
+struct S {
     bar: ();
     //~^ ERROR expected `,`, or `}`, found `;`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/removed-syntax-field-semicolon.stderr b/src/test/ui/parser/removed-syntax-field-semicolon.stderr
index f859ec6..fbefeb2 100644
--- a/src/test/ui/parser/removed-syntax-field-semicolon.stderr
+++ b/src/test/ui/parser/removed-syntax-field-semicolon.stderr
@@ -1,5 +1,5 @@
 error: expected `,`, or `}`, found `;`
-  --> $DIR/removed-syntax-field-semicolon.rs:4:12
+  --> $DIR/removed-syntax-field-semicolon.rs:2:12
    |
 LL |     bar: ();
    |            ^
diff --git a/src/test/ui/parser/removed-syntax-fixed-vec.rs b/src/test/ui/parser/removed-syntax-fixed-vec.rs
index 5f70c43..560efec 100644
--- a/src/test/ui/parser/removed-syntax-fixed-vec.rs
+++ b/src/test/ui/parser/removed-syntax-fixed-vec.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 type v = [isize * 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `*`
diff --git a/src/test/ui/parser/removed-syntax-fixed-vec.stderr b/src/test/ui/parser/removed-syntax-fixed-vec.stderr
index 8cbed9e..318591e 100644
--- a/src/test/ui/parser/removed-syntax-fixed-vec.stderr
+++ b/src/test/ui/parser/removed-syntax-fixed-vec.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `*`
-  --> $DIR/removed-syntax-fixed-vec.rs:3:17
+  --> $DIR/removed-syntax-fixed-vec.rs:1:17
    |
 LL | type v = [isize * 3]; //~ ERROR expected one of `!`, `(`, `+`, `::`, `;`, `<`, or `]`, found `*`
    |                 ^ expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/removed-syntax-fn-sigil.rs b/src/test/ui/parser/removed-syntax-fn-sigil.rs
index 77735f4..7258434 100644
--- a/src/test/ui/parser/removed-syntax-fn-sigil.rs
+++ b/src/test/ui/parser/removed-syntax-fn-sigil.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
-fn f() {
+fn main() {
     let x: fn~() = || (); //~ ERROR expected `(`, found `~`
 }
diff --git a/src/test/ui/parser/removed-syntax-fn-sigil.stderr b/src/test/ui/parser/removed-syntax-fn-sigil.stderr
index db5b634..9303a67 100644
--- a/src/test/ui/parser/removed-syntax-fn-sigil.stderr
+++ b/src/test/ui/parser/removed-syntax-fn-sigil.stderr
@@ -1,5 +1,5 @@
 error: expected `(`, found `~`
-  --> $DIR/removed-syntax-fn-sigil.rs:4:14
+  --> $DIR/removed-syntax-fn-sigil.rs:2:14
    |
 LL |     let x: fn~() = || (); //~ ERROR expected `(`, found `~`
    |         -    ^ expected `(`
diff --git a/src/test/ui/parser/removed-syntax-mode.rs b/src/test/ui/parser/removed-syntax-mode.rs
index ace8dc4..23851b5 100644
--- a/src/test/ui/parser/removed-syntax-mode.rs
+++ b/src/test/ui/parser/removed-syntax-mode.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn f(+x: isize) {}
 //~^ ERROR expected argument name, found `+`
+
+fn main() {}
diff --git a/src/test/ui/parser/removed-syntax-mode.stderr b/src/test/ui/parser/removed-syntax-mode.stderr
index 807b47b..5e7139d 100644
--- a/src/test/ui/parser/removed-syntax-mode.stderr
+++ b/src/test/ui/parser/removed-syntax-mode.stderr
@@ -1,5 +1,5 @@
 error: expected argument name, found `+`
-  --> $DIR/removed-syntax-mode.rs:3:6
+  --> $DIR/removed-syntax-mode.rs:1:6
    |
 LL | fn f(+x: isize) {}
    |      ^ expected argument name
diff --git a/src/test/ui/parser/removed-syntax-mut-vec-expr.rs b/src/test/ui/parser/removed-syntax-mut-vec-expr.rs
index f68a1bc..2ee95db 100644
--- a/src/test/ui/parser/removed-syntax-mut-vec-expr.rs
+++ b/src/test/ui/parser/removed-syntax-mut-vec-expr.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
-fn f() {
+fn main() {
     let v = [mut 1, 2, 3, 4]; //~ ERROR expected expression, found keyword `mut`
 }
diff --git a/src/test/ui/parser/removed-syntax-mut-vec-expr.stderr b/src/test/ui/parser/removed-syntax-mut-vec-expr.stderr
index 3995b6e..8164645 100644
--- a/src/test/ui/parser/removed-syntax-mut-vec-expr.stderr
+++ b/src/test/ui/parser/removed-syntax-mut-vec-expr.stderr
@@ -1,5 +1,5 @@
 error: expected expression, found keyword `mut`
-  --> $DIR/removed-syntax-mut-vec-expr.rs:4:14
+  --> $DIR/removed-syntax-mut-vec-expr.rs:2:14
    |
 LL |     let v = [mut 1, 2, 3, 4]; //~ ERROR expected expression, found keyword `mut`
    |              ^^^ expected expression
diff --git a/src/test/ui/parser/removed-syntax-mut-vec-ty.rs b/src/test/ui/parser/removed-syntax-mut-vec-ty.rs
index b492a86..923a7ea 100644
--- a/src/test/ui/parser/removed-syntax-mut-vec-ty.rs
+++ b/src/test/ui/parser/removed-syntax-mut-vec-ty.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 type v = [mut isize]; //~ ERROR expected type, found keyword `mut`
diff --git a/src/test/ui/parser/removed-syntax-mut-vec-ty.stderr b/src/test/ui/parser/removed-syntax-mut-vec-ty.stderr
index 513d896..f0eafa3 100644
--- a/src/test/ui/parser/removed-syntax-mut-vec-ty.stderr
+++ b/src/test/ui/parser/removed-syntax-mut-vec-ty.stderr
@@ -1,5 +1,5 @@
 error: expected type, found keyword `mut`
-  --> $DIR/removed-syntax-mut-vec-ty.rs:3:11
+  --> $DIR/removed-syntax-mut-vec-ty.rs:1:11
    |
 LL | type v = [mut isize]; //~ ERROR expected type, found keyword `mut`
    |           ^^^
diff --git a/src/test/ui/parser/removed-syntax-ptr-lifetime.rs b/src/test/ui/parser/removed-syntax-ptr-lifetime.rs
index 3457b96..5b551ad 100644
--- a/src/test/ui/parser/removed-syntax-ptr-lifetime.rs
+++ b/src/test/ui/parser/removed-syntax-ptr-lifetime.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 type bptr = &lifetime/isize; //~ ERROR expected one of `!`, `(`, `::`, `;`, or `<`, found `/`
diff --git a/src/test/ui/parser/removed-syntax-ptr-lifetime.stderr b/src/test/ui/parser/removed-syntax-ptr-lifetime.stderr
index 5b61315..689ed35 100644
--- a/src/test/ui/parser/removed-syntax-ptr-lifetime.stderr
+++ b/src/test/ui/parser/removed-syntax-ptr-lifetime.stderr
@@ -1,5 +1,5 @@
 error: expected one of `!`, `(`, `::`, `;`, or `<`, found `/`
-  --> $DIR/removed-syntax-ptr-lifetime.rs:3:22
+  --> $DIR/removed-syntax-ptr-lifetime.rs:1:22
    |
 LL | type bptr = &lifetime/isize; //~ ERROR expected one of `!`, `(`, `::`, `;`, or `<`, found `/`
    |                      ^ expected one of `!`, `(`, `::`, `;`, or `<` here
diff --git a/src/test/ui/parser/removed-syntax-record.rs b/src/test/ui/parser/removed-syntax-record.rs
index b16a741..d1d91c8 100644
--- a/src/test/ui/parser/removed-syntax-record.rs
+++ b/src/test/ui/parser/removed-syntax-record.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 type t = { f: () }; //~ ERROR expected type, found `{`
diff --git a/src/test/ui/parser/removed-syntax-record.stderr b/src/test/ui/parser/removed-syntax-record.stderr
index 13dfc3d..f9b9859 100644
--- a/src/test/ui/parser/removed-syntax-record.stderr
+++ b/src/test/ui/parser/removed-syntax-record.stderr
@@ -1,5 +1,5 @@
 error: expected type, found `{`
-  --> $DIR/removed-syntax-record.rs:3:10
+  --> $DIR/removed-syntax-record.rs:1:10
    |
 LL | type t = { f: () }; //~ ERROR expected type, found `{`
    |          ^
diff --git a/src/test/ui/parser/removed-syntax-static-fn.rs b/src/test/ui/parser/removed-syntax-static-fn.rs
index 3cb1cd4..df39641 100644
--- a/src/test/ui/parser/removed-syntax-static-fn.rs
+++ b/src/test/ui/parser/removed-syntax-static-fn.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Z parse-only
 // ignore-tidy-linelength
 
 struct S;
@@ -7,3 +6,5 @@
     static fn f() {}
 }
 //~^^ ERROR expected one of `async`, `const`, `crate`, `default`, `existential`, `extern`, `fn`, `pub`, `type`,
+
+fn main() {}
diff --git a/src/test/ui/parser/removed-syntax-static-fn.stderr b/src/test/ui/parser/removed-syntax-static-fn.stderr
index ab42e0b..84e0432 100644
--- a/src/test/ui/parser/removed-syntax-static-fn.stderr
+++ b/src/test/ui/parser/removed-syntax-static-fn.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `crate`, `default`, `existential`, `extern`, `fn`, `pub`, `type`, `unsafe`, or `}`, found `static`
-  --> $DIR/removed-syntax-static-fn.rs:7:5
+  --> $DIR/removed-syntax-static-fn.rs:6:5
    |
 LL | impl S {
    |         - expected one of 11 possible tokens here
diff --git a/src/test/ui/parser/removed-syntax-uniq-mut-expr.rs b/src/test/ui/parser/removed-syntax-uniq-mut-expr.rs
index 95166bd..08ef4b4 100644
--- a/src/test/ui/parser/removed-syntax-uniq-mut-expr.rs
+++ b/src/test/ui/parser/removed-syntax-uniq-mut-expr.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
-fn f() {
+fn main() {
     let a_box = box mut 42; //~ ERROR expected expression, found keyword `mut`
 }
diff --git a/src/test/ui/parser/removed-syntax-uniq-mut-expr.stderr b/src/test/ui/parser/removed-syntax-uniq-mut-expr.stderr
index 8b2dbb3..90d0764 100644
--- a/src/test/ui/parser/removed-syntax-uniq-mut-expr.stderr
+++ b/src/test/ui/parser/removed-syntax-uniq-mut-expr.stderr
@@ -1,5 +1,5 @@
 error: expected expression, found keyword `mut`
-  --> $DIR/removed-syntax-uniq-mut-expr.rs:4:21
+  --> $DIR/removed-syntax-uniq-mut-expr.rs:2:21
    |
 LL |     let a_box = box mut 42; //~ ERROR expected expression, found keyword `mut`
    |                     ^^^ expected expression
diff --git a/src/test/ui/parser/removed-syntax-uniq-mut-ty.rs b/src/test/ui/parser/removed-syntax-uniq-mut-ty.rs
index 7d9b8af..12de76d 100644
--- a/src/test/ui/parser/removed-syntax-uniq-mut-ty.rs
+++ b/src/test/ui/parser/removed-syntax-uniq-mut-ty.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 type mut_box = Box<mut isize>; //~ ERROR expected one of `>`, lifetime, or type, found `mut`
diff --git a/src/test/ui/parser/removed-syntax-uniq-mut-ty.stderr b/src/test/ui/parser/removed-syntax-uniq-mut-ty.stderr
index dc16082..0177b19 100644
--- a/src/test/ui/parser/removed-syntax-uniq-mut-ty.stderr
+++ b/src/test/ui/parser/removed-syntax-uniq-mut-ty.stderr
@@ -1,5 +1,5 @@
 error: expected one of `>`, lifetime, or type, found `mut`
-  --> $DIR/removed-syntax-uniq-mut-ty.rs:3:20
+  --> $DIR/removed-syntax-uniq-mut-ty.rs:1:20
    |
 LL | type mut_box = Box<mut isize>; //~ ERROR expected one of `>`, lifetime, or type, found `mut`
    |                    ^^^ expected one of `>`, lifetime, or type here
diff --git a/src/test/ui/parser/removed-syntax-with-1.rs b/src/test/ui/parser/removed-syntax-with-1.rs
index a08baf6..57cbe8d 100644
--- a/src/test/ui/parser/removed-syntax-with-1.rs
+++ b/src/test/ui/parser/removed-syntax-with-1.rs
@@ -1,6 +1,4 @@
-// compile-flags: -Z parse-only
-
-fn removed_with() {
+fn main() {
     struct S {
         foo: (),
         bar: (),
@@ -9,4 +7,5 @@
     let a = S { foo: (), bar: () };
     let b = S { foo: () with a };
     //~^ ERROR expected one of `,`, `.`, `?`, `}`, or an operator, found `with`
+    //~| ERROR missing field `bar` in initializer of `main::S`
 }
diff --git a/src/test/ui/parser/removed-syntax-with-1.stderr b/src/test/ui/parser/removed-syntax-with-1.stderr
index 6a69cdf..77ed4fc 100644
--- a/src/test/ui/parser/removed-syntax-with-1.stderr
+++ b/src/test/ui/parser/removed-syntax-with-1.stderr
@@ -1,8 +1,15 @@
 error: expected one of `,`, `.`, `?`, `}`, or an operator, found `with`
-  --> $DIR/removed-syntax-with-1.rs:10:25
+  --> $DIR/removed-syntax-with-1.rs:8:25
    |
 LL |     let b = S { foo: () with a };
    |                         ^^^^ expected one of `,`, `.`, `?`, `}`, or an operator here
 
-error: aborting due to previous error
+error[E0063]: missing field `bar` in initializer of `main::S`
+  --> $DIR/removed-syntax-with-1.rs:8:13
+   |
+LL |     let b = S { foo: () with a };
+   |             ^ missing `bar`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0063`.
diff --git a/src/test/ui/parser/removed-syntax-with-2.rs b/src/test/ui/parser/removed-syntax-with-2.rs
index 22b9ba2..11db391 100644
--- a/src/test/ui/parser/removed-syntax-with-2.rs
+++ b/src/test/ui/parser/removed-syntax-with-2.rs
@@ -1,6 +1,4 @@
-// compile-flags: -Z parse-only
-
-fn removed_with() {
+fn main() {
     struct S {
         foo: (),
         bar: (),
@@ -9,4 +7,6 @@
     let a = S { foo: (), bar: () };
     let b = S { foo: (), with a };
     //~^ ERROR expected one of `,` or `}`, found `a`
+    //~| ERROR cannot find value `with` in this scope
+    //~| ERROR struct `main::S` has no field named `with`
 }
diff --git a/src/test/ui/parser/removed-syntax-with-2.stderr b/src/test/ui/parser/removed-syntax-with-2.stderr
index ade56ef..5642d2f 100644
--- a/src/test/ui/parser/removed-syntax-with-2.stderr
+++ b/src/test/ui/parser/removed-syntax-with-2.stderr
@@ -1,8 +1,24 @@
 error: expected one of `,` or `}`, found `a`
-  --> $DIR/removed-syntax-with-2.rs:10:31
+  --> $DIR/removed-syntax-with-2.rs:8:31
    |
 LL |     let b = S { foo: (), with a };
    |                               ^ expected one of `,` or `}` here
 
-error: aborting due to previous error
+error[E0425]: cannot find value `with` in this scope
+  --> $DIR/removed-syntax-with-2.rs:8:26
+   |
+LL |     let b = S { foo: (), with a };
+   |                          ^^^^ not found in this scope
 
+error[E0560]: struct `main::S` has no field named `with`
+  --> $DIR/removed-syntax-with-2.rs:8:26
+   |
+LL |     let b = S { foo: (), with a };
+   |                          ^^^^ `main::S` does not have this field
+   |
+   = note: available fields are: `foo`, `bar`
+
+error: aborting due to 3 previous errors
+
+Some errors occurred: E0425, E0560.
+For more information about an error, try `rustc --explain E0425`.
diff --git a/src/test/ui/parser/require-parens-for-chained-comparison.rs b/src/test/ui/parser/require-parens-for-chained-comparison.rs
index 912da96..525be5d 100644
--- a/src/test/ui/parser/require-parens-for-chained-comparison.rs
+++ b/src/test/ui/parser/require-parens-for-chained-comparison.rs
@@ -1,6 +1,5 @@
-// compile-flags: -Z parse-only
-
 fn f<T>() {}
+struct X;
 
 fn main() {
     false == false == false;
@@ -8,9 +7,12 @@
 
     false == 0 < 2;
     //~^ ERROR: chained comparison operators require parentheses
+    //~| ERROR: mismatched types
+    //~| ERROR: mismatched types
 
     f<X>();
     //~^ ERROR: chained comparison operators require parentheses
+    //~| ERROR: binary operation `<` cannot be applied to type `fn() {f::<_>}`
     //~| HELP: use `::<...>` instead of `<...>`
     //~| HELP: or use `(...)`
 }
diff --git a/src/test/ui/parser/require-parens-for-chained-comparison.stderr b/src/test/ui/parser/require-parens-for-chained-comparison.stderr
index ca33ed9..4597b14 100644
--- a/src/test/ui/parser/require-parens-for-chained-comparison.stderr
+++ b/src/test/ui/parser/require-parens-for-chained-comparison.stderr
@@ -1,17 +1,17 @@
 error: chained comparison operators require parentheses
-  --> $DIR/require-parens-for-chained-comparison.rs:6:11
+  --> $DIR/require-parens-for-chained-comparison.rs:5:11
    |
 LL |     false == false == false;
    |           ^^^^^^^^^^^^^^^^^
 
 error: chained comparison operators require parentheses
-  --> $DIR/require-parens-for-chained-comparison.rs:9:11
+  --> $DIR/require-parens-for-chained-comparison.rs:8:11
    |
 LL |     false == 0 < 2;
    |           ^^^^^^^^
 
 error: chained comparison operators require parentheses
-  --> $DIR/require-parens-for-chained-comparison.rs:12:6
+  --> $DIR/require-parens-for-chained-comparison.rs:13:6
    |
 LL |     f<X>();
    |      ^^^^
@@ -19,5 +19,33 @@
    = help: use `::<...>` instead of `<...>` if you meant to specify type arguments
    = help: or use `(...)` if you meant to specify fn arguments
 
-error: aborting due to 3 previous errors
+error[E0308]: mismatched types
+  --> $DIR/require-parens-for-chained-comparison.rs:8:14
+   |
+LL |     false == 0 < 2;
+   |              ^ expected bool, found integer
+   |
+   = note: expected type `bool`
+              found type `{integer}`
 
+error[E0308]: mismatched types
+  --> $DIR/require-parens-for-chained-comparison.rs:8:18
+   |
+LL |     false == 0 < 2;
+   |                  ^ expected bool, found integer
+   |
+   = note: expected type `bool`
+              found type `{integer}`
+
+error[E0369]: binary operation `<` cannot be applied to type `fn() {f::<_>}`
+  --> $DIR/require-parens-for-chained-comparison.rs:13:5
+   |
+LL |     f<X>();
+   |     ^^^
+   |
+   = note: an implementation of `std::cmp::PartialOrd` might be missing for `fn() {f::<_>}`
+
+error: aborting due to 6 previous errors
+
+Some errors occurred: E0308, E0369.
+For more information about an error, try `rustc --explain E0308`.
diff --git a/src/test/ui/parser/struct-field-numeric-shorthand.rs b/src/test/ui/parser/struct-field-numeric-shorthand.rs
index a6ed6fc..914588f 100644
--- a/src/test/ui/parser/struct-field-numeric-shorthand.rs
+++ b/src/test/ui/parser/struct-field-numeric-shorthand.rs
@@ -1,7 +1,6 @@
-// compile-flags: -Z parse-only
-
 struct Rgb(u8, u8, u8);
 
 fn main() {
     let _ = Rgb { 0, 1, 2 }; //~ ERROR expected identifier, found `0`
+                             //~| ERROR missing fields `0`, `1`, `2` in initializer of `Rgb`
 }
diff --git a/src/test/ui/parser/struct-field-numeric-shorthand.stderr b/src/test/ui/parser/struct-field-numeric-shorthand.stderr
index 29fc654..f5dc226 100644
--- a/src/test/ui/parser/struct-field-numeric-shorthand.stderr
+++ b/src/test/ui/parser/struct-field-numeric-shorthand.stderr
@@ -1,10 +1,17 @@
 error: expected identifier, found `0`
-  --> $DIR/struct-field-numeric-shorthand.rs:6:19
+  --> $DIR/struct-field-numeric-shorthand.rs:4:19
    |
 LL |     let _ = Rgb { 0, 1, 2 }; //~ ERROR expected identifier, found `0`
    |             ---   ^ expected identifier
    |             |
    |             while parsing this struct
 
-error: aborting due to previous error
+error[E0063]: missing fields `0`, `1`, `2` in initializer of `Rgb`
+  --> $DIR/struct-field-numeric-shorthand.rs:4:13
+   |
+LL |     let _ = Rgb { 0, 1, 2 }; //~ ERROR expected identifier, found `0`
+   |             ^^^ missing `0`, `1`, `2`
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0063`.
diff --git a/src/test/ui/parser/struct-literal-in-for.rs b/src/test/ui/parser/struct-literal-in-for.rs
index 0dec3d3..526b5e7 100644
--- a/src/test/ui/parser/struct-literal-in-for.rs
+++ b/src/test/ui/parser/struct-literal-in-for.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo {
     x: isize,
 }
@@ -11,7 +9,7 @@
 }
 
 fn main() {
-    for x in Foo {
+    for x in Foo { //~ ERROR expected value, found struct `Foo`
         x: 3    //~ ERROR expected type, found `3`
     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
         println!("yo");
diff --git a/src/test/ui/parser/struct-literal-in-for.stderr b/src/test/ui/parser/struct-literal-in-for.stderr
index 3117fdc..38a5e22 100644
--- a/src/test/ui/parser/struct-literal-in-for.stderr
+++ b/src/test/ui/parser/struct-literal-in-for.stderr
@@ -1,14 +1,21 @@
 error: expected type, found `3`
-  --> $DIR/struct-literal-in-for.rs:15:12
+  --> $DIR/struct-literal-in-for.rs:13:12
    |
 LL |         x: 3    //~ ERROR expected type, found `3`
    |            ^ expecting a type here because of type ascription
 
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
-  --> $DIR/struct-literal-in-for.rs:16:12
+  --> $DIR/struct-literal-in-for.rs:14:12
    |
 LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
    |            ^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to 2 previous errors
+error[E0423]: expected value, found struct `Foo`
+  --> $DIR/struct-literal-in-for.rs:12:14
+   |
+LL |     for x in Foo { //~ ERROR expected value, found struct `Foo`
+   |              ^^^ did you mean `(Foo { /* fields */ })`?
 
+error: aborting due to 3 previous errors
+
+For more information about this error, try `rustc --explain E0423`.
diff --git a/src/test/ui/parser/struct-literal-in-if.rs b/src/test/ui/parser/struct-literal-in-if.rs
index f69b9b1..362a71c 100644
--- a/src/test/ui/parser/struct-literal-in-if.rs
+++ b/src/test/ui/parser/struct-literal-in-if.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo {
     x: isize,
 }
@@ -11,7 +9,7 @@
 }
 
 fn main() {
-    if Foo {
+    if Foo { //~ ERROR expected value, found struct `Foo`
         x: 3    //~ ERROR expected type, found `3`
     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
         println!("yo");
diff --git a/src/test/ui/parser/struct-literal-in-if.stderr b/src/test/ui/parser/struct-literal-in-if.stderr
index 55018a8..49b9a52 100644
--- a/src/test/ui/parser/struct-literal-in-if.stderr
+++ b/src/test/ui/parser/struct-literal-in-if.stderr
@@ -1,14 +1,21 @@
 error: expected type, found `3`
-  --> $DIR/struct-literal-in-if.rs:15:12
+  --> $DIR/struct-literal-in-if.rs:13:12
    |
 LL |         x: 3    //~ ERROR expected type, found `3`
    |            ^ expecting a type here because of type ascription
 
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
-  --> $DIR/struct-literal-in-if.rs:16:12
+  --> $DIR/struct-literal-in-if.rs:14:12
    |
 LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
    |            ^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to 2 previous errors
+error[E0423]: expected value, found struct `Foo`
+  --> $DIR/struct-literal-in-if.rs:12:8
+   |
+LL |     if Foo { //~ ERROR expected value, found struct `Foo`
+   |        ^^^ did you mean `(Foo { /* fields */ })`?
 
+error: aborting due to 3 previous errors
+
+For more information about this error, try `rustc --explain E0423`.
diff --git a/src/test/ui/parser/struct-literal-in-match-discriminant.rs b/src/test/ui/parser/struct-literal-in-match-discriminant.rs
index d14276f..35a1109 100644
--- a/src/test/ui/parser/struct-literal-in-match-discriminant.rs
+++ b/src/test/ui/parser/struct-literal-in-match-discriminant.rs
@@ -1,15 +1,13 @@
-// compile-flags: -Z parse-only
-
 struct Foo {
     x: isize,
 }
 
 fn main() {
-    match Foo {
+    match Foo { //~ ERROR expected value, found struct `Foo`
         x: 3    //~ ERROR expected one of `=>`, `@`, `if`, or `|`, found `:`
     } {
-        Foo {
-            x: x
+        Foo { //~ ERROR mismatched types
+            x: x //~ ERROR cannot find value `x` in this scope
         } => {} //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `=>`
     }
 }
diff --git a/src/test/ui/parser/struct-literal-in-match-discriminant.stderr b/src/test/ui/parser/struct-literal-in-match-discriminant.stderr
index 680258b..64ddde0 100644
--- a/src/test/ui/parser/struct-literal-in-match-discriminant.stderr
+++ b/src/test/ui/parser/struct-literal-in-match-discriminant.stderr
@@ -1,14 +1,42 @@
 error: expected one of `=>`, `@`, `if`, or `|`, found `:`
-  --> $DIR/struct-literal-in-match-discriminant.rs:9:10
+  --> $DIR/struct-literal-in-match-discriminant.rs:7:10
    |
 LL |         x: 3    //~ ERROR expected one of `=>`, `@`, `if`, or `|`, found `:`
    |          ^ expected one of `=>`, `@`, `if`, or `|` here
 
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `=>`
-  --> $DIR/struct-literal-in-match-discriminant.rs:13:11
+  --> $DIR/struct-literal-in-match-discriminant.rs:11:11
    |
 LL |         } => {} //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `=>`
    |           ^^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to 2 previous errors
+error[E0423]: expected value, found struct `Foo`
+  --> $DIR/struct-literal-in-match-discriminant.rs:6:11
+   |
+LL |     match Foo { //~ ERROR expected value, found struct `Foo`
+   |           ^^^ did you mean `(Foo { /* fields */ })`?
 
+error[E0425]: cannot find value `x` in this scope
+  --> $DIR/struct-literal-in-match-discriminant.rs:10:16
+   |
+LL |             x: x //~ ERROR cannot find value `x` in this scope
+   |                ^ not found in this scope
+
+error[E0308]: mismatched types
+  --> $DIR/struct-literal-in-match-discriminant.rs:9:9
+   |
+LL |   fn main() {
+   |             - expected `()` because of default return type
+...
+LL | /         Foo { //~ ERROR mismatched types
+LL | |             x: x //~ ERROR cannot find value `x` in this scope
+LL | |         } => {} //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `=>`
+   | |_________^ expected (), found struct `Foo`
+   |
+   = note: expected type `()`
+              found type `Foo`
+
+error: aborting due to 5 previous errors
+
+Some errors occurred: E0308, E0423, E0425.
+For more information about an error, try `rustc --explain E0308`.
diff --git a/src/test/ui/parser/struct-literal-in-while.rs b/src/test/ui/parser/struct-literal-in-while.rs
index cd3e640..561cdce 100644
--- a/src/test/ui/parser/struct-literal-in-while.rs
+++ b/src/test/ui/parser/struct-literal-in-while.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo {
     x: isize,
 }
@@ -11,9 +9,10 @@
 }
 
 fn main() {
-    while Foo {
+    while Foo { //~ ERROR expected value, found struct `Foo`
         x: 3    //~ ERROR expected type, found `3`
     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
+             //~| ERROR no method named `hi` found for type `()` in the current scope
         println!("yo");
     }
 }
diff --git a/src/test/ui/parser/struct-literal-in-while.stderr b/src/test/ui/parser/struct-literal-in-while.stderr
index 4de05f0..9a6ab81 100644
--- a/src/test/ui/parser/struct-literal-in-while.stderr
+++ b/src/test/ui/parser/struct-literal-in-while.stderr
@@ -1,14 +1,28 @@
 error: expected type, found `3`
-  --> $DIR/struct-literal-in-while.rs:15:12
+  --> $DIR/struct-literal-in-while.rs:13:12
    |
 LL |         x: 3    //~ ERROR expected type, found `3`
    |            ^ expecting a type here because of type ascription
 
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
-  --> $DIR/struct-literal-in-while.rs:16:12
+  --> $DIR/struct-literal-in-while.rs:14:12
    |
 LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
    |            ^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to 2 previous errors
+error[E0423]: expected value, found struct `Foo`
+  --> $DIR/struct-literal-in-while.rs:12:11
+   |
+LL |     while Foo { //~ ERROR expected value, found struct `Foo`
+   |           ^^^ did you mean `(Foo { /* fields */ })`?
 
+error[E0599]: no method named `hi` found for type `()` in the current scope
+  --> $DIR/struct-literal-in-while.rs:14:7
+   |
+LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
+   |       ^^
+
+error: aborting due to 4 previous errors
+
+Some errors occurred: E0423, E0599.
+For more information about an error, try `rustc --explain E0423`.
diff --git a/src/test/ui/parser/struct-literal-restrictions-in-lamda.rs b/src/test/ui/parser/struct-literal-restrictions-in-lamda.rs
index 743b773..e504908 100644
--- a/src/test/ui/parser/struct-literal-restrictions-in-lamda.rs
+++ b/src/test/ui/parser/struct-literal-restrictions-in-lamda.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct Foo {
     x: isize,
 }
@@ -11,9 +9,10 @@
 }
 
 fn main() {
-    while || Foo {
+    while || Foo { //~ ERROR expected value, found struct `Foo`
         x: 3    //~ ERROR expected type, found `3`
     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
+             //~| ERROR no method named `hi` found for type `()` in the current scope
         println!("yo");
     }
 }
diff --git a/src/test/ui/parser/struct-literal-restrictions-in-lamda.stderr b/src/test/ui/parser/struct-literal-restrictions-in-lamda.stderr
index 0968009..2303df9 100644
--- a/src/test/ui/parser/struct-literal-restrictions-in-lamda.stderr
+++ b/src/test/ui/parser/struct-literal-restrictions-in-lamda.stderr
@@ -1,14 +1,28 @@
 error: expected type, found `3`
-  --> $DIR/struct-literal-restrictions-in-lamda.rs:15:12
+  --> $DIR/struct-literal-restrictions-in-lamda.rs:13:12
    |
 LL |         x: 3    //~ ERROR expected type, found `3`
    |            ^ expecting a type here because of type ascription
 
 error: expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
-  --> $DIR/struct-literal-restrictions-in-lamda.rs:16:12
+  --> $DIR/struct-literal-restrictions-in-lamda.rs:14:12
    |
 LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
    |            ^ expected one of `.`, `;`, `?`, `}`, or an operator here
 
-error: aborting due to 2 previous errors
+error[E0423]: expected value, found struct `Foo`
+  --> $DIR/struct-literal-restrictions-in-lamda.rs:12:14
+   |
+LL |     while || Foo { //~ ERROR expected value, found struct `Foo`
+   |              ^^^ did you mean `(Foo { /* fields */ })`?
 
+error[E0599]: no method named `hi` found for type `()` in the current scope
+  --> $DIR/struct-literal-restrictions-in-lamda.rs:14:7
+   |
+LL |     }.hi() { //~ ERROR expected one of `.`, `;`, `?`, `}`, or an operator, found `{`
+   |       ^^
+
+error: aborting due to 4 previous errors
+
+Some errors occurred: E0423, E0599.
+For more information about an error, try `rustc --explain E0423`.
diff --git a/src/test/ui/parser/tag-variant-disr-non-nullary.rs b/src/test/ui/parser/tag-variant-disr-non-nullary.rs
index 55ab871..35a36cb 100644
--- a/src/test/ui/parser/tag-variant-disr-non-nullary.rs
+++ b/src/test/ui/parser/tag-variant-disr-non-nullary.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 //error-pattern: discriminator values can only be used with a field-less enum
 
 enum color {
@@ -10,3 +8,5 @@
     white = 0xffffff,
     other (str),
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/tag-variant-disr-non-nullary.stderr b/src/test/ui/parser/tag-variant-disr-non-nullary.stderr
index 6bb393a..aa45ea4 100644
--- a/src/test/ui/parser/tag-variant-disr-non-nullary.stderr
+++ b/src/test/ui/parser/tag-variant-disr-non-nullary.stderr
@@ -1,5 +1,5 @@
 error: discriminator values can only be used with a field-less enum
-  --> $DIR/tag-variant-disr-non-nullary.rs:10:13
+  --> $DIR/tag-variant-disr-non-nullary.rs:8:13
    |
 LL |     white = 0xffffff,
    |             ^^^^^^^^
diff --git a/src/test/ui/parser/trailing-carriage-return-in-string.rs b/src/test/ui/parser/trailing-carriage-return-in-string.rs
index cbc9195..8abf262 100644
--- a/src/test/ui/parser/trailing-carriage-return-in-string.rs
+++ b/src/test/ui/parser/trailing-carriage-return-in-string.rs
Binary files differ
diff --git a/src/test/ui/parser/trailing-carriage-return-in-string.stderr b/src/test/ui/parser/trailing-carriage-return-in-string.stderr
index d019bc7..972e429 100644
--- a/src/test/ui/parser/trailing-carriage-return-in-string.stderr
+++ b/src/test/ui/parser/trailing-carriage-return-in-string.stderr
Binary files differ
diff --git a/src/test/ui/parser/trailing-plus-in-bounds.rs b/src/test/ui/parser/trailing-plus-in-bounds.rs
index 1204f05..153f942 100644
--- a/src/test/ui/parser/trailing-plus-in-bounds.rs
+++ b/src/test/ui/parser/trailing-plus-in-bounds.rs
@@ -1,5 +1,7 @@
 // compile-pass
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
+
+#![feature(box_syntax)]
 
 use std::fmt::Debug;
 
diff --git a/src/test/ui/parser/trait-bounds-not-on-impl.rs b/src/test/ui/parser/trait-bounds-not-on-impl.rs
index f89dbb0..d77ff80 100644
--- a/src/test/ui/parser/trait-bounds-not-on-impl.rs
+++ b/src/test/ui/parser/trait-bounds-not-on-impl.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 trait Foo {
 }
diff --git a/src/test/ui/parser/trait-object-bad-parens.rs b/src/test/ui/parser/trait-object-bad-parens.rs
index 4d732b3..0f1f49a 100644
--- a/src/test/ui/parser/trait-object-bad-parens.rs
+++ b/src/test/ui/parser/trait-object-bad-parens.rs
@@ -1,12 +1,16 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
+
+#![feature(optin_builtin_traits)]
+
+auto trait Auto {}
 
 fn main() {
-    let _: Box<((Copy)) + Copy>;
-    //~^ ERROR expected a path on the left-hand side of `+`, not `((Copy))`
-    let _: Box<(Copy + Copy) + Copy>;
-    //~^ ERROR expected a path on the left-hand side of `+`, not `(Copy + Copy)`
-    let _: Box<(Copy +) + Copy>;
-    //~^ ERROR expected a path on the left-hand side of `+`, not `(Copy)`
-    let _: Box<(dyn Copy) + Copy>;
-    //~^ ERROR expected a path on the left-hand side of `+`, not `(dyn Copy)`
+    let _: Box<((Auto)) + Auto>;
+    //~^ ERROR expected a path on the left-hand side of `+`, not `((Auto))`
+    let _: Box<(Auto + Auto) + Auto>;
+    //~^ ERROR expected a path on the left-hand side of `+`, not `(Auto + Auto)`
+    let _: Box<(Auto +) + Auto>;
+    //~^ ERROR expected a path on the left-hand side of `+`, not `(Auto)`
+    let _: Box<(dyn Auto) + Auto>;
+    //~^ ERROR expected a path on the left-hand side of `+`, not `(dyn Auto)`
 }
diff --git a/src/test/ui/parser/trait-object-bad-parens.stderr b/src/test/ui/parser/trait-object-bad-parens.stderr
index e9f1dc5..74e484e 100644
--- a/src/test/ui/parser/trait-object-bad-parens.stderr
+++ b/src/test/ui/parser/trait-object-bad-parens.stderr
@@ -1,25 +1,25 @@
-error[E0178]: expected a path on the left-hand side of `+`, not `((Copy))`
-  --> $DIR/trait-object-bad-parens.rs:4:16
-   |
-LL |     let _: Box<((Copy)) + Copy>;
-   |                ^^^^^^^^^^^^^^^ expected a path
-
-error[E0178]: expected a path on the left-hand side of `+`, not `(Copy + Copy)`
-  --> $DIR/trait-object-bad-parens.rs:6:16
-   |
-LL |     let _: Box<(Copy + Copy) + Copy>;
-   |                ^^^^^^^^^^^^^^^^^^^^ expected a path
-
-error[E0178]: expected a path on the left-hand side of `+`, not `(Copy)`
+error[E0178]: expected a path on the left-hand side of `+`, not `((Auto))`
   --> $DIR/trait-object-bad-parens.rs:8:16
    |
-LL |     let _: Box<(Copy +) + Copy>;
+LL |     let _: Box<((Auto)) + Auto>;
    |                ^^^^^^^^^^^^^^^ expected a path
 
-error[E0178]: expected a path on the left-hand side of `+`, not `(dyn Copy)`
+error[E0178]: expected a path on the left-hand side of `+`, not `(Auto + Auto)`
   --> $DIR/trait-object-bad-parens.rs:10:16
    |
-LL |     let _: Box<(dyn Copy) + Copy>;
+LL |     let _: Box<(Auto + Auto) + Auto>;
+   |                ^^^^^^^^^^^^^^^^^^^^ expected a path
+
+error[E0178]: expected a path on the left-hand side of `+`, not `(Auto)`
+  --> $DIR/trait-object-bad-parens.rs:12:16
+   |
+LL |     let _: Box<(Auto +) + Auto>;
+   |                ^^^^^^^^^^^^^^^ expected a path
+
+error[E0178]: expected a path on the left-hand side of `+`, not `(dyn Auto)`
+  --> $DIR/trait-object-bad-parens.rs:14:16
+   |
+LL |     let _: Box<(dyn Auto) + Auto>;
    |                ^^^^^^^^^^^^^^^^^ expected a path
 
 error: aborting due to 4 previous errors
diff --git a/src/test/ui/parser/trait-object-lifetime-parens.rs b/src/test/ui/parser/trait-object-lifetime-parens.rs
index fef8352..b188e14 100644
--- a/src/test/ui/parser/trait-object-lifetime-parens.rs
+++ b/src/test/ui/parser/trait-object-lifetime-parens.rs
@@ -1,8 +1,12 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
-fn f<T: Copy + ('a)>() {} //~ ERROR parenthesized lifetime bounds are not supported
+trait Trait {}
 
-fn main() {
-    let _: Box<Copy + ('a)>; //~ ERROR parenthesized lifetime bounds are not supported
-    let _: Box<('a) + Copy>; //~ ERROR expected type, found `'a`
+fn f<'a, T: Trait + ('a)>() {} //~ ERROR parenthesized lifetime bounds are not supported
+
+fn check<'a>() {
+    let _: Box<Trait + ('a)>; //~ ERROR parenthesized lifetime bounds are not supported
+    let _: Box<('a) + Trait>; //~ ERROR expected type, found `'a`
 }
+
+fn main() {}
diff --git a/src/test/ui/parser/trait-object-lifetime-parens.stderr b/src/test/ui/parser/trait-object-lifetime-parens.stderr
index e5a201a..a9b542d 100644
--- a/src/test/ui/parser/trait-object-lifetime-parens.stderr
+++ b/src/test/ui/parser/trait-object-lifetime-parens.stderr
@@ -1,19 +1,19 @@
 error: parenthesized lifetime bounds are not supported
-  --> $DIR/trait-object-lifetime-parens.rs:3:19
+  --> $DIR/trait-object-lifetime-parens.rs:5:24
    |
-LL | fn f<T: Copy + ('a)>() {} //~ ERROR parenthesized lifetime bounds are not supported
-   |                   ^
+LL | fn f<'a, T: Trait + ('a)>() {} //~ ERROR parenthesized lifetime bounds are not supported
+   |                        ^
 
 error: parenthesized lifetime bounds are not supported
-  --> $DIR/trait-object-lifetime-parens.rs:6:26
+  --> $DIR/trait-object-lifetime-parens.rs:8:27
    |
-LL |     let _: Box<Copy + ('a)>; //~ ERROR parenthesized lifetime bounds are not supported
-   |                          ^
+LL |     let _: Box<Trait + ('a)>; //~ ERROR parenthesized lifetime bounds are not supported
+   |                           ^
 
 error: expected type, found `'a`
-  --> $DIR/trait-object-lifetime-parens.rs:7:17
+  --> $DIR/trait-object-lifetime-parens.rs:9:17
    |
-LL |     let _: Box<('a) + Copy>; //~ ERROR expected type, found `'a`
+LL |     let _: Box<('a) + Trait>; //~ ERROR expected type, found `'a`
    |         -       ^^
    |         |
    |         while parsing the type for `_`
diff --git a/src/test/ui/parser/trait-object-polytrait-priority.rs b/src/test/ui/parser/trait-object-polytrait-priority.rs
index e08c3bc..40d2ad5 100644
--- a/src/test/ui/parser/trait-object-polytrait-priority.rs
+++ b/src/test/ui/parser/trait-object-polytrait-priority.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait Trait<'a> {}
 
 fn main() {
diff --git a/src/test/ui/parser/trait-object-polytrait-priority.stderr b/src/test/ui/parser/trait-object-polytrait-priority.stderr
index a6add60..5e2a35e 100644
--- a/src/test/ui/parser/trait-object-polytrait-priority.stderr
+++ b/src/test/ui/parser/trait-object-polytrait-priority.stderr
@@ -1,5 +1,5 @@
 error[E0178]: expected a path on the left-hand side of `+`, not `&for<'a> Trait<'a>`
-  --> $DIR/trait-object-polytrait-priority.rs:6:12
+  --> $DIR/trait-object-polytrait-priority.rs:4:12
    |
 LL |     let _: &for<'a> Trait<'a> + 'static;
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try adding parentheses: `&(for<'a> Trait<'a> + 'static)`
diff --git a/src/test/ui/parser/trait-object-trait-parens.rs b/src/test/ui/parser/trait-object-trait-parens.rs
index 3802d35..2bbc580 100644
--- a/src/test/ui/parser/trait-object-trait-parens.rs
+++ b/src/test/ui/parser/trait-object-trait-parens.rs
@@ -1,10 +1,12 @@
-// compile-pass
-// compile-flags: -Z parse-only
+trait Trait<'a> {}
 
 fn f<T: (Copy) + (?Sized) + (for<'a> Trait<'a>)>() {}
 
 fn main() {
     let _: Box<(Copy) + (?Sized) + (for<'a> Trait<'a>)>;
+    //~^ ERROR `?Trait` is not permitted in trait object types
     let _: Box<(?Sized) + (for<'a> Trait<'a>) + (Copy)>;
     let _: Box<(for<'a> Trait<'a>) + (Copy) + (?Sized)>;
+    //~^ ERROR `?Trait` is not permitted in trait object types
+    //~| ERROR use of undeclared lifetime name `'a`
 }
diff --git a/src/test/ui/parser/trait-object-trait-parens.stderr b/src/test/ui/parser/trait-object-trait-parens.stderr
new file mode 100644
index 0000000..36494b7
--- /dev/null
+++ b/src/test/ui/parser/trait-object-trait-parens.stderr
@@ -0,0 +1,21 @@
+error: `?Trait` is not permitted in trait object types
+  --> $DIR/trait-object-trait-parens.rs:6:25
+   |
+LL |     let _: Box<(Copy) + (?Sized) + (for<'a> Trait<'a>)>;
+   |                         ^^^^^^^^
+
+error: `?Trait` is not permitted in trait object types
+  --> $DIR/trait-object-trait-parens.rs:9:47
+   |
+LL |     let _: Box<(for<'a> Trait<'a>) + (Copy) + (?Sized)>;
+   |                                               ^^^^^^^^
+
+error[E0261]: use of undeclared lifetime name `'a`
+  --> $DIR/trait-object-trait-parens.rs:9:31
+   |
+LL |     let _: Box<(for<'a> Trait<'a>) + (Copy) + (?Sized)>;
+   |                               ^^ undeclared lifetime
+
+error: aborting due to 3 previous errors
+
+For more information about this error, try `rustc --explain E0261`.
diff --git a/src/test/ui/parser/trait-plusequal-splitting.rs b/src/test/ui/parser/trait-plusequal-splitting.rs
index 9e2b5eb..c655a15 100644
--- a/src/test/ui/parser/trait-plusequal-splitting.rs
+++ b/src/test/ui/parser/trait-plusequal-splitting.rs
@@ -1,7 +1,6 @@
 // Fixes issue where `+` in generics weren't parsed if they were part of a `+=`.
 
 // compile-pass
-// compile-flags: -Z parse-only
 
 struct Whitespace<T: Clone + = ()> { t: T }
 struct TokenSplit<T: Clone +=  ()> { t: T }
diff --git a/src/test/ui/parser/trait-pub-assoc-const.rs b/src/test/ui/parser/trait-pub-assoc-const.rs
index 5fce37a..3ee2dc1 100644
--- a/src/test/ui/parser/trait-pub-assoc-const.rs
+++ b/src/test/ui/parser/trait-pub-assoc-const.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait Foo {
     pub const Foo: u32;
     //~^ ERROR expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found
diff --git a/src/test/ui/parser/trait-pub-assoc-const.stderr b/src/test/ui/parser/trait-pub-assoc-const.stderr
index 62778d7..8fc9ae4 100644
--- a/src/test/ui/parser/trait-pub-assoc-const.stderr
+++ b/src/test/ui/parser/trait-pub-assoc-const.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub`
-  --> $DIR/trait-pub-assoc-const.rs:4:5
+  --> $DIR/trait-pub-assoc-const.rs:2:5
    |
 LL | trait Foo {
    |            - expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/trait-pub-assoc-ty.rs b/src/test/ui/parser/trait-pub-assoc-ty.rs
index 22e1ab4..042addf 100644
--- a/src/test/ui/parser/trait-pub-assoc-ty.rs
+++ b/src/test/ui/parser/trait-pub-assoc-ty.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait Foo {
     pub type Foo;
     //~^ ERROR expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found
diff --git a/src/test/ui/parser/trait-pub-assoc-ty.stderr b/src/test/ui/parser/trait-pub-assoc-ty.stderr
index 42c26ec..b8eab4e 100644
--- a/src/test/ui/parser/trait-pub-assoc-ty.stderr
+++ b/src/test/ui/parser/trait-pub-assoc-ty.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub`
-  --> $DIR/trait-pub-assoc-ty.rs:4:5
+  --> $DIR/trait-pub-assoc-ty.rs:2:5
    |
 LL | trait Foo {
    |            - expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/trait-pub-method.rs b/src/test/ui/parser/trait-pub-method.rs
index 5b40ae1..9675182 100644
--- a/src/test/ui/parser/trait-pub-method.rs
+++ b/src/test/ui/parser/trait-pub-method.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 trait Foo {
     pub fn foo();
     //~^ ERROR expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found
diff --git a/src/test/ui/parser/trait-pub-method.stderr b/src/test/ui/parser/trait-pub-method.stderr
index 6ca4de8..d4db961 100644
--- a/src/test/ui/parser/trait-pub-method.stderr
+++ b/src/test/ui/parser/trait-pub-method.stderr
@@ -1,5 +1,5 @@
 error: expected one of `async`, `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `pub`
-  --> $DIR/trait-pub-method.rs:4:5
+  --> $DIR/trait-pub-method.rs:2:5
    |
 LL | trait Foo {
    |            - expected one of 7 possible tokens here
diff --git a/src/test/ui/parser/type-parameters-in-field-exprs.rs b/src/test/ui/parser/type-parameters-in-field-exprs.rs
index 1c714c2..1b8ed9f 100644
--- a/src/test/ui/parser/type-parameters-in-field-exprs.rs
+++ b/src/test/ui/parser/type-parameters-in-field-exprs.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 struct Foo {
     x: isize,
diff --git a/src/test/ui/parser/unbalanced-doublequote.rs b/src/test/ui/parser/unbalanced-doublequote.rs
index 56953aa..f213162 100644
--- a/src/test/ui/parser/unbalanced-doublequote.rs
+++ b/src/test/ui/parser/unbalanced-doublequote.rs
@@ -1,6 +1,3 @@
-// compile-flags: -Z parse-only
-
-
 // error-pattern: unterminated double quote string
 
 
diff --git a/src/test/ui/parser/unbalanced-doublequote.stderr b/src/test/ui/parser/unbalanced-doublequote.stderr
index f2d9aa8..4d98515 100644
--- a/src/test/ui/parser/unbalanced-doublequote.stderr
+++ b/src/test/ui/parser/unbalanced-doublequote.stderr
@@ -1,5 +1,5 @@
 error: unterminated double quote string
-  --> $DIR/unbalanced-doublequote.rs:8:5
+  --> $DIR/unbalanced-doublequote.rs:5:5
    |
 LL | /     "
 LL | | }
diff --git a/src/test/ui/parser/unclosed-braces.rs b/src/test/ui/parser/unclosed-braces.rs
index f3c8c18..9c9ab76 100644
--- a/src/test/ui/parser/unclosed-braces.rs
+++ b/src/test/ui/parser/unclosed-braces.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 struct S {
     x: [usize; 3],
 }
diff --git a/src/test/ui/parser/unclosed-braces.stderr b/src/test/ui/parser/unclosed-braces.stderr
index 9223000..3ab3664 100644
--- a/src/test/ui/parser/unclosed-braces.stderr
+++ b/src/test/ui/parser/unclosed-braces.stderr
@@ -1,5 +1,5 @@
 error: this file contains an un-closed delimiter
-  --> $DIR/unclosed-braces.rs:24:53
+  --> $DIR/unclosed-braces.rs:22:53
    |
 LL | fn main() {
    |           - un-closed delimiter
diff --git a/src/test/ui/parser/underscore-suffix-for-float.rs b/src/test/ui/parser/underscore-suffix-for-float.rs
index be252dd..c9b7ece 100644
--- a/src/test/ui/parser/underscore-suffix-for-float.rs
+++ b/src/test/ui/parser/underscore-suffix-for-float.rs
@@ -1,5 +1,4 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let a = 42._; //~ ERROR expected identifier, found reserved identifier `_`
+                  //~| ERROR `{integer}` is a primitive type and therefore doesn't have fields
 }
diff --git a/src/test/ui/parser/underscore-suffix-for-float.stderr b/src/test/ui/parser/underscore-suffix-for-float.stderr
index 5dec77b..58adcbb 100644
--- a/src/test/ui/parser/underscore-suffix-for-float.stderr
+++ b/src/test/ui/parser/underscore-suffix-for-float.stderr
@@ -1,8 +1,15 @@
 error: expected identifier, found reserved identifier `_`
-  --> $DIR/underscore-suffix-for-float.rs:4:16
+  --> $DIR/underscore-suffix-for-float.rs:2:16
    |
 LL |     let a = 42._; //~ ERROR expected identifier, found reserved identifier `_`
    |                ^ expected identifier, found reserved identifier
 
-error: aborting due to previous error
+error[E0610]: `{integer}` is a primitive type and therefore doesn't have fields
+  --> $DIR/underscore-suffix-for-float.rs:2:16
+   |
+LL |     let a = 42._; //~ ERROR expected identifier, found reserved identifier `_`
+   |                ^
 
+error: aborting due to 2 previous errors
+
+For more information about this error, try `rustc --explain E0610`.
diff --git a/src/test/ui/parser/underscore-suffix-for-string.rs b/src/test/ui/parser/underscore-suffix-for-string.rs
index fd7e54f..bcd0b24 100644
--- a/src/test/ui/parser/underscore-suffix-for-string.rs
+++ b/src/test/ui/parser/underscore-suffix-for-string.rs
@@ -1,5 +1,4 @@
 // compile-pass
-// compile-flags: -Z parse-only
 
 fn main() {
     let _ = "Foo"_;
diff --git a/src/test/ui/parser/underscore-suffix-for-string.stderr b/src/test/ui/parser/underscore-suffix-for-string.stderr
index ed1b4d3..80d0d1b 100644
--- a/src/test/ui/parser/underscore-suffix-for-string.stderr
+++ b/src/test/ui/parser/underscore-suffix-for-string.stderr
@@ -1,5 +1,5 @@
 warning: underscore literal suffix is not allowed
-  --> $DIR/underscore-suffix-for-string.rs:5:18
+  --> $DIR/underscore-suffix-for-string.rs:4:18
    |
 LL |     let _ = "Foo"_;
    |                  ^
diff --git a/src/test/ui/parser/underscore_static.rs b/src/test/ui/parser/underscore_static.rs
index e1a9a02..21d6a1b 100644
--- a/src/test/ui/parser/underscore_static.rs
+++ b/src/test/ui/parser/underscore_static.rs
@@ -1,3 +1,3 @@
-// compile-flags: -Z parse-only
-
 static _: () = (); //~ ERROR expected identifier, found reserved identifier `_`
+
+fn main() {}
diff --git a/src/test/ui/parser/underscore_static.stderr b/src/test/ui/parser/underscore_static.stderr
index 1b766f7..3bf3ce8 100644
--- a/src/test/ui/parser/underscore_static.stderr
+++ b/src/test/ui/parser/underscore_static.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found reserved identifier `_`
-  --> $DIR/underscore_static.rs:3:8
+  --> $DIR/underscore_static.rs:1:8
    |
 LL | static _: () = (); //~ ERROR expected identifier, found reserved identifier `_`
    |        ^ expected identifier, found reserved identifier
diff --git a/src/test/ui/parser/unicode-chars.rs b/src/test/ui/parser/unicode-chars.rs
index 8108ea7..89ae85e 100644
--- a/src/test/ui/parser/unicode-chars.rs
+++ b/src/test/ui/parser/unicode-chars.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn main() {
     let y = 0;
     //~^ ERROR unknown start of token: \u{37e}
diff --git a/src/test/ui/parser/unicode-chars.stderr b/src/test/ui/parser/unicode-chars.stderr
index 864866a..3a360d8 100644
--- a/src/test/ui/parser/unicode-chars.stderr
+++ b/src/test/ui/parser/unicode-chars.stderr
@@ -1,5 +1,5 @@
 error: unknown start of token: /u{37e}
-  --> $DIR/unicode-chars.rs:4:14
+  --> $DIR/unicode-chars.rs:2:14
    |
 LL |     let y = 0;
    |              ^
diff --git a/src/test/ui/parser/unsized.rs b/src/test/ui/parser/unsized.rs
index 4d6aeb4..e7fd7a1 100644
--- a/src/test/ui/parser/unsized.rs
+++ b/src/test/ui/parser/unsized.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Test syntax checks for `type` keyword.
 
 struct S1 for type;
diff --git a/src/test/ui/parser/unsized.stderr b/src/test/ui/parser/unsized.stderr
index 5130743..3d4ed52 100644
--- a/src/test/ui/parser/unsized.stderr
+++ b/src/test/ui/parser/unsized.stderr
@@ -1,5 +1,5 @@
 error: expected `where`, `{`, `(`, or `;` after struct name, found keyword `for`
-  --> $DIR/unsized.rs:5:11
+  --> $DIR/unsized.rs:3:11
    |
 LL | struct S1 for type;
    |           ^^^ expected `where`, `{`, `(`, or `;` after struct name
diff --git a/src/test/ui/parser/unsized2.rs b/src/test/ui/parser/unsized2.rs
index 5f566b9..21370b3 100644
--- a/src/test/ui/parser/unsized2.rs
+++ b/src/test/ui/parser/unsized2.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Test syntax checks for `type` keyword.
 
 fn f<X>() {}
diff --git a/src/test/ui/parser/unsized2.stderr b/src/test/ui/parser/unsized2.stderr
index d607fad..fd12d86 100644
--- a/src/test/ui/parser/unsized2.stderr
+++ b/src/test/ui/parser/unsized2.stderr
@@ -1,5 +1,5 @@
 error: expected expression, found keyword `type`
-  --> $DIR/unsized2.rs:8:7
+  --> $DIR/unsized2.rs:6:7
    |
 LL |     f<type>(); //~ ERROR expected expression, found keyword `type`
    |       ^^^^ expected expression
diff --git a/src/test/ui/parser/use-as-where-use-ends-with-mod-sep.rs b/src/test/ui/parser/use-as-where-use-ends-with-mod-sep.rs
index f9302fe..d322e9f 100644
--- a/src/test/ui/parser/use-as-where-use-ends-with-mod-sep.rs
+++ b/src/test/ui/parser/use-as-where-use-ends-with-mod-sep.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 use std::any:: as foo; //~ ERROR expected identifier, found keyword `as`
 //~^ ERROR: expected one of `::`, `;`, or `as`, found `foo`
diff --git a/src/test/ui/parser/use-ends-with-mod-sep.rs b/src/test/ui/parser/use-ends-with-mod-sep.rs
index 8606ca3..ad8da4d 100644
--- a/src/test/ui/parser/use-ends-with-mod-sep.rs
+++ b/src/test/ui/parser/use-ends-with-mod-sep.rs
@@ -1,3 +1 @@
-// compile-flags: -Z parse-only
-
 use std::any::; //~ ERROR expected identifier, found `;`
diff --git a/src/test/ui/parser/use-ends-with-mod-sep.stderr b/src/test/ui/parser/use-ends-with-mod-sep.stderr
index 3ec4553..4a2b95a 100644
--- a/src/test/ui/parser/use-ends-with-mod-sep.stderr
+++ b/src/test/ui/parser/use-ends-with-mod-sep.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `;`
-  --> $DIR/use-ends-with-mod-sep.rs:3:15
+  --> $DIR/use-ends-with-mod-sep.rs:1:15
    |
 LL | use std::any::; //~ ERROR expected identifier, found `;`
    |               ^ expected identifier
diff --git a/src/test/ui/parser/variadic-ffi-3.rs b/src/test/ui/parser/variadic-ffi-3.rs
index 678e951..13bce27 100644
--- a/src/test/ui/parser/variadic-ffi-3.rs
+++ b/src/test/ui/parser/variadic-ffi-3.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn foo(x: isize, ...) {
     //~^ ERROR: only foreign functions are allowed to be variadic
 }
diff --git a/src/test/ui/parser/variadic-ffi-3.stderr b/src/test/ui/parser/variadic-ffi-3.stderr
index 5932a06..150de9e 100644
--- a/src/test/ui/parser/variadic-ffi-3.stderr
+++ b/src/test/ui/parser/variadic-ffi-3.stderr
@@ -1,5 +1,5 @@
 error: only foreign functions are allowed to be variadic
-  --> $DIR/variadic-ffi-3.rs:3:18
+  --> $DIR/variadic-ffi-3.rs:1:18
    |
 LL | fn foo(x: isize, ...) {
    |                  ^^^
diff --git a/src/test/ui/parser/variadic-ffi-4.rs b/src/test/ui/parser/variadic-ffi-4.rs
index 5ff2cea..812ed25 100644
--- a/src/test/ui/parser/variadic-ffi-4.rs
+++ b/src/test/ui/parser/variadic-ffi-4.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 extern "C" fn foo(x: isize, ...) {
     //~^ ERROR: only foreign functions are allowed to be variadic
 }
diff --git a/src/test/ui/parser/variadic-ffi-4.stderr b/src/test/ui/parser/variadic-ffi-4.stderr
index 4751cff..2d036b0 100644
--- a/src/test/ui/parser/variadic-ffi-4.stderr
+++ b/src/test/ui/parser/variadic-ffi-4.stderr
@@ -1,5 +1,5 @@
 error: only foreign functions are allowed to be variadic
-  --> $DIR/variadic-ffi-4.rs:3:29
+  --> $DIR/variadic-ffi-4.rs:1:29
    |
 LL | extern "C" fn foo(x: isize, ...) {
    |                             ^^^
diff --git a/src/test/ui/parser/virtual-structs.rs b/src/test/ui/parser/virtual-structs.rs
index 522df6b..ce57a34 100644
--- a/src/test/ui/parser/virtual-structs.rs
+++ b/src/test/ui/parser/virtual-structs.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Test diagnostics for the removed struct inheritance feature.
 
 virtual struct SuperStruct {
diff --git a/src/test/ui/parser/virtual-structs.stderr b/src/test/ui/parser/virtual-structs.stderr
index fc2736e..a5211d8 100644
--- a/src/test/ui/parser/virtual-structs.stderr
+++ b/src/test/ui/parser/virtual-structs.stderr
@@ -1,5 +1,5 @@
 error: expected item, found reserved keyword `virtual`
-  --> $DIR/virtual-structs.rs:5:1
+  --> $DIR/virtual-structs.rs:3:1
    |
 LL | virtual struct SuperStruct {
    | ^^^^^^^ expected item
diff --git a/src/test/ui/parser/where-clauses-no-bounds-or-predicates.rs b/src/test/ui/parser/where-clauses-no-bounds-or-predicates.rs
index 6148c07..45dacf2 100644
--- a/src/test/ui/parser/where-clauses-no-bounds-or-predicates.rs
+++ b/src/test/ui/parser/where-clauses-no-bounds-or-predicates.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Z parse-only -Z continue-parse-after-error
+// compile-flags: -Z continue-parse-after-error
 
 // Empty predicate list is OK
 fn equal1<T>(_: &T, _: &T) -> bool where {
diff --git a/src/test/ui/parser/where_with_bound.rs b/src/test/ui/parser/where_with_bound.rs
index 2f0caec..3a1edb9 100644
--- a/src/test/ui/parser/where_with_bound.rs
+++ b/src/test/ui/parser/where_with_bound.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 fn foo<T>() where <T>::Item: ToString, T: Iterator { }
 //~^ ERROR generic parameters on `where` clauses are reserved for future use
 
diff --git a/src/test/ui/parser/where_with_bound.stderr b/src/test/ui/parser/where_with_bound.stderr
index c8d3ced..e68f744 100644
--- a/src/test/ui/parser/where_with_bound.stderr
+++ b/src/test/ui/parser/where_with_bound.stderr
@@ -1,5 +1,5 @@
 error: generic parameters on `where` clauses are reserved for future use
-  --> $DIR/where_with_bound.rs:3:19
+  --> $DIR/where_with_bound.rs:1:19
    |
 LL | fn foo<T>() where <T>::Item: ToString, T: Iterator { }
    |                   ^^^
diff --git a/src/test/ui/parser/wrong-escape-of-curly-braces.rs b/src/test/ui/parser/wrong-escape-of-curly-braces.rs
index af5e5e8..7a5c27a 100644
--- a/src/test/ui/parser/wrong-escape-of-curly-braces.rs
+++ b/src/test/ui/parser/wrong-escape-of-curly-braces.rs
@@ -1,6 +1,4 @@
-// compile-flags: -Z parse-only
-
-fn f() {
+fn main() {
     let ok = "{{everything fine}}";
     let bad = "\{it is wrong\}";
     //~^  ERROR unknown character escape: {
diff --git a/src/test/ui/parser/wrong-escape-of-curly-braces.stderr b/src/test/ui/parser/wrong-escape-of-curly-braces.stderr
index a9b276f..90debfc 100644
--- a/src/test/ui/parser/wrong-escape-of-curly-braces.stderr
+++ b/src/test/ui/parser/wrong-escape-of-curly-braces.stderr
@@ -1,23 +1,23 @@
 error: unknown character escape: {
-  --> $DIR/wrong-escape-of-curly-braces.rs:5:17
+  --> $DIR/wrong-escape-of-curly-braces.rs:3:17
    |
 LL |     let bad = "/{it is wrong/}";
    |                 ^
    |
 help: if used in a formatting string, curly braces are escaped with `{{` and `}}`
-  --> $DIR/wrong-escape-of-curly-braces.rs:5:17
+  --> $DIR/wrong-escape-of-curly-braces.rs:3:17
    |
 LL |     let bad = "/{it is wrong/}";
    |                 ^
 
 error: unknown character escape: }
-  --> $DIR/wrong-escape-of-curly-braces.rs:5:30
+  --> $DIR/wrong-escape-of-curly-braces.rs:3:30
    |
 LL |     let bad = "/{it is wrong/}";
    |                              ^
    |
 help: if used in a formatting string, curly braces are escaped with `{{` and `}}`
-  --> $DIR/wrong-escape-of-curly-braces.rs:5:30
+  --> $DIR/wrong-escape-of-curly-braces.rs:3:30
    |
 LL |     let bad = "/{it is wrong/}";
    |                              ^
diff --git a/src/test/ui/privacy/auxiliary/issue-57264-1.rs b/src/test/ui/privacy/auxiliary/issue-57264-1.rs
new file mode 100644
index 0000000..9302fa0d
--- /dev/null
+++ b/src/test/ui/privacy/auxiliary/issue-57264-1.rs
@@ -0,0 +1,9 @@
+mod inner {
+    pub struct PubUnnameable;
+}
+
+pub struct Pub<T>(T);
+
+impl Pub<inner::PubUnnameable> {
+    pub fn pub_method() {}
+}
diff --git a/src/test/ui/privacy/auxiliary/issue-57264-2.rs b/src/test/ui/privacy/auxiliary/issue-57264-2.rs
new file mode 100644
index 0000000..416206b
--- /dev/null
+++ b/src/test/ui/privacy/auxiliary/issue-57264-2.rs
@@ -0,0 +1,10 @@
+mod inner {
+    pub struct PubUnnameable;
+
+    impl PubUnnameable {
+        pub fn pub_method(self) {}
+    }
+}
+
+pub trait PubTraitWithSingleImplementor {}
+impl PubTraitWithSingleImplementor for Option<inner::PubUnnameable> {}
diff --git a/src/test/ui/privacy/issue-57264-1.rs b/src/test/ui/privacy/issue-57264-1.rs
new file mode 100644
index 0000000..dcffdc3
--- /dev/null
+++ b/src/test/ui/privacy/issue-57264-1.rs
@@ -0,0 +1,8 @@
+// compile-pass
+// aux-build:issue-57264-1.rs
+
+extern crate issue_57264_1;
+
+fn main() {
+    issue_57264_1::Pub::pub_method();
+}
diff --git a/src/test/ui/privacy/issue-57264-2.rs b/src/test/ui/privacy/issue-57264-2.rs
new file mode 100644
index 0000000..79d0d2c
--- /dev/null
+++ b/src/test/ui/privacy/issue-57264-2.rs
@@ -0,0 +1,10 @@
+// compile-pass
+// aux-build:issue-57264-2.rs
+
+extern crate issue_57264_2;
+
+fn infer<T: issue_57264_2::PubTraitWithSingleImplementor>(arg: T) -> T { arg }
+
+fn main() {
+    infer(None).unwrap().pub_method();
+}
diff --git a/src/test/ui/range/range-1.stderr b/src/test/ui/range/range-1.stderr
index 8e0e405..00c0c80 100644
--- a/src/test/ui/range/range-1.stderr
+++ b/src/test/ui/range/range-1.stderr
@@ -19,7 +19,7 @@
    |                 ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[{integer}]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::ops::RangeFrom`
 
 error: aborting due to 3 previous errors
diff --git a/src/test/ui/resolve/issue-5035-2.stderr b/src/test/ui/resolve/issue-5035-2.stderr
index d3e559e..89eb3d9 100644
--- a/src/test/ui/resolve/issue-5035-2.stderr
+++ b/src/test/ui/resolve/issue-5035-2.stderr
@@ -5,7 +5,7 @@
    |        ^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn I + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/rfc1598-generic-associated-types/parse/in-trait-impl.rs b/src/test/ui/rfc1598-generic-associated-types/parse/in-trait-impl.rs
index 5835305..589e5fc 100644
--- a/src/test/ui/rfc1598-generic-associated-types/parse/in-trait-impl.rs
+++ b/src/test/ui/rfc1598-generic-associated-types/parse/in-trait-impl.rs
@@ -1,5 +1,5 @@
-// compile-flags: -Z parse-only
 // compile-pass
+// compile-flags: -Z parse-only
 
 #![feature(generic_associated_types)]
 
diff --git a/src/test/ui/rfc1598-generic-associated-types/parse/in-trait.rs b/src/test/ui/rfc1598-generic-associated-types/parse/in-trait.rs
index e295463..7fa71e4 100644
--- a/src/test/ui/rfc1598-generic-associated-types/parse/in-trait.rs
+++ b/src/test/ui/rfc1598-generic-associated-types/parse/in-trait.rs
@@ -1,5 +1,5 @@
-// compile-flags: -Z parse-only
 // compile-pass
+// compile-flags: -Z parse-only
 
 #![feature(generic_associated_types)]
 
diff --git a/src/test/ui/span/dropck_vec_cycle_checked.nll.stderr b/src/test/ui/span/dropck_vec_cycle_checked.nll.stderr
index 3d9c935..0569251 100644
--- a/src/test/ui/span/dropck_vec_cycle_checked.nll.stderr
+++ b/src/test/ui/span/dropck_vec_cycle_checked.nll.stderr
@@ -1,5 +1,5 @@
 error[E0597]: `c2` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:103:24
+  --> $DIR/dropck_vec_cycle_checked.rs:98:24
    |
 LL |     c1.v[0].v.set(Some(&c2));
    |                        ^^^ borrowed value does not live long enough
@@ -13,7 +13,7 @@
    = note: values in a scope are dropped in the opposite order they are defined
 
 error[E0597]: `c3` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:105:24
+  --> $DIR/dropck_vec_cycle_checked.rs:100:24
    |
 LL |     c1.v[1].v.set(Some(&c3));
    |                        ^^^ borrowed value does not live long enough
@@ -27,7 +27,7 @@
    = note: values in a scope are dropped in the opposite order they are defined
 
 error[E0597]: `c1` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:111:24
+  --> $DIR/dropck_vec_cycle_checked.rs:106:24
    |
 LL |     c3.v[0].v.set(Some(&c1));
    |                        ^^^ borrowed value does not live long enough
diff --git a/src/test/ui/span/dropck_vec_cycle_checked.rs b/src/test/ui/span/dropck_vec_cycle_checked.rs
index 4f627c4..c80e038 100644
--- a/src/test/ui/span/dropck_vec_cycle_checked.rs
+++ b/src/test/ui/span/dropck_vec_cycle_checked.rs
@@ -1,12 +1,7 @@
-// compile-flags: -Z nll-subminimal-causes
-// (Work around rust-lang/rust#49998 by opting into nll-subminimal-causes.)
-
 // Reject mixing cyclic structure and Drop when using Vec.
 //
 // (Compare against compile-fail/dropck_arr_cycle_checked.rs)
 
-
-
 use std::cell::Cell;
 use id::Id;
 
diff --git a/src/test/ui/span/dropck_vec_cycle_checked.stderr b/src/test/ui/span/dropck_vec_cycle_checked.stderr
index 3a52144..35e4314 100644
--- a/src/test/ui/span/dropck_vec_cycle_checked.stderr
+++ b/src/test/ui/span/dropck_vec_cycle_checked.stderr
@@ -1,5 +1,5 @@
 error[E0597]: `c2` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:103:25
+  --> $DIR/dropck_vec_cycle_checked.rs:98:25
    |
 LL |     c1.v[0].v.set(Some(&c2));
    |                         ^^ borrowed value does not live long enough
@@ -10,7 +10,7 @@
    = note: values in a scope are dropped in the opposite order they are created
 
 error[E0597]: `c3` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:105:25
+  --> $DIR/dropck_vec_cycle_checked.rs:100:25
    |
 LL |     c1.v[1].v.set(Some(&c3));
    |                         ^^ borrowed value does not live long enough
@@ -21,7 +21,7 @@
    = note: values in a scope are dropped in the opposite order they are created
 
 error[E0597]: `c2` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:107:25
+  --> $DIR/dropck_vec_cycle_checked.rs:102:25
    |
 LL |     c2.v[0].v.set(Some(&c2));
    |                         ^^ borrowed value does not live long enough
@@ -32,7 +32,7 @@
    = note: values in a scope are dropped in the opposite order they are created
 
 error[E0597]: `c3` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:109:25
+  --> $DIR/dropck_vec_cycle_checked.rs:104:25
    |
 LL |     c2.v[1].v.set(Some(&c3));
    |                         ^^ borrowed value does not live long enough
@@ -43,7 +43,7 @@
    = note: values in a scope are dropped in the opposite order they are created
 
 error[E0597]: `c1` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:111:25
+  --> $DIR/dropck_vec_cycle_checked.rs:106:25
    |
 LL |     c3.v[0].v.set(Some(&c1));
    |                         ^^ borrowed value does not live long enough
@@ -54,7 +54,7 @@
    = note: values in a scope are dropped in the opposite order they are created
 
 error[E0597]: `c2` does not live long enough
-  --> $DIR/dropck_vec_cycle_checked.rs:113:25
+  --> $DIR/dropck_vec_cycle_checked.rs:108:25
    |
 LL |     c3.v[1].v.set(Some(&c2));
    |                         ^^ borrowed value does not live long enough
diff --git a/src/test/ui/span/gated-features-attr-spans.rs b/src/test/ui/span/gated-features-attr-spans.rs
index ff722a5..69511ab 100644
--- a/src/test/ui/span/gated-features-attr-spans.rs
+++ b/src/test/ui/span/gated-features-attr-spans.rs
@@ -1,7 +1,7 @@
 #[repr(simd)] //~ ERROR are experimental
-struct Weapon {
-    name: String,
-    damage: u32
+struct Coord {
+    x: u32,
+    y: u32,
 }
 
 fn main() {}
diff --git a/src/test/ui/str/str-array-assignment.stderr b/src/test/ui/str/str-array-assignment.stderr
index d3bff00..24d8db4 100644
--- a/src/test/ui/str/str-array-assignment.stderr
+++ b/src/test/ui/str/str-array-assignment.stderr
@@ -28,7 +28,7 @@
    |       doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/str/str-mut-idx.stderr b/src/test/ui/str/str-mut-idx.stderr
index a8ab38e..a0c7c2c 100644
--- a/src/test/ui/str/str-mut-idx.stderr
+++ b/src/test/ui/str/str-mut-idx.stderr
@@ -5,7 +5,7 @@
    |               ^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
 note: required by `bot`
   --> $DIR/str-mut-idx.rs:1:1
    |
@@ -19,7 +19,7 @@
    |     ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the left-hand-side of an assignment must have a statically known size
 
 error[E0277]: the type `str` cannot be mutably indexed by `usize`
diff --git a/src/test/ui/structs/struct-duplicate-comma.rs b/src/test/ui/structs/struct-duplicate-comma.rs
index 2d4551c..ff0d58a 100644
--- a/src/test/ui/structs/struct-duplicate-comma.rs
+++ b/src/test/ui/structs/struct-duplicate-comma.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Issue #50974
 
 struct Foo {
@@ -14,4 +12,3 @@
         b: 42
     };
 }
-
diff --git a/src/test/ui/structs/struct-duplicate-comma.stderr b/src/test/ui/structs/struct-duplicate-comma.stderr
index 112ea90..2297fea 100644
--- a/src/test/ui/structs/struct-duplicate-comma.stderr
+++ b/src/test/ui/structs/struct-duplicate-comma.stderr
@@ -1,5 +1,5 @@
 error: expected identifier, found `,`
-  --> $DIR/struct-duplicate-comma.rs:12:14
+  --> $DIR/struct-duplicate-comma.rs:10:14
    |
 LL |     let bar = Foo {
    |               --- while parsing this struct
diff --git a/src/test/ui/structs/struct-field-init-syntax.rs b/src/test/ui/structs/struct-field-init-syntax.rs
index 3146399..161f7e9 100644
--- a/src/test/ui/structs/struct-field-init-syntax.rs
+++ b/src/test/ui/structs/struct-field-init-syntax.rs
@@ -1,7 +1,10 @@
-// compile-flags: -Z parse-only
-
 // issue #41834
 
+#[derive(Default)]
+struct Foo {
+    one: u8,
+}
+
 fn main() {
     let foo = Foo {
         one: 111,
diff --git a/src/test/ui/structs/struct-field-init-syntax.stderr b/src/test/ui/structs/struct-field-init-syntax.stderr
index cd8f6b9..0b72c5c 100644
--- a/src/test/ui/structs/struct-field-init-syntax.stderr
+++ b/src/test/ui/structs/struct-field-init-syntax.stderr
@@ -1,5 +1,5 @@
 error: cannot use a comma after the base struct
-  --> $DIR/struct-field-init-syntax.rs:8:9
+  --> $DIR/struct-field-init-syntax.rs:11:9
    |
 LL |         ..Foo::default(),
    |         ^^^^^^^^^^^^^^^^- help: remove this comma
@@ -7,7 +7,7 @@
    = note: the base struct must always be the last field
 
 error: cannot use a comma after the base struct
-  --> $DIR/struct-field-init-syntax.rs:13:9
+  --> $DIR/struct-field-init-syntax.rs:16:9
    |
 LL |         ..Foo::default(),
    |         ^^^^^^^^^^^^^^^^- help: remove this comma
diff --git a/src/test/ui/structs/struct-missing-comma.rs b/src/test/ui/structs/struct-missing-comma.rs
index e07080f..4c3cac3 100644
--- a/src/test/ui/structs/struct-missing-comma.rs
+++ b/src/test/ui/structs/struct-missing-comma.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Z parse-only
-
 // Issue #50636
 
 struct S {
diff --git a/src/test/ui/structs/struct-missing-comma.stderr b/src/test/ui/structs/struct-missing-comma.stderr
index a941c5b..00ef1a7 100644
--- a/src/test/ui/structs/struct-missing-comma.stderr
+++ b/src/test/ui/structs/struct-missing-comma.stderr
@@ -1,5 +1,5 @@
 error: expected `,`, or `}`, found `bar`
-  --> $DIR/struct-missing-comma.rs:6:13
+  --> $DIR/struct-missing-comma.rs:4:13
    |
 LL |     foo: u32 //~ expected `,`, or `}`, found `bar`
    |             ^ help: try adding a comma: `,`
diff --git a/src/test/ui/substs-ppaux.normal.stderr b/src/test/ui/substs-ppaux.normal.stderr
index fb9e49e..567b4d9 100644
--- a/src/test/ui/substs-ppaux.normal.stderr
+++ b/src/test/ui/substs-ppaux.normal.stderr
@@ -41,7 +41,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because of the requirements on the impl of `Foo<'_, '_, u8>` for `str`
 note: required by `Foo::bar`
   --> $DIR/substs-ppaux.rs:7:5
diff --git a/src/test/ui/substs-ppaux.verbose.stderr b/src/test/ui/substs-ppaux.verbose.stderr
index 77683c1..9d8a555 100644
--- a/src/test/ui/substs-ppaux.verbose.stderr
+++ b/src/test/ui/substs-ppaux.verbose.stderr
@@ -41,7 +41,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because of the requirements on the impl of `Foo<'_#0r, '_#1r, u8>` for `str`
 note: required by `Foo::bar`
   --> $DIR/substs-ppaux.rs:7:5
diff --git a/src/test/ui/suggestions/path-by-value.stderr b/src/test/ui/suggestions/path-by-value.stderr
index 338cfc9..b073e10 100644
--- a/src/test/ui/suggestions/path-by-value.stderr
+++ b/src/test/ui/suggestions/path-by-value.stderr
@@ -5,7 +5,7 @@
    |      ^ borrow the `Path` instead
    |
    = help: within `std::path::Path`, the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `std::path::Path`
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
diff --git a/src/test/ui/traits/trait-bounds-not-on-bare-trait.stderr b/src/test/ui/traits/trait-bounds-not-on-bare-trait.stderr
index 43d1e1a..5aee1e7 100644
--- a/src/test/ui/traits/trait-bounds-not-on-bare-trait.stderr
+++ b/src/test/ui/traits/trait-bounds-not-on-bare-trait.stderr
@@ -5,7 +5,7 @@
    |        ^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn Foo + std::marker::Send + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/traits/trait-suggest-where-clause.stderr b/src/test/ui/traits/trait-suggest-where-clause.stderr
index 161cf85..f88dae3 100644
--- a/src/test/ui/traits/trait-suggest-where-clause.stderr
+++ b/src/test/ui/traits/trait-suggest-where-clause.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `U`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where U: std::marker::Sized` bound
    = note: required by `std::mem::size_of`
 
@@ -16,7 +16,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Misc<U>`, the trait `std::marker::Sized` is not implemented for `U`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where U: std::marker::Sized` bound
    = note: required because it appears within the type `Misc<U>`
    = note: required by `std::mem::size_of`
@@ -54,7 +54,7 @@
    |     ^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[T]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::mem::size_of`
 
 error[E0277]: the size for values of type `[&U]` cannot be known at compilation time
@@ -64,7 +64,7 @@
    |     ^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[&U]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::mem::size_of`
 
 error: aborting due to 7 previous errors
diff --git a/src/test/ui/trivial-bounds/trivial-bounds-leak.stderr b/src/test/ui/trivial-bounds/trivial-bounds-leak.stderr
index bc94aba..aa055d3 100644
--- a/src/test/ui/trivial-bounds/trivial-bounds-leak.stderr
+++ b/src/test/ui/trivial-bounds/trivial-bounds-leak.stderr
@@ -5,7 +5,7 @@
    |                         ^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: the return type of a function must have a statically known size
 
 error[E0599]: no method named `test` found for type `i32` in the current scope
diff --git a/src/test/ui/tuple/tuple-float-index.fixed b/src/test/ui/tuple/tuple-float-index.fixed
index c93b545..cd1a85a 100644
--- a/src/test/ui/tuple/tuple-float-index.fixed
+++ b/src/test/ui/tuple/tuple-float-index.fixed
@@ -1,5 +1,4 @@
 // run-rustfix
-// compile-flags: -Z parse-only
 
 fn main () {
     ((1, (2, 3)).1).1; //~ ERROR unexpected token: `1.1`
diff --git a/src/test/ui/tuple/tuple-float-index.rs b/src/test/ui/tuple/tuple-float-index.rs
index 9b669bc..1faabac 100644
--- a/src/test/ui/tuple/tuple-float-index.rs
+++ b/src/test/ui/tuple/tuple-float-index.rs
@@ -1,5 +1,4 @@
 // run-rustfix
-// compile-flags: -Z parse-only
 
 fn main () {
     (1, (2, 3)).1.1; //~ ERROR unexpected token: `1.1`
diff --git a/src/test/ui/tuple/tuple-float-index.stderr b/src/test/ui/tuple/tuple-float-index.stderr
index 5bbccba..9a3e384 100644
--- a/src/test/ui/tuple/tuple-float-index.stderr
+++ b/src/test/ui/tuple/tuple-float-index.stderr
@@ -1,5 +1,5 @@
 error: unexpected token: `1.1`
-  --> $DIR/tuple-float-index.rs:5:17
+  --> $DIR/tuple-float-index.rs:4:17
    |
 LL |     (1, (2, 3)).1.1; //~ ERROR unexpected token: `1.1`
    |     ------------^^^
diff --git a/src/test/ui/union/union-sized-field.stderr b/src/test/ui/union/union-sized-field.stderr
index b490be2..8914003 100644
--- a/src/test/ui/union/union-sized-field.stderr
+++ b/src/test/ui/union/union-sized-field.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: no field of a union may have a dynamically sized type
 
@@ -16,7 +16,7 @@
    |     ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: only the last field of a struct may have a dynamically sized type
 
@@ -27,7 +27,7 @@
    |           ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
diff --git a/src/test/ui/union/union-suggest-field.rs b/src/test/ui/union/union-suggest-field.rs
index b2d8c0e..d84a22c 100644
--- a/src/test/ui/union/union-suggest-field.rs
+++ b/src/test/ui/union/union-suggest-field.rs
@@ -16,5 +16,6 @@
                           //~| SUGGESTION principal
 
     let y = u.calculate; //~ ERROR attempted to take value of method `calculate` on type `U`
-                         //~| HELP maybe a `()` to call it is missing
+                         //~| HELP use parentheses to call the method
+                         //~| SUGGESTION calculate()
 }
diff --git a/src/test/ui/union/union-suggest-field.stderr b/src/test/ui/union/union-suggest-field.stderr
index 91d6b30..8ea0736 100644
--- a/src/test/ui/union/union-suggest-field.stderr
+++ b/src/test/ui/union/union-suggest-field.stderr
@@ -14,9 +14,7 @@
   --> $DIR/union-suggest-field.rs:18:15
    |
 LL |     let y = u.calculate; //~ ERROR attempted to take value of method `calculate` on type `U`
-   |               ^^^^^^^^^
-   |
-   = help: maybe a `()` to call it is missing?
+   |               ^^^^^^^^^ help: use parentheses to call the method: `calculate()`
 
 error: aborting due to 3 previous errors
 
diff --git a/src/test/ui/union/union-unsized.stderr b/src/test/ui/union/union-unsized.stderr
index cd65172..e702f2c 100644
--- a/src/test/ui/union/union-unsized.stderr
+++ b/src/test/ui/union/union-unsized.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of a union may have a dynamically sized type
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
@@ -15,7 +15,7 @@
    |     ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of a union may have a dynamically sized type
 
 error: aborting due to 2 previous errors
diff --git a/src/test/ui/unsized-locals/issue-50940-with-feature.stderr b/src/test/ui/unsized-locals/issue-50940-with-feature.stderr
index f4f015f..7b6c2d1 100644
--- a/src/test/ui/unsized-locals/issue-50940-with-feature.stderr
+++ b/src/test/ui/unsized-locals/issue-50940-with-feature.stderr
@@ -5,7 +5,7 @@
    |     ^ doesn't have a size known at compile-time
    |
    = help: within `main::A<str>`, the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `main::A<str>`
    = note: the return type of a function must have a statically known size
 
diff --git a/src/test/ui/unsized-locals/issue-50940.stderr b/src/test/ui/unsized-locals/issue-50940.stderr
index 9f3669c..be006c0 100644
--- a/src/test/ui/unsized-locals/issue-50940.stderr
+++ b/src/test/ui/unsized-locals/issue-50940.stderr
@@ -5,7 +5,7 @@
    |     ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/unsized-locals/unsized-exprs.stderr b/src/test/ui/unsized-locals/unsized-exprs.stderr
index 0ca60e8..43c35cd 100644
--- a/src/test/ui/unsized-locals/unsized-exprs.stderr
+++ b/src/test/ui/unsized-locals/unsized-exprs.stderr
@@ -5,7 +5,7 @@
    |                          ^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `({integer}, [u8])`, the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `({integer}, [u8])`
    = note: tuples must have a statically known size to be initialized
 
@@ -16,7 +16,7 @@
    |                      ^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `A<[u8]>`, the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `A<[u8]>`
    = note: structs must have a statically known size to be initialized
 
@@ -27,7 +27,7 @@
    |                      ^ doesn't have a size known at compile-time
    |
    = help: within `A<[u8]>`, the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `A<[u8]>`
    = note: the return type of a function must have a statically known size
 
diff --git a/src/test/ui/unsized-locals/unsized-exprs3.stderr b/src/test/ui/unsized-locals/unsized-exprs3.stderr
index 42f91a9..f9a7452 100644
--- a/src/test/ui/unsized-locals/unsized-exprs3.stderr
+++ b/src/test/ui/unsized-locals/unsized-exprs3.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: all function arguments must have a statically known size
    = help: unsized locals are gated as an unstable feature
 
diff --git a/src/test/ui/unsized/unsized-bare-typaram.stderr b/src/test/ui/unsized/unsized-bare-typaram.stderr
index 6f54ac5..cee1459 100644
--- a/src/test/ui/unsized/unsized-bare-typaram.stderr
+++ b/src/test/ui/unsized/unsized-bare-typaram.stderr
@@ -5,7 +5,7 @@
    |                       ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
 note: required by `bar`
   --> $DIR/unsized-bare-typaram.rs:1:1
diff --git a/src/test/ui/unsized/unsized-enum.stderr b/src/test/ui/unsized/unsized-enum.stderr
index 7d8c09e..20857a1 100644
--- a/src/test/ui/unsized/unsized-enum.stderr
+++ b/src/test/ui/unsized/unsized-enum.stderr
@@ -5,7 +5,7 @@
    |                                    ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
 note: required by `Foo`
   --> $DIR/unsized-enum.rs:4:1
diff --git a/src/test/ui/unsized/unsized-enum2.stderr b/src/test/ui/unsized/unsized-enum2.stderr
index 81135c3..9109366 100644
--- a/src/test/ui/unsized/unsized-enum2.stderr
+++ b/src/test/ui/unsized/unsized-enum2.stderr
@@ -5,7 +5,7 @@
    |        ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `W`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where W: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -16,7 +16,7 @@
    |        ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -27,7 +27,7 @@
    |               ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Y`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Y: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -38,7 +38,7 @@
    |                  ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Z`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Z: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -49,7 +49,7 @@
    |        ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
@@ -59,7 +59,7 @@
    |        ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[f32]` cannot be known at compilation time
@@ -69,7 +69,7 @@
    |               ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[f32]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[u32]` cannot be known at compilation time
@@ -79,7 +79,7 @@
    |                  ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u32]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `(dyn Foo + 'static)` cannot be known at compilation time
@@ -89,7 +89,7 @@
    |        ^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn Foo + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `(dyn Bar + 'static)` cannot be known at compilation time
@@ -99,7 +99,7 @@
    |        ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn Bar + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `(dyn FooBar + 'static)` cannot be known at compilation time
@@ -109,7 +109,7 @@
    |               ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn FooBar + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `(dyn BarFoo + 'static)` cannot be known at compilation time
@@ -119,7 +119,7 @@
    |                  ^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn BarFoo + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[i8]` cannot be known at compilation time
@@ -129,7 +129,7 @@
    |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[i8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[char]` cannot be known at compilation time
@@ -139,7 +139,7 @@
    |        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[char]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[f64]` cannot be known at compilation time
@@ -149,7 +149,7 @@
    |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[f64]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `[i32]` cannot be known at compilation time
@@ -159,7 +159,7 @@
    |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[i32]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: no field of an enum variant may have a dynamically sized type
 
 error[E0277]: the size for values of type `(dyn PathHelper1 + 'static)` cannot be known at compilation time
@@ -169,7 +169,7 @@
    |        ^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Path1`, the trait `std::marker::Sized` is not implemented for `(dyn PathHelper1 + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Path1`
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -180,7 +180,7 @@
    |        ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Path2`, the trait `std::marker::Sized` is not implemented for `(dyn PathHelper2 + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Path2`
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -191,7 +191,7 @@
    |               ^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Path3`, the trait `std::marker::Sized` is not implemented for `(dyn PathHelper3 + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Path3`
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -202,7 +202,7 @@
    |                  ^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Path4`, the trait `std::marker::Sized` is not implemented for `(dyn PathHelper4 + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required because it appears within the type `Path4`
    = note: no field of an enum variant may have a dynamically sized type
 
diff --git a/src/test/ui/unsized/unsized-inherent-impl-self-type.stderr b/src/test/ui/unsized/unsized-inherent-impl-self-type.stderr
index 1d157bf..98eecab 100644
--- a/src/test/ui/unsized/unsized-inherent-impl-self-type.stderr
+++ b/src/test/ui/unsized/unsized-inherent-impl-self-type.stderr
@@ -5,7 +5,7 @@
    |                 ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 note: required by `S5`
   --> $DIR/unsized-inherent-impl-self-type.rs:5:1
diff --git a/src/test/ui/unsized/unsized-struct.stderr b/src/test/ui/unsized/unsized-struct.stderr
index a72b3cf..7add65c 100644
--- a/src/test/ui/unsized/unsized-struct.stderr
+++ b/src/test/ui/unsized/unsized-struct.stderr
@@ -5,7 +5,7 @@
    |                                    ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
 note: required by `Foo`
   --> $DIR/unsized-struct.rs:4:1
@@ -20,7 +20,7 @@
    |                        ^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Bar<T>`, the trait `std::marker::Sized` is not implemented for `T`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where T: std::marker::Sized` bound
    = note: required because it appears within the type `Bar<T>`
 note: required by `is_sized`
diff --git a/src/test/ui/unsized/unsized-trait-impl-self-type.stderr b/src/test/ui/unsized/unsized-trait-impl-self-type.stderr
index 53ddad9..c39f365 100644
--- a/src/test/ui/unsized/unsized-trait-impl-self-type.stderr
+++ b/src/test/ui/unsized/unsized-trait-impl-self-type.stderr
@@ -5,7 +5,7 @@
    |                 ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 note: required by `S5`
   --> $DIR/unsized-trait-impl-self-type.rs:8:1
diff --git a/src/test/ui/unsized/unsized-trait-impl-trait-arg.stderr b/src/test/ui/unsized/unsized-trait-impl-trait-arg.stderr
index e664c1d..ee0d5cc 100644
--- a/src/test/ui/unsized/unsized-trait-impl-trait-arg.stderr
+++ b/src/test/ui/unsized/unsized-trait-impl-trait-arg.stderr
@@ -5,7 +5,7 @@
    |                 ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 
 error: aborting due to previous error
diff --git a/src/test/ui/unsized3.stderr b/src/test/ui/unsized3.stderr
index 8c2d713d..2c7b86c 100644
--- a/src/test/ui/unsized3.stderr
+++ b/src/test/ui/unsized3.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 note: required by `f2`
   --> $DIR/unsized3.rs:10:1
@@ -20,7 +20,7 @@
    |     ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 note: required by `f4`
   --> $DIR/unsized3.rs:21:1
@@ -35,7 +35,7 @@
    |     ^^ doesn't have a size known at compile-time
    |
    = help: within `S<X>`, the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: required because it appears within the type `S<X>`
 note: required by `f5`
@@ -51,7 +51,7 @@
    |     ^^ doesn't have a size known at compile-time
    |
    = help: within `S<X>`, the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: required because it appears within the type `S<X>`
    = note: only the last element of a tuple may have a dynamically sized type
@@ -63,7 +63,7 @@
    |         ^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `({integer}, S<X>)`, the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: required because it appears within the type `S<X>`
    = note: required because it appears within the type `({integer}, S<X>)`
@@ -76,7 +76,7 @@
    |     ^^ doesn't have a size known at compile-time
    |
    = help: within `({integer}, S<X>)`, the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: required because it appears within the type `S<X>`
    = note: required because it appears within the type `({integer}, S<X>)`
diff --git a/src/test/ui/unsized5.stderr b/src/test/ui/unsized5.stderr
index 9dc8c8f..6dce9a0 100644
--- a/src/test/ui/unsized5.stderr
+++ b/src/test/ui/unsized5.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: only the last field of a struct may have a dynamically sized type
 
@@ -16,7 +16,7 @@
    |     ^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: only the last field of a struct may have a dynamically sized type
 
@@ -27,7 +27,7 @@
    |     ^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `str`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: only the last field of a struct may have a dynamically sized type
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
@@ -37,7 +37,7 @@
    |     ^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: only the last field of a struct may have a dynamically sized type
 
 error[E0277]: the size for values of type `X` cannot be known at compilation time
@@ -47,7 +47,7 @@
    |        ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
@@ -58,7 +58,7 @@
    |        ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: no field of an enum variant may have a dynamically sized type
 
diff --git a/src/test/ui/unsized6.stderr b/src/test/ui/unsized6.stderr
index 058c22e..a6a2657 100644
--- a/src/test/ui/unsized6.stderr
+++ b/src/test/ui/unsized6.stderr
@@ -5,7 +5,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Y`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Y: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -17,7 +17,7 @@
    |            ^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: only the last element of a tuple may have a dynamically sized type
 
@@ -28,7 +28,7 @@
    |            ^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Z`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Z: std::marker::Sized` bound
    = note: only the last element of a tuple may have a dynamically sized type
 
@@ -39,7 +39,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -51,7 +51,7 @@
    |            ^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `Y`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where Y: std::marker::Sized` bound
    = note: only the last element of a tuple may have a dynamically sized type
 
@@ -62,7 +62,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -74,7 +74,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -86,7 +86,7 @@
    |          ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -98,7 +98,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -110,7 +110,7 @@
    |         ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -122,7 +122,7 @@
    |          ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -134,7 +134,7 @@
    |                  ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
@@ -146,7 +146,7 @@
    |                      ^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
    = note: all local variables must have a statically known size
    = help: unsized locals are gated as an unstable feature
diff --git a/src/test/ui/unsized7.stderr b/src/test/ui/unsized7.stderr
index 90f5a1f..bb83b18 100644
--- a/src/test/ui/unsized7.stderr
+++ b/src/test/ui/unsized7.stderr
@@ -5,7 +5,7 @@
    |                     ^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `X`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = help: consider adding a `where X: std::marker::Sized` bound
 
 error: aborting due to previous error
diff --git a/src/test/ui/utf8_idents.rs b/src/test/ui/utf8_idents.rs
index c9f433c..bed0d9b 100644
--- a/src/test/ui/utf8_idents.rs
+++ b/src/test/ui/utf8_idents.rs
@@ -3,6 +3,7 @@
 fn foo<
     'β, //~ ERROR non-ascii idents are not fully supported
     γ  //~ ERROR non-ascii idents are not fully supported
+       //~^ WARN type parameter `γ` should have a camel case name such as `Γ`
 >() {}
 
 struct X {
diff --git a/src/test/ui/utf8_idents.stderr b/src/test/ui/utf8_idents.stderr
index b1bb4a3..1ccf767 100644
--- a/src/test/ui/utf8_idents.stderr
+++ b/src/test/ui/utf8_idents.stderr
@@ -15,7 +15,7 @@
    = help: add #![feature(non_ascii_idents)] to the crate attributes to enable
 
 error[E0658]: non-ascii idents are not fully supported. (see issue #55467)
-  --> $DIR/utf8_idents.rs:9:5
+  --> $DIR/utf8_idents.rs:10:5
    |
 LL |     δ: usize //~ ERROR non-ascii idents are not fully supported
    |     ^
@@ -23,13 +23,21 @@
    = help: add #![feature(non_ascii_idents)] to the crate attributes to enable
 
 error[E0658]: non-ascii idents are not fully supported. (see issue #55467)
-  --> $DIR/utf8_idents.rs:13:9
+  --> $DIR/utf8_idents.rs:14:9
    |
 LL |     let α = 0.00001f64; //~ ERROR non-ascii idents are not fully supported
    |         ^
    |
    = help: add #![feature(non_ascii_idents)] to the crate attributes to enable
 
+warning: type parameter `γ` should have a camel case name such as `Γ`
+  --> $DIR/utf8_idents.rs:5:5
+   |
+LL |     γ  //~ ERROR non-ascii idents are not fully supported
+   |     ^
+   |
+   = note: #[warn(non_camel_case_types)] on by default
+
 error: aborting due to 4 previous errors
 
 For more information about this error, try `rustc --explain E0658`.
diff --git a/src/test/ui/wf/wf-array-elem-sized.stderr b/src/test/ui/wf/wf-array-elem-sized.stderr
index 249a2d0..69df9ea 100644
--- a/src/test/ui/wf/wf-array-elem-sized.stderr
+++ b/src/test/ui/wf/wf-array-elem-sized.stderr
@@ -5,7 +5,7 @@
    |     ^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `[u8]`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: slice and array elements must have `Sized` type
 
 error: aborting due to previous error
diff --git a/src/test/ui/wf/wf-fn-where-clause.stderr b/src/test/ui/wf/wf-fn-where-clause.stderr
index 62305be..594ce7d 100644
--- a/src/test/ui/wf/wf-fn-where-clause.stderr
+++ b/src/test/ui/wf/wf-fn-where-clause.stderr
@@ -20,7 +20,7 @@
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `std::marker::Sized` is not implemented for `(dyn std::marker::Copy + 'static)`
-   = note: to learn more, visit <https://doc.rust-lang.org/book/second-edition/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
+   = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
    = note: required by `std::vec::Vec`
 
 error[E0038]: the trait `std::marker::Copy` cannot be made into an object
diff --git a/src/tools/build-manifest/src/main.rs b/src/tools/build-manifest/src/main.rs
index 574526c..28c0b6c 100644
--- a/src/tools/build-manifest/src/main.rs
+++ b/src/tools/build-manifest/src/main.rs
@@ -192,6 +192,7 @@
     rustfmt_release: String,
     llvm_tools_release: String,
     lldb_release: String,
+    miri_release: String,
 
     input: PathBuf,
     output: PathBuf,
@@ -207,6 +208,7 @@
     rustfmt_version: Option<String>,
     llvm_tools_version: Option<String>,
     lldb_version: Option<String>,
+    miri_version: Option<String>,
 
     rust_git_commit_hash: Option<String>,
     cargo_git_commit_hash: Option<String>,
@@ -215,6 +217,7 @@
     rustfmt_git_commit_hash: Option<String>,
     llvm_tools_git_commit_hash: Option<String>,
     lldb_git_commit_hash: Option<String>,
+    miri_git_commit_hash: Option<String>,
 
     should_sign: bool,
 }
@@ -237,13 +240,14 @@
     let output = PathBuf::from(args.next().unwrap());
     let date = args.next().unwrap();
     let rust_release = args.next().unwrap();
+    let s3_address = args.next().unwrap();
     let cargo_release = args.next().unwrap();
     let rls_release = args.next().unwrap();
     let clippy_release = args.next().unwrap();
+    let miri_release = args.next().unwrap();
     let rustfmt_release = args.next().unwrap();
     let llvm_tools_release = args.next().unwrap();
     let lldb_release = args.next().unwrap();
-    let s3_address = args.next().unwrap();
 
     // Do not ask for a passphrase while manually testing
     let mut passphrase = String::new();
@@ -259,6 +263,7 @@
         rustfmt_release,
         llvm_tools_release,
         lldb_release,
+        miri_release,
 
         input,
         output,
@@ -274,6 +279,7 @@
         rustfmt_version: None,
         llvm_tools_version: None,
         lldb_version: None,
+        miri_version: None,
 
         rust_git_commit_hash: None,
         cargo_git_commit_hash: None,
@@ -282,6 +288,7 @@
         rustfmt_git_commit_hash: None,
         llvm_tools_git_commit_hash: None,
         lldb_git_commit_hash: None,
+        miri_git_commit_hash: None,
 
         should_sign,
     }.build();
@@ -297,6 +304,7 @@
         self.llvm_tools_version = self.version("llvm-tools", "x86_64-unknown-linux-gnu");
         // lldb is only built for macOS.
         self.lldb_version = self.version("lldb", "x86_64-apple-darwin");
+        self.miri_version = self.version("miri", "x86_64-unknown-linux-gnu");
 
         self.rust_git_commit_hash = self.git_commit_hash("rust", "x86_64-unknown-linux-gnu");
         self.cargo_git_commit_hash = self.git_commit_hash("cargo", "x86_64-unknown-linux-gnu");
@@ -306,6 +314,7 @@
         self.llvm_tools_git_commit_hash = self.git_commit_hash("llvm-tools",
                                                                "x86_64-unknown-linux-gnu");
         self.lldb_git_commit_hash = self.git_commit_hash("lldb", "x86_64-unknown-linux-gnu");
+        self.miri_git_commit_hash = self.git_commit_hash("miri", "x86_64-unknown-linux-gnu");
 
         self.digest_and_sign();
         let manifest = self.build_manifest();
@@ -516,6 +525,8 @@
             format!("llvm-tools-{}-{}.tar.gz", self.llvm_tools_release, target)
         } else if component == "lldb" || component == "lldb-preview" {
             format!("lldb-{}-{}.tar.gz", self.lldb_release, target)
+        } else if component == "miri" || component == "miri-preview" {
+            format!("miri-{}-{}.tar.gz", self.miri_release, target)
         } else {
             format!("{}-{}-{}.tar.gz", component, self.rust_release, target)
         }
@@ -534,6 +545,8 @@
             &self.llvm_tools_version
         } else if component == "lldb" || component == "lldb-preview" {
             &self.lldb_version
+        } else if component == "miri" || component == "miri-preview" {
+            &self.miri_version
         } else {
             &self.rust_version
         }
@@ -552,6 +565,8 @@
             &self.llvm_tools_git_commit_hash
         } else if component == "lldb" || component == "lldb-preview" {
             &self.lldb_git_commit_hash
+        } else if component == "miri" || component == "miri-preview" {
+            &self.miri_git_commit_hash
         } else {
             &self.rust_git_commit_hash
         }
diff --git a/src/tools/clippy b/src/tools/clippy
index 39bd844..c63b634 160000
--- a/src/tools/clippy
+++ b/src/tools/clippy
@@ -1 +1 @@
-Subproject commit 39bd84494f4a9b40f2e3b38416a91d52d5c4738b
+Subproject commit c63b6349b44019146cc2edcef8141692891b9401
diff --git a/src/tools/compiletest/src/main.rs b/src/tools/compiletest/src/main.rs
index c35addc..2e5feca 100644
--- a/src/tools/compiletest/src/main.rs
+++ b/src/tools/compiletest/src/main.rs
@@ -489,7 +489,7 @@
     // Let tests know which target they're running as
     env::set_var("TARGET", &config.target);
 
-    let res = test::run_tests_console(&opts, tests.into_iter().collect());
+    let res = test::run_tests_console(&opts, tests);
     match res {
         Ok(true) => {}
         Ok(false) => panic!("Some tests failed"),
@@ -548,22 +548,18 @@
     relative_dir_path: &Path,
     tests: &mut Vec<test::TestDescAndFn>,
 ) -> io::Result<()> {
-    // Ignore directories that contain a file
-    // `compiletest-ignore-dir`.
-    for file in fs::read_dir(dir)? {
-        let file = file?;
-        let name = file.file_name();
-        if name == *"compiletest-ignore-dir" {
-            return Ok(());
-        }
-        if name == *"Makefile" && config.mode == Mode::RunMake {
-            let paths = TestPaths {
-                file: dir.to_path_buf(),
-                relative_dir: relative_dir_path.parent().unwrap().to_path_buf(),
-            };
-            tests.extend(make_test(config, &paths));
-            return Ok(());
-        }
+    // Ignore directories that contain a file named `compiletest-ignore-dir`.
+    if dir.join("compiletest-ignore-dir").exists() {
+        return Ok(());
+    }
+
+    if config.mode == Mode::RunMake && dir.join("Makefile").exists() {
+        let paths = TestPaths {
+            file: dir.to_path_buf(),
+            relative_dir: relative_dir_path.parent().unwrap().to_path_buf(),
+        };
+        tests.extend(make_test(config, &paths));
+        return Ok(());
     }
 
     // If we find a test foo/bar.rs, we have to build the
@@ -577,8 +573,7 @@
 
     // Add each `.rs` file as a test, and recurse further on any
     // subdirectories we find, except for `aux` directories.
-    let dirs = fs::read_dir(dir)?;
-    for file in dirs {
+    for file in fs::read_dir(dir)? {
         let file = file?;
         let file_path = file.path();
         let file_name = file.file_name();
@@ -679,7 +674,7 @@
     WalkDir::new(path)
         .into_iter()
         .map(|entry| entry.unwrap())
-        .filter(|entry| entry.metadata().unwrap().is_file())
+        .filter(|entry| entry.file_type().is_file())
         .map(|entry| mtime(entry.path()))
 }
 
@@ -707,14 +702,12 @@
         .expect("Could not find Rust source root");
     let stamp = mtime(&stamp_name);
     let mut inputs = vec![mtime(&testpaths.file), mtime(&config.rustc_path)];
-    for aux in props.aux.iter() {
-        inputs.push(mtime(&testpaths
-            .file
-            .parent()
-            .unwrap()
-            .join("auxiliary")
-            .join(aux)));
-    }
+    inputs.extend(
+        props
+            .aux
+            .iter()
+            .map(|aux| mtime(&testpaths.file.parent().unwrap().join("auxiliary").join(aux))),
+    );
     // Relevant pretty printer files
     let pretty_printer_files = [
         "src/etc/debugger_pretty_printers_common.py",
@@ -723,9 +716,9 @@
         "src/etc/lldb_batchmode.py",
         "src/etc/lldb_rust_formatters.py",
     ];
-    for pretty_printer_file in &pretty_printer_files {
-        inputs.push(mtime(&rust_src_dir.join(pretty_printer_file)));
-    }
+    inputs.extend(pretty_printer_files.iter().map(|pretty_printer_file| {
+        mtime(&rust_src_dir.join(pretty_printer_file))
+    }));
     inputs.extend(collect_timestamps(&config.run_lib_path));
     if let Some(ref rustdoc_path) = config.rustdoc_path {
         inputs.push(mtime(&rustdoc_path));
@@ -733,10 +726,10 @@
     }
 
     // UI test files.
-    for extension in UI_EXTENSIONS {
+    inputs.extend(UI_EXTENSIONS.iter().map(|extension| {
         let path = &expected_output_path(testpaths, revision, &config.compare_mode, extension);
-        inputs.push(mtime(path));
-    }
+        mtime(path)
+    }));
 
     // Compiletest itself.
     inputs.extend(collect_timestamps(&rust_src_dir.join("src/tools/compiletest/")));
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs
index 84f3f30..400c205 100644
--- a/src/tools/compiletest/src/runtest.rs
+++ b/src/tools/compiletest/src/runtest.rs
@@ -2569,7 +2569,7 @@
             .env("LLVM_CXXFLAGS", &self.config.llvm_cxxflags)
 
             // We for sure don't want these tests to run in parallel, so make
-            // sure they don't have access to these vars if we we run via `make`
+            // sure they don't have access to these vars if we run via `make`
             // at the top level
             .env_remove("MAKEFLAGS")
             .env_remove("MFLAGS")
diff --git a/src/tools/rls b/src/tools/rls
index 6f5e4bb..1a6361b 160000
--- a/src/tools/rls
+++ b/src/tools/rls
@@ -1 +1 @@
-Subproject commit 6f5e4bba7b1586fca6e0ea7724cadb5683b2f308
+Subproject commit 1a6361bd399a9466deba9b42ff2ff2ae365c5d0e
diff --git a/src/tools/rustc-workspace-hack/Cargo.toml b/src/tools/rustc-workspace-hack/Cargo.toml
index ca44016..c4499ef 100644
--- a/src/tools/rustc-workspace-hack/Cargo.toml
+++ b/src/tools/rustc-workspace-hack/Cargo.toml
@@ -27,18 +27,21 @@
   "errhandlingapi",
   "jobapi",
   "jobapi2",
+  "knownfolders",
   "lmcons",
   "memoryapi",
   "minschannel",
   "minwinbase",
   "ntsecapi",
   "ntstatus",
+  "objbase",
   "profileapi",
   "processenv",
   "psapi",
   "schannel",
   "securitybaseapi",
   "shellapi",
+  "shlobj",
   "sspi",
   "synchapi",
   "sysinfoapi",
@@ -50,12 +53,15 @@
 ]
 
 [dependencies]
-curl-sys = { version = "0.4.13", optional = true }
+curl-sys = { version = "0.4.13", features = ["http2", "libnghttp2-sys"], optional = true }
 parking_lot = { version = "0.6", features = ['nightly'] }
 rand = { version = "0.5.5", features = ["i128_support"] }
 serde = { version = "1.0.82", features = ['derive'] }
 serde_json = { version = "1.0.31", features = ["raw_value"] }
 smallvec = { version = "0.6", features = ['union'] }
+scopeguard = { version = "0.3.3", features = ["use_std", "default"]}
+byteorder = { version = "1.2.7", features = ["i128"]}
+
 
 [target.'cfg(not(windows))'.dependencies]
 openssl = { version = "0.10.12", optional = true }