Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
8e30f04
Skip linting unused braces for FunctionArg and MethodArg context for …
chenyukang Mar 25, 2026
85adfcf
run intrinsic-test by default on x86_64-gnu
xonx4l Jul 26, 2026
7f8e276
add regression test for stale closure recovery state
TaKO8Ki Jul 27, 2026
da2697d
reset closure recovery state before parsing a statement
TaKO8Ki Jul 27, 2026
7696641
Add regression test for fn-ptr coercion normalization ICE
zakrad Jul 27, 2026
4ab575d
Update `browser-ui-test` version to `0.25.0`
GuillaumeGomez Jul 27, 2026
51a9794
Improve consistency of proc macro attribute error messages
nnethercote Jul 28, 2026
c9be59d
Improve consistency of `rustc_abi` attribute error messages
nnethercote Jul 28, 2026
02df958
Improve consistency of `rustc_const_stable` attribute error messages
nnethercote Jul 28, 2026
909079f
Improve consistency of `diagnostic::on_const` attribute error messages
nnethercote Jul 28, 2026
6c97237
Improve consistency of `test`/`bench` attribute error messages
nnethercote Jul 28, 2026
8704b63
Improve consistency of unsafe attribute error messages
nnethercote Jul 28, 2026
8bfa429
Add regression test for generic associated function suggestions
chenyukang Jul 28, 2026
c9dbe2b
Use value syntax for associated function suggestions
chenyukang Jul 28, 2026
1d32220
Add missing `"clipboard-read"` permission
GuillaumeGomez Jul 28, 2026
23e9a09
add build.sde to bootstrap.example.toml
xonx4l Jul 28, 2026
32246e5
Update Rust crate tracing-subscriber to v0.3.23 [SECURITY]
renovate-bot Jul 28, 2026
c35d330
sanitize_standard_fds: clarify macos comment
RalfJung Jul 28, 2026
0d16cb1
use unstable features when updating dependencies
marcoieni Jul 28, 2026
7b8f260
Replace most `Ty::new_fn_def` calls with `type_of` queries directly
Jul 21, 2026
8f77183
Rollup merge of #159665 - addiesh:turbofish-fear-me, r=oli-obk
JonathanBrouwer Jul 28, 2026
bd65482
Rollup merge of #154373 - chenyukang:yukang-fix-154247-unused-braces-…
JonathanBrouwer Jul 28, 2026
e281054
Rollup merge of #159978 - xonx4l:x86-intrinsic-test-default, r=Kobzol
JonathanBrouwer Jul 28, 2026
71d0d26
Rollup merge of #160008 - TaKO8Ki:fix-stale-closure-recovery, r=mati865
JonathanBrouwer Jul 28, 2026
27f71b2
Rollup merge of #160027 - zakrad:regr-test-132767, r=chenyukang
JonathanBrouwer Jul 28, 2026
3b4927a
Rollup merge of #160030 - GuillaumeGomez:update-browser-ui-test, r=Gu…
JonathanBrouwer Jul 28, 2026
95ffbd0
Rollup merge of #160046 - nnethercote:attr-errors-2, r=estebank
JonathanBrouwer Jul 28, 2026
d3bfc05
Rollup merge of #160056 - chenyukang:yukang-fix-159813-assoc-fn-turbo…
JonathanBrouwer Jul 28, 2026
4f7d297
Rollup merge of #160069 - renovate-bot:renovate/crate-tracing-subscri…
JonathanBrouwer Jul 28, 2026
152ea51
Rollup merge of #160071 - RalfJung:sanitize_standard_fds, r=clarfonthey
JonathanBrouwer Jul 28, 2026
947cdca
Rollup merge of #160076 - marcoieni:renovate-lockfile-update-fix, r=K…
JonathanBrouwer Jul 28, 2026
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
27 changes: 27 additions & 0 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,17 @@
// (still gated by dashboard approval for now)
":maintainLockFilesMonthly",
],
// Cargo manifests in this repository use unstable features.
"env": {
"RUSTC_BOOTSTRAP": "1"
},
// The compiler and rustbook workspaces have path dependencies in these
// submodules.
"cloneSubmodules": true,
"cloneSubmodulesFilter": [
"src/doc/book",
"src/doc/reference"
],
// Require manual approval from the Dependency Dashboard before opening PRs
"dependencyDashboardApproval": true,
// Renovate shouldn't update a PR if it is in the bors merge queue.
Expand All @@ -18,6 +29,22 @@
// No dashboard approval necessary for GitHub Actions updates
"matchManagers": ["github-actions"],
"dependencyDashboardApproval": false
},
{
// Only maintain the Cargo lockfiles managed by update-lockfile.sh.
"matchManagers": ["cargo"],
"matchUpdateTypes": ["lockFileMaintenance"],
"enabled": false
},
{
"matchManagers": ["cargo"],
"matchUpdateTypes": ["lockFileMaintenance"],
"matchFileNames": [
"Cargo.toml",
"library/Cargo.toml",
"src/tools/rustbook/Cargo.toml"
],
"enabled": true
}
],
// Don't manage dependencies inside subtrees. They are updated upstream and
Expand Down
22 changes: 11 additions & 11 deletions Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -848,7 +848,7 @@ version = "3.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "faf9468729b8cbcea668e36183cb69d317348c2e08e994829fb56ebfdfbaac34"
dependencies = [
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -1261,7 +1261,7 @@ dependencies = [
"libc",
"option-ext",
"redox_users",
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -1388,7 +1388,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"
dependencies = [
"libc",
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -2166,7 +2166,7 @@ dependencies = [
"portable-atomic",
"portable-atomic-util",
"serde_core",
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -2653,7 +2653,7 @@ version = "0.50.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5"
dependencies = [
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -5084,7 +5084,7 @@ dependencies = [
"errno",
"libc",
"linux-raw-sys",
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -5516,7 +5516,7 @@ dependencies = [
"getrandom 0.3.3",
"once_cell",
"rustix",
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand All @@ -5535,7 +5535,7 @@ version = "1.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d8c27177b12a6399ffc08b98f76f7c9a1f4fe9fc967c784c5a071fa8d93cf7e1"
dependencies = [
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down Expand Up @@ -5905,9 +5905,9 @@ dependencies = [

[[package]]
name = "tracing-subscriber"
version = "0.3.22"
version = "0.3.23"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2f30143827ddab0d256fd843b7a66d164e9f271cfa0dde49142c5ca0ca291f1e"
checksum = "cb7f578e5945fb242538965c2d0b04418d38ec25c79d160cd279bf0731c8d319"
dependencies = [
"matchers",
"nu-ansi-term",
Expand Down Expand Up @@ -6513,7 +6513,7 @@ version = "0.1.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"
dependencies = [
"windows-sys 0.61.2",
"windows-sys 0.59.0",
]

[[package]]
Expand Down
4 changes: 4 additions & 0 deletions bootstrap.example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,10 @@
# Set this to "discover" to automatically discover LLDB from the environment.
#build.lldb = "lldb"

# The path to (or name of) the Intel SDE executable, used to run the
# intrinsic-test suite for x86 target features the host CPU may not support.
#build.sde = "sde64"

# The node.js executable to use. Note that this is only used for the emscripten
# target when running tests, otherwise this can be omitted.
#build.nodejs = "node"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use crate::attributes::diagnostic::*;
use crate::attributes::prelude::*;
#[derive(Default)]
pub(crate) struct OnConstParser {
span: Option<Span>,
path_span: Option<Span>,
directive: Option<(Span, Directive)>,
}

Expand All @@ -21,8 +21,8 @@ impl AttributeParser for OnConstParser {
return;
}

let span = cx.attr_span;
this.span = Some(span);
let path_span = cx.attr_path.span;
this.path_span = Some(path_span);

let mode = Mode::DiagnosticOnConst;

Expand All @@ -31,7 +31,7 @@ impl AttributeParser for OnConstParser {
let Some(directive) = parse_directive_items(cx, mode, items.mixed(), true) else {
return;
};
merge_directives(cx, &mut this.directive, (span, directive));
merge_directives(cx, &mut this.directive, (path_span, directive));
},
)];

Expand All @@ -44,8 +44,11 @@ impl AttributeParser for OnConstParser {
]);

fn finalize(self, _cx: &FinalizeContext<'_, '_>) -> Option<AttributeKind> {
if let Some(span) = self.span {
Some(AttributeKind::OnConst { span, directive: self.directive.map(|d| Box::new(d.1)) })
if let Some(path_span) = self.path_span {
Some(AttributeKind::OnConst {
span: path_span,
directive: self.directive.map(|d| Box::new(d.1)),
})
} else {
None
}
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_attr_parsing/src/attributes/stability.rs
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ impl AttributeParser for ConstStabilityParser {
{
this.stability = Some((
PartialConstStability { level, feature, promotable: false },
cx.attr_span,
cx.attr_path.span,
));
}
},
Expand All @@ -225,7 +225,7 @@ impl AttributeParser for ConstStabilityParser {
{
this.stability = Some((
PartialConstStability { level, feature, promotable: false },
cx.attr_span,
cx.attr_path.span,
));
}
},
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_attr_parsing/src/diagnostics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -814,7 +814,7 @@ pub(crate) enum InvalidOnClause {
pub(crate) struct DupesNotAllowed;

#[derive(Diagnostic)]
#[diag("usage of the unsafe `#[{$attr_path}]` attribute")]
#[diag("usage of the unsafe `{$attr_path}` attribute")]
#[note("{$note}")]
pub(crate) struct UnsafeAttribute {
pub attr_path: AttrPath,
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_builtin_macros/src/diagnostics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,7 @@ pub(crate) struct TakesNoArguments<'a> {
}

#[derive(Diagnostic)]
#[diag("the `#[{$path}]` attribute is only usable with crates of the `proc-macro` crate type")]
#[diag("the `{$path}` attribute is only usable with crates of the `proc-macro` crate type")]
pub(crate) struct AttributeOnlyUsableWithCrateType<'a> {
#[primary_span]
pub span: Span,
Expand Down
3 changes: 2 additions & 1 deletion compiler/rustc_builtin_macros/src/proc_macro_harness.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,9 +230,10 @@ impl<'a> Visitor<'a> for CollectProcMacros<'a> {
}

if !self.is_proc_macro_crate {
let path = &attr.get_normal_item().path;
self.dcx
.create_err(diagnostics::AttributeOnlyUsableWithCrateType {
span: attr.span,
span: path.span,
path: &pprust::path_to_string(&attr.get_normal_item().path),
})
.emit();
Expand Down
8 changes: 4 additions & 4 deletions compiler/rustc_builtin_macros/src/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,13 @@ pub(crate) fn expand_test(

pub(crate) fn expand_bench(
cx: &mut ExtCtxt<'_>,
attr_sp: Span,
attr_path_sp: Span,
meta_item: &ast::MetaItem,
item: Annotatable,
) -> Vec<Annotatable> {
check_builtin_macro_attribute(cx, meta_item, sym::bench);
warn_on_duplicate_attribute(cx, &item, sym::bench);
expand_test_or_bench(cx, attr_sp, item, true)
expand_test_or_bench(cx, attr_path_sp, item, true)
}

pub(crate) fn expand_test_or_bench(
Expand Down Expand Up @@ -413,7 +413,7 @@ pub(crate) fn expand_test_or_bench(
fn not_testable_error(cx: &ExtCtxt<'_>, is_bench: bool, attr_sp: Span, item: Option<&ast::Item>) {
let dcx = cx.dcx();
let name = if is_bench { "bench" } else { "test" };
let msg = format!("the `#[{name}]` attribute may only be used on a free function");
let msg = format!("the `{name}` attribute may only be used on a free function");
let level = match item.map(|i| &i.kind) {
// These were a warning before #92959 and need to continue being that to avoid breaking
// stable user code (#94508).
Expand All @@ -432,7 +432,7 @@ fn not_testable_error(cx: &ExtCtxt<'_>, is_bench: bool, attr_sp: Span, item: Opt
),
);
}
err.span_label(attr_sp, format!("the `#[{name}]` macro causes a function to be run as a test and has no effect on non-functions"));
err.span_label(attr_sp, format!("the `{name}` attribute causes a function to be run as a test and has no effect on non-functions"));

if !is_bench {
err.with_span_suggestion(attr_sp,
Expand Down
4 changes: 3 additions & 1 deletion compiler/rustc_hir/src/attrs/data_structures.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1219,6 +1219,7 @@ pub enum AttributeKind {

/// Represents `#[diagnostic::on_const]`.
OnConst {
/// The attribute path span.
span: Span,
/// None if the directive was malformed in some way.
directive: Option<Box<Directive>>,
Expand Down Expand Up @@ -1391,7 +1392,8 @@ pub enum AttributeKind {
/// Represents `#[rustc_const_stable]` and `#[rustc_const_unstable]`.
RustcConstStability {
stability: PartialConstStability,
/// Span of the `#[rustc_const_stable(...)]` or `#[rustc_const_unstable(...)]` attribute
/// Path span of the `#[rustc_const_stable(...)]` or `#[rustc_const_unstable(...)]`
/// attribute.
span: Span,
},

Expand Down
5 changes: 2 additions & 3 deletions compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1487,7 +1487,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
// FIXME(156581): actually instantiate the binder correctly (turbofishing/fndef changes)
Ok(ty::Const::zero_sized(
tcx,
Ty::new_fn_def(tcx, ctor_def_id, ty::Binder::dummy(args)),
tcx.type_of(ctor_def_id).instantiate(tcx, args).skip_norm_wip(),
))
}
DefKind::Ctor(ctor_of, CtorKind::Const) => {
Expand Down Expand Up @@ -2913,8 +2913,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
&path.segments[generic_segments[0].1],
);

// FIXME(156581): actually instantiate the binder correctly (turbofishing/fndef changes)
ty::Const::zero_sized(tcx, Ty::new_fn_def(tcx, did, ty::Binder::dummy(args)))
ty::Const::zero_sized(tcx, tcx.type_of(did).instantiate(tcx, args).skip_norm_wip())
}
Res::Def(DefKind::AssocConst { .. }, did) => {
let trait_segment = if let [modules @ .., trait_, _item] = path.segments {
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_hir_typeck/src/method/suggest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3399,7 +3399,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
return;
};

let name = self.ty_to_value_string(actual);
let name = self.ty_to_string(actual);
let inner_id = kind.did();
let mutable = if let Some(AutorefOrPtrAdjustment::Autoref { mutbl, .. }) =
pick.autoref_or_ptr_adjustment
Expand Down Expand Up @@ -3868,7 +3868,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
/// Print out the type for use in value namespace.
fn ty_to_value_string(&self, ty: Ty<'tcx>) -> String {
match ty.kind() {
ty::Adt(def, args) => self.tcx.def_path_str_with_args(def.did(), args),
ty::Adt(def, args) => self.tcx.value_path_str_with_args(def.did(), args),
_ => self.ty_to_string(ty),
}
}
Expand Down
Loading
Loading