Skip to content

Commit b87b0a3

Browse files
committed
Auto merge of rust-lang#121069 - cuviper:beta-next, r=cuviper
[beta] backports - Correct paths for hexagon-unknown-none-elf platform doc rust-lang#120533 - CI: Use ninja on apple builders rust-lang#120543 - Correctly check `never_type` feature gating rust-lang#120552 - Revert unsound libcore changes of 119911 rust-lang#120562 r? cuviper
2 parents 3d66104 + a686e61 commit b87b0a3

File tree

12 files changed

+228
-458
lines changed

12 files changed

+228
-458
lines changed

Diff for: .github/workflows/ci.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ jobs:
319319
- name: dist-x86_64-apple
320320
env:
321321
SCRIPT: "./x.py dist bootstrap --include-default-paths --host=x86_64-apple-darwin --target=x86_64-apple-darwin"
322-
RUST_CONFIGURE_ARGS: "--enable-full-tools --enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false --set rust.lto=thin"
322+
RUST_CONFIGURE_ARGS: "--enable-full-tools --enable-sanitizers --enable-profiler --set rust.jemalloc --set rust.lto=thin"
323323
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
324324
MACOSX_DEPLOYMENT_TARGET: 10.12
325325
SELECT_XCODE: /Applications/Xcode_13.4.1.app
@@ -332,7 +332,7 @@ jobs:
332332
- name: dist-apple-various
333333
env:
334334
SCRIPT: "./x.py dist bootstrap --include-default-paths --host='' --target=aarch64-apple-ios,x86_64-apple-ios,aarch64-apple-ios-sim"
335-
RUST_CONFIGURE_ARGS: "--enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false"
335+
RUST_CONFIGURE_ARGS: "--enable-sanitizers --enable-profiler --set rust.jemalloc"
336336
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
337337
MACOSX_DEPLOYMENT_TARGET: 10.12
338338
SELECT_XCODE: /Applications/Xcode_13.4.1.app
@@ -343,7 +343,7 @@ jobs:
343343
- name: x86_64-apple-1
344344
env:
345345
SCRIPT: "./x.py --stage 2 test --skip tests/ui --skip tests/rustdoc --skip tests/run-make-fulldeps"
346-
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false"
346+
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --enable-sanitizers --enable-profiler --set rust.jemalloc"
347347
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
348348
MACOSX_DEPLOYMENT_TARGET: 10.12
349349
MACOSX_STD_DEPLOYMENT_TARGET: 10.12
@@ -354,7 +354,7 @@ jobs:
354354
- name: x86_64-apple-2
355355
env:
356356
SCRIPT: "./x.py --stage 2 test tests/ui tests/rustdoc tests/run-make-fulldeps"
357-
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false"
357+
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --enable-sanitizers --enable-profiler --set rust.jemalloc"
358358
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
359359
MACOSX_DEPLOYMENT_TARGET: 10.12
360360
MACOSX_STD_DEPLOYMENT_TARGET: 10.12
@@ -365,7 +365,7 @@ jobs:
365365
- name: dist-aarch64-apple
366366
env:
367367
SCRIPT: "./x.py dist bootstrap --include-default-paths --stage 2"
368-
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --host=aarch64-apple-darwin --target=aarch64-apple-darwin --enable-full-tools --enable-sanitizers --enable-profiler --disable-docs --set rust.jemalloc --set llvm.ninja=false"
368+
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --host=aarch64-apple-darwin --target=aarch64-apple-darwin --enable-full-tools --enable-sanitizers --enable-profiler --disable-docs --set rust.jemalloc"
369369
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
370370
SELECT_XCODE: /Applications/Xcode_13.4.1.app
371371
USE_XCODE_CLANG: 1

Diff for: compiler/rustc_ast_passes/src/feature_gate.rs

+13
Original file line numberDiff line numberDiff line change
@@ -362,6 +362,19 @@ impl<'a> Visitor<'a> for PostExpansionVisitor<'a> {
362362
}
363363
}
364364

365+
fn visit_generic_args(&mut self, args: &'a ast::GenericArgs) {
366+
// This check needs to happen here because the never type can be returned from a function,
367+
// but cannot be used in any other context. If this check was in `visit_fn_ret_ty`, it
368+
// include both functions and generics like `impl Fn() -> !`.
369+
if let ast::GenericArgs::Parenthesized(generic_args) = args
370+
&& let ast::FnRetTy::Ty(ref ty) = generic_args.output
371+
&& matches!(ty.kind, ast::TyKind::Never)
372+
{
373+
gate!(&self, never_type, ty.span, "the `!` type is experimental");
374+
}
375+
visit::walk_generic_args(self, args);
376+
}
377+
365378
fn visit_expr(&mut self, e: &'a ast::Expr) {
366379
match e.kind {
367380
ast::ExprKind::TryBlock(_) => {

Diff for: library/core/src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,6 @@
200200
//
201201
// Language features:
202202
// tidy-alphabetical-start
203-
#![cfg_attr(not(bootstrap), feature(is_val_statically_known))]
204203
#![feature(abi_unadjusted)]
205204
#![feature(adt_const_params)]
206205
#![feature(allow_internal_unsafe)]

0 commit comments

Comments
 (0)