Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 16 pull requests #126319

Merged
merged 38 commits into from
Jun 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
8e91a51
DOC: Add FFI example for slice::from_raw_parts()
mgeier Apr 2, 2024
22319bf
Add "safety" comment
mgeier Apr 26, 2024
4df1303
Extend the example code and assert the result
mgeier Apr 26, 2024
30b676c
Add missing .into_iter()
mgeier Apr 26, 2024
c8a3697
Recommend to never display zero disambiguators when demangling v0 sym…
michaelwoerister Apr 29, 2024
14348d9
NVPTX: Avoid PassMode::Direct for C ABI
May 31, 2024
a49fe0a
NVPTX:_Especially add the DoubleI32 struct as a nvptx abi test case s…
May 31, 2024
c59a2b2
Cleanup: HIR ty lowering: Consolidate assoc item access checking
fmease Jun 4, 2024
fe52b54
docs(core): make more const_ptr doctests assert instead of printing
lolbinarycat Jun 10, 2024
1462f3d
Add {{target}} substitution to compiletest
Veykril Jun 11, 2024
d695544
Simplify `[T; N]::try_map` signature
workingjubilee Jun 11, 2024
26fa5c2
Make issue-122805.rs big endian compatible
nikic Jun 11, 2024
751143e
set_env: State the conclusion upfront
ChrisDenton Jun 11, 2024
1a60597
Make `storage-live.rs` robust against rustc internal changes.
nnethercote Jun 11, 2024
7e7da49
Update a cranelift patch file for formatting changes.
nnethercote Jun 11, 2024
0b3fec9
For E0277 suggest adding `Result` return type for function which usin…
surechen Jun 9, 2024
75b164d
Use `tidy` to sort crate attributes for all compiler crates.
nnethercote Jun 12, 2024
af04418
Make PathBuf less Ok with adding UTF-16 then `into_string`
workingjubilee Jun 12, 2024
f2cce98
Migrate `run-make/prefer-rlib` to `rmake.rs`
GuillaumeGomez Jun 12, 2024
d79aeaf
Remove unused import in `run-make/prefer-dylib/rmake.rs`
GuillaumeGomez Jun 12, 2024
bbc5509
fix RELEASES: we do not support upcasting to auto traits
lcnr Jun 12, 2024
45a9bd5
Use `fs_wrapper` in `run-make/prefer-dylib`
GuillaumeGomez Jun 12, 2024
8d3b9a1
Rollup merge of #123374 - mgeier:doc-slice-from-raw-parts, r=scottmcm
workingjubilee Jun 12, 2024
969056d
Rollup merge of #124514 - michaelwoerister:zero-disambiguator-demangl…
workingjubilee Jun 12, 2024
e7b07ea
Rollup merge of #125978 - fmease:cleanup-hir-ty-lowering-consolidate-…
workingjubilee Jun 12, 2024
322af5c
Rollup merge of #125980 - kjetilkjeka:nvptx_remove_direct_passmode, r…
workingjubilee Jun 12, 2024
519a322
Rollup merge of #126187 - surechen:fix_125997, r=oli-obk
workingjubilee Jun 12, 2024
3a37293
Rollup merge of #126210 - lolbinarycat:ptr_doctest_assert, r=workingj…
workingjubilee Jun 12, 2024
4de77b6
Rollup merge of #126249 - workingjubilee:simplify-try-map-signature, …
workingjubilee Jun 12, 2024
3997b62
Rollup merge of #126256 - ferrocene:lw-target-subst, r=albertlarsan68
workingjubilee Jun 12, 2024
0ed474a
Rollup merge of #126263 - nikic:s390x-codegen-test-fix, r=jieyouxu
workingjubilee Jun 12, 2024
0805ab4
Rollup merge of #126281 - ChrisDenton:env, r=jhpratt
workingjubilee Jun 12, 2024
6cde179
Rollup merge of #126286 - nnethercote:fix-test-LL-CC, r=lqd
workingjubilee Jun 12, 2024
ac73965
Rollup merge of #126287 - nnethercote:reformat-cranelift-patch, r=bjorn3
workingjubilee Jun 12, 2024
36e828f
Rollup merge of #126301 - nnethercote:sort-crate-attributes, r=davidtwco
workingjubilee Jun 12, 2024
3862f01
Rollup merge of #126305 - workingjubilee:fix-os-string-to-string-utf8…
workingjubilee Jun 12, 2024
6f4f405
Rollup merge of #126310 - GuillaumeGomez:migrate-run-make-prefer-rlib…
workingjubilee Jun 12, 2024
0a52849
Rollup merge of #126314 - lcnr:fix-relnotes, r=pietroalbini
workingjubilee Jun 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ Language
- [Split `refining_impl_trait` lint into `_reachable`, `_internal` variants](https://github.com/rust-lang/rust/pull/121720/)
- [Remove unnecessary type inference when using associated types inside of higher ranked `where`-bounds](https://github.com/rust-lang/rust/pull/119849)
- [Weaken eager detection of cyclic types during type inference](https://github.com/rust-lang/rust/pull/119989)
- [`trait Trait: Auto {}`: allow upcasting from `dyn Trait` to `dyn Auto`](https://github.com/rust-lang/rust/pull/119338)
- [`trait Trait: Auto {}`: allow upcasting from `dyn Trait` to `dyn Trait + Auto`](https://github.com/rust-lang/rust/pull/119338)

<a id="1.78.0-Compiler"></a>

Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_abi/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#![cfg_attr(feature = "nightly", feature(step_trait))]
// tidy-alphabetical-start
#![cfg_attr(feature = "nightly", allow(internal_features))]
#![cfg_attr(feature = "nightly", doc(rust_logo))]
#![cfg_attr(feature = "nightly", feature(rustdoc_internals))]
#![cfg_attr(feature = "nightly", feature(step_trait))]
// tidy-alphabetical-end

use std::fmt;
use std::num::{NonZeroUsize, ParseIntError};
Expand Down
16 changes: 9 additions & 7 deletions compiler/rustc_arena/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,25 @@
//!
//! This crate implements several kinds of arena.

// tidy-alphabetical-start
#![allow(clippy::mut_from_ref)] // Arena allocators are one place where this pattern is fine.
#![allow(internal_features)]
#![cfg_attr(test, feature(test))]
#![deny(unsafe_op_in_unsafe_fn)]
#![doc(
html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/",
test(no_crate_inject, attr(deny(warnings)))
)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
#![feature(core_intrinsics)]
#![feature(decl_macro)]
#![feature(dropck_eyepatch)]
#![feature(new_uninit)]
#![feature(maybe_uninit_slice)]
#![feature(decl_macro)]
#![feature(new_uninit)]
#![feature(rustc_attrs)]
#![cfg_attr(test, feature(test))]
#![feature(rustdoc_internals)]
#![feature(strict_provenance)]
#![deny(unsafe_op_in_unsafe_fn)]
#![allow(internal_features)]
#![allow(clippy::mut_from_ref)] // Arena allocators are one of the places where this pattern is fine.
// tidy-alphabetical-end

use smallvec::SmallVec;

Expand Down
8 changes: 5 additions & 3 deletions compiler/rustc_ast/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,22 @@
//!
//! This API is completely unstable and subject to change.

// tidy-alphabetical-start
#![allow(internal_features)]
#![doc(
html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/",
test(attr(deny(warnings)))
)]
#![doc(rust_logo)]
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![feature(associated_type_defaults)]
#![feature(box_patterns)]
#![feature(if_let_guard)]
#![feature(let_chains)]
#![feature(never_type)]
#![feature(negative_impls)]
#![feature(never_type)]
#![feature(rustdoc_internals)]
#![feature(stmt_expr_attributes)]
// tidy-alphabetical-end

pub mod util {
pub mod case;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_ast_ir/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// tidy-alphabetical-start
#![cfg_attr(feature = "nightly", allow(internal_features))]
#![cfg_attr(feature = "nightly", feature(never_type))]
#![cfg_attr(feature = "nightly", feature(rustc_attrs))]
#![cfg_attr(feature = "nightly", allow(internal_features))]
// tidy-alphabetical-end

#[cfg(feature = "nightly")]
use rustc_macros::{Decodable, Encodable, HashStable_NoContext};
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_ast_lowering/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,14 @@
//! get confused if the spans from leaf AST nodes occur in multiple places
//! in the HIR, especially for multiple identifiers.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(assert_matches)]
#![feature(box_patterns)]
#![feature(let_chains)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

use crate::errors::{AssocTyParentheses, AssocTyParenthesesSub, MisplacedImplTrait};
use rustc_ast::node_id::NodeMap;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_ast_passes/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
//!
//! The crate also contains other misc AST visitors, e.g. `node_count` and `show_span`.

// tidy-alphabetical-start
#![allow(internal_features)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
#![feature(box_patterns)]
#![feature(if_let_guard)]
#![feature(iter_is_partitioned)]
#![feature(let_chains)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

pub mod ast_validation;
mod errors;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_ast_pretty/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(box_patterns)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

mod helpers;
pub mod pp;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_attr/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@
//! The goal is to move the definition of `MetaItem` and things that don't need to be in `syntax`
//! to this crate.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(let_chains)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

mod builtin;
mod session_diagnostics;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_baked_icu_data/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,12 @@
//! --cldr-tag latest --icuexport-tag latest -o src/data
//! ```

// tidy-alphabetical-start
#![allow(elided_lifetimes_in_paths)]
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![allow(elided_lifetimes_in_paths)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

mod data {
include!("data/mod.rs");
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_borrowck/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! This query borrow-checks the MIR to (further) ensure it is not broken.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(assert_matches)]
#![feature(box_patterns)]
Expand All @@ -10,8 +10,10 @@
#![feature(min_specialization)]
#![feature(never_type)]
#![feature(rustc_attrs)]
#![feature(rustdoc_internals)]
#![feature(stmt_expr_attributes)]
#![feature(try_blocks)]
// tidy-alphabetical-end

#[macro_use]
extern crate tracing;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_builtin_macros/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
//! This crate contains implementations of built-in macros and other code generating facilities
//! injecting code into the crate before it is lowered to HIR.

// tidy-alphabetical-start
#![allow(internal_features)]
#![allow(rustc::diagnostic_outside_of_impl)]
#![allow(rustc::untranslatable_diagnostic)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
#![doc(rust_logo)]
#![feature(assert_matches)]
#![feature(box_patterns)]
#![feature(decl_macro)]
Expand All @@ -15,7 +15,9 @@
#![feature(lint_reasons)]
#![feature(proc_macro_internals)]
#![feature(proc_macro_quote)]
#![feature(rustdoc_internals)]
#![feature(try_blocks)]
// tidy-alphabetical-end

extern crate proc_macro;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ diff --git a/library/std/src/sys/pal/windows/c.rs b/library/std/src/sys/pal/wind
index ad8e01bfa9b..9ca8e4c16ce 100644
--- a/library/std/src/sys/pal/windows/c.rs
+++ b/library/std/src/sys/pal/windows/c.rs
@@ -323,7 +323,7 @@ pub unsafe fn NtWriteFile(
@@ -312,7 +312,7 @@ pub unsafe fn NtWriteFile(

// Use raw-dylib to import ProcessPrng as we can't rely on there being an import library.
cfg_if::cfg_if! {
Expand All @@ -26,8 +26,8 @@ index e427546222a..f2fe42a4d51 100644
--- a/library/std/src/sys/pal/windows/rand.rs
+++ b/library/std/src/sys/pal/windows/rand.rs
@@ -2,7 +2,7 @@
use core::mem;
use core::ptr;

use crate::sys::c;

-#[cfg(not(target_vendor = "win7"))]
+#[cfg(any())]
Expand Down
11 changes: 7 additions & 4 deletions compiler/rustc_codegen_cranelift/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
// tidy-alphabetical-start
#![allow(rustc::diagnostic_outside_of_impl)]
#![allow(rustc::untranslatable_diagnostic)]
#![cfg_attr(doc, allow(internal_features))]
#![cfg_attr(doc, feature(rustdoc_internals))]
#![cfg_attr(doc, doc(rust_logo))]
#![cfg_attr(doc, feature(rustdoc_internals))]
// Note: please avoid adding other feature gates where possible
#![feature(rustc_private)]
// Note: please avoid adding other feature gates where possible
#![allow(rustc::diagnostic_outside_of_impl)]
#![allow(rustc::untranslatable_diagnostic)]
#![warn(rust_2018_idioms)]
#![warn(unused_lifetimes)]
#![warn(unreachable_pub)]
#![warn(unused_lifetimes)]
// tidy-alphabetical-end

extern crate jobserver;
#[macro_use]
Expand Down
8 changes: 5 additions & 3 deletions compiler/rustc_codegen_llvm/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,18 @@
//!
//! This API is completely unstable and subject to change.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
#![doc(rust_logo)]
#![feature(exact_size_is_empty)]
#![feature(extern_types)]
#![feature(hash_raw_entry)]
#![feature(impl_trait_in_assoc_type)]
#![feature(iter_intersperse)]
#![feature(let_chains)]
#![feature(impl_trait_in_assoc_type)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

use back::owned_target_machine::OwnedTargetMachine;
use back::write::{create_informational_target_machine, create_target_machine};
Expand Down
8 changes: 5 additions & 3 deletions compiler/rustc_codegen_ssa/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-start
#![allow(internal_features)]
#![allow(rustc::diagnostic_outside_of_impl)]
#![allow(rustc::untranslatable_diagnostic)]
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
#![doc(rust_logo)]
#![feature(box_patterns)]
#![feature(if_let_guard)]
#![feature(let_chains)]
#![feature(negative_impls)]
#![feature(rustdoc_internals)]
#![feature(strict_provenance)]
#![feature(try_blocks)]
// tidy-alphabetical-end

//! This crate contains codegen code that is used by all codegen backends (LLVM and others).
//! The backend-agnostic functions of this crate use functions defined in various traits that
Expand Down
8 changes: 5 additions & 3 deletions compiler/rustc_const_eval/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
// tidy-alphabetical-start
#![allow(internal_features)]
#![allow(rustc::diagnostic_outside_of_impl)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(assert_matches)]
#![feature(box_patterns)]
#![feature(decl_macro)]
#![feature(if_let_guard)]
#![feature(let_chains)]
#![feature(never_type)]
#![feature(rustdoc_internals)]
#![feature(slice_ptr_get)]
#![feature(strict_provenance)]
#![feature(never_type)]
#![feature(trait_alias)]
#![feature(try_blocks)]
#![feature(yeet_expr)]
#![feature(if_let_guard)]
// tidy-alphabetical-end

pub mod check_consts;
pub mod const_eval;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_driver/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
// This crate is intentionally empty and a re-export of `rustc_driver_impl` to allow the code in
// `rustc_driver_impl` to be compiled in parallel with other crates.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

pub use rustc_driver_impl::*;
6 changes: 4 additions & 2 deletions compiler/rustc_driver_impl/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,18 @@
//!
//! This API is completely unstable and subject to change.

// tidy-alphabetical-start
#![allow(internal_features)]
#![allow(rustc::untranslatable_diagnostic)] // FIXME: make this translatable
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
#![allow(internal_features)]
#![feature(decl_macro)]
#![feature(let_chains)]
#![feature(panic_backtrace_config)]
#![feature(panic_update_hook)]
#![feature(result_flattening)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

use rustc_ast as ast;
use rustc_codegen_ssa::{traits::CodegenBackend, CodegenErrors, CodegenResults};
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_error_codes/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
//! This library is used to gather all error codes into one place, to make
//! their maintenance easier.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![deny(rustdoc::invalid_codeblock_attributes)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

// This higher-order macro defines the error codes that are in use. It is used
// in the `rustc_errors` crate. Removed error codes are listed in the comment
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_error_messages/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
// tidy-alphabetical-start
#![allow(internal_features)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
#![feature(rustc_attrs)]
#![feature(rustdoc_internals)]
#![feature(type_alias_impl_trait)]
#![allow(internal_features)]
// tidy-alphabetical-end

use fluent_bundle::FluentResource;
use fluent_syntax::parser::ParserError;
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_feature/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,11 @@
//! even if it is stabilized or removed, *do not remove it*. Instead, move the
//! symbol to the `accepted` or `removed` modules respectively.

// tidy-alphabetical-start
#![allow(internal_features)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![feature(rustdoc_internals)]
// tidy-alphabetical-end

mod accepted;
mod builtin_attrs;
Expand Down
Loading
Loading