| Age | Commit message (Collapse) | Author | Lines |
|
|
|
Make the allocator shim participate in LTO again
This is likely the cause of the perf regression in https://github.com/rust-lang/rust/pull/145955. It also caused some functional regressions.
Fixes https://github.com/rust-lang/rust/issues/146235
Fixes https://github.com/rust-lang/rust/issues/146239
|
|
definitively excluded
|
|
|
|
s390x: use the new `u128::funnel_shl`
|
|
|
|
Co-Authored-By: Rémy Rakic <remy.rakic+github@gmail.com>
|
|
|
|
|
|
Rollup of 5 pull requests
Successful merges:
- rust-lang/rust#127316 (move pinned version from tracing_core to tracing)
- rust-lang/rust#144801 (Suggest bounds in more cases, accounting for type parameters referenced in predicate)
- rust-lang/rust#146211 (Disallow shebang in `--cfg` and `--check-cfg` arguments)
- rust-lang/rust#146263 (Fix `bump-stage0` build failure, and check-build `bump-stage0` in CI)
- rust-lang/rust#146266 (miri std tests: skip all of sys::)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
miri std tests: skip all of sys::
Matches https://github.com/rust-lang/miri-test-libstd/pull/104
|
|
Fix `bump-stage0` build failure, and check-build `bump-stage0` in CI
This PR bumps the `toml` dependency of the `bump-stage0` tool to `0.8.23`, which AFAICT is the highest `toml` version that's present in the r-l/r workspace's `Cargo.lock` already (so we don't introduce _another_ `toml 0.x.*` series). I added some byte-buffer-to-string intermediary to workaround `toml 0.8.*` not having the `toml 0.9.*` `toml::from_slice` API.
To catch obvious build failures of the `src/tools/bump-stage0` tool early, before we find out it can't even build when we really need it to work.
Contexts:
- https://github.com/rust-lang/rust/pull/146250#issue-3388327410
- [#t-release > Bump stage0 rustfmt separately ("one-off") @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/241545-t-release/topic/Bump.20stage0.20rustfmt.20separately.20.28.22one-off.22.29/near/537916615)
Fixes rust-lang/rust#146252.
|
|
Disallow shebang in `--cfg` and `--check-cfg` arguments
This PR is similar to https://github.com/rust-lang/rust/issues/146130, where we disallowed frontmatter in `--cfg` and `--check-cfg` arguments. While fixing the other one we also discovered that shebang `#!/usr/bin/shebang` are currently also allowed in `--cfg` and `--check-cfg` arguments.
Allowing shebang in them (which are just ignored) was never intended, this PR fixes that by not stripping shebang for `--cfg` and `--check-cfg` arguments.
This is technically a breaking-change, although I don't expect anyone to actually rely on this unintended behavior.
Fixes https://github.com/rust-lang/rust/issues/146130#issuecomment-3246299499
r? fmease
|
|
Suggest bounds in more cases, accounting for type parameters referenced in predicate
Use a `ty::Visitor` to see if the failed predicate references a type parameter. If it does, then we only suggest adding a bound to an (associated) item only if the referenced parameter is present in its generics.
Provide adding bound suggestion in trait and impl associated functions in cases we previously weren't:
```
error[E0277]: `?` couldn't convert the error to `ApplicationError`
--> $DIR/suggest-complex-bound-on-method.rs:18:16
|
LL | t.run()?;
| -----^ the trait `From<<T as Trait>::Error>` is not implemented for `ApplicationError`
| |
| this can't be annotated with `?` because it has type `Result<_, <T as Trait>::Error>`
|
note: `ApplicationError` needs to implement `From<<T as Trait>::Error>`
--> $DIR/suggest-complex-bound-on-method.rs:12:1
|
LL | enum ApplicationError {
| ^^^^^^^^^^^^^^^^^^^^^
= note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait
help: consider introducing a `where` clause, but there might be an alternative better way to express this requirement
|
LL | fn thing<T: Trait>(&self, t: T) -> Result<(), ApplicationError> where ApplicationError: From<<T as Trait>::Error> {
| +++++++++++++++++++++++++++++++++++++++++++++++++
```
Fix rust-lang/rust#144734.
|
|
move pinned version from tracing_core to tracing
This PR removes pin from `tracing-core` and moves it to `tracing`, which regressed perf in > 0.1.37 versions.
|
|
Best viewed with `git diff --color-moved`
|
|
Will hopefully make the next commit's diff somewhat easier to understand
|
|
It's now redundant to `same_lifetimes`: if `ty` and `impl_ty` are the
same type, and they both have no lifetimes, `same_lifetimes` will return
`true` already
|
|
This unfortunately breaks another test case -- it had only worked
because when we checked `!has_lifetime` on `S2<S<'a>>`, we only looked
for generic lifetime params on `S2`, forgetting to descend into `S`.
One thing that makes this a bit less sad is that this particular test
case doesn't come from a reported issue, but rather was added as a
miscellaneous check during a kind of unrelated PR.
|
|
Notably, rename `same_type_and_consts` to `same_type_modulo_regions` to
be more explicit about the function ignoring lifetimes
|
|
|
|
|
|
|
|
To catch obvious build failures of the `src/tools/bump-stage0` early,
before we find out it can't even build when we really need it to work.
|
|
|
|
- We pick the higest common `toml` version used in the r-l/r workspace
to avoid introducing Yet Another `toml` `0.x` version, which happens
to be `0.8.23` as of the time of writing.
- We introduce a byte-buffer-to-string workaround for the `toml 0.8.*`
series that do not have the `toml 0.9.*` series's `toml::from_slice`
API yet. Not efficient, but this is not perf-critical so it's fine.
|
|
Optimize Cargo with LTO
This optimization was "lost" when Cargo was switched away from a `ToolRustcPrivate` to a `ToolTarget` tool.
r? `@jieyouxu`
|
|
Example
---
```rust
fn foo() {
let _ = 2 el$0
}
```
->
```rust
fn foo() {
let _ = 2 else {
$0
};
}
```
|
|
|
|
reduce overlong physical lines (sembr)
|
|
|
|
clean up some old const trait impl syntax
Related to: https://github.com/rust-lang/rust/issues/143874
|
|
Zulip streams were renamed over a year ago
|
|
|
|
https://blog.zulip.com/2024/07/25/zulip-9-0-released
|
|
|
|
|
|
|
|
Rollup of 2 pull requests
Successful merges:
- rust-lang/rust#146199 (Document Cargo with in-tree rustdoc)
- rust-lang/rust#146257 (std: Update `wasi` crate dependency)
Failed merges:
- rust-lang/rust#146200 (Simplify rustdoc-gui tester by calling directly browser-ui-test)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
std: Update `wasi` crate dependency
The recent work on the WASIp2 target being integrated into the standard library (rust-lang/rust#146207, rust-lang/rust#145944) ended up causing a bug in nightly on the target. This [has now been fixed](https://github.com/bytecodealliance/wasi-rs/pull/115) in the `wasi` crate so this commit pulls in the updated version to ensure bindings work correctly.
|
|
Document Cargo with in-tree rustdoc
Fixes https://rust-lang.zulipchat.com/#narrow/channel/266220-t-rustdoc/topic/nightly.20rust.20doc.20seem.20corrupted.
r? `@jieyouxu`
try-job: dist-x86_64-linux-alt
|
|
The recent work on the WASIp2 target being integrated into the standard
library ended up causing a bug in nightly on the target. This has now
been fixed in the `wasi` crate so this commit pulls in the updated
version to ensure bindings work correctly.
|
|
|
|
Rollup of 11 pull requests
Successful merges:
- rust-lang/rust#138944 (Add `__isPlatformVersionAtLeast` and `__isOSVersionAtLeast` symbols)
- rust-lang/rust#139113 (unstable book: in a sanitizer example, check the code)
- rust-lang/rust#145735 (style-guide: Document absence of trailing whitespace)
- rust-lang/rust#146041 (tidy: --bless now makes escheck run with --fix)
- rust-lang/rust#146144 (compiler: Apply target features to the entry function)
- rust-lang/rust#146225 (Simplify `{f16, f32, f64, f128}::midpoint()`)
- rust-lang/rust#146234 (change file-is-generated doc comment to inner)
- rust-lang/rust#146241 (rustc_infer: change top-level doc comment to inner)
- rust-lang/rust#146242 (Ensure that `--html-after-content` option is used to check `scrape_examples_ice` rustdoc GUI test)
- rust-lang/rust#146243 (remove couple of redundant clones)
- rust-lang/rust#146250 (Bump stage0 rustfmt)
Failed merges:
- rust-lang/rust#146200 (Simplify rustdoc-gui tester by calling directly browser-ui-test)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Bump stage0 rustfmt
Unblocks rust-lang/rust#146071, cc `@npmccallum.`
Steps to reproduce:
1. Temporarily upgrade `src/tools/bump-stage0`'s `toml` dependency from 0.7 to 0.9 to fix build error (see Zulip topic)
2. Execute `./x run src/tools/bump-stage0`
3. Manually revert changes unrelated to nightly `rustfmt`+`rustc` (the latter needs to be bumped, too, for the driver ([via](https://github.com/rust-lang/rust/pull/146250#discussion_r2325742775)))
r? `@Mark-Simulacrum` as discussed in [#t-release > Bump stage0 rustfmt separately ("one-off")](https://rust-lang.zulipchat.com/#narrow/channel/241545-t-release/topic/Bump.20stage0.20rustfmt.20separately.20.28.22one-off.22.29/with/537916615)
|
|
remove couple of redundant clones
|
|
Ensure that `--html-after-content` option is used to check `scrape_examples_ice` rustdoc GUI test
Follow-up of https://github.com/rust-lang/rust/pull/146091.
This test ensures that the spans are correctly handled when a "local source file" is not the first in the file list. To ensure it's actually what's tested, this test checks that the option is actually used by adding an element.
r? `@lolbinarycat`
|
|
rustc_infer: change top-level doc comment to inner
|
|
change file-is-generated doc comment to inner
Alternatively this could perhaps be better as a normal comment...
|
|
Simplify `{f16, f32, f64, f128}::midpoint()`
`(float_ty::MAX / 2) - (float_ty::MIN_POSITIVE * 2)` equals `(float_ty::MAX / 2) + (float_ty::MIN_POSITIVE * 2)` equals `(float_ty::MAX / 2)`. So these branches are pointless.
CC `@Urgau` who wrote the original implementation in https://github.com/rust-lang/rust/pull/92048; does this seem right?
`@rustbot` label A-floating-point
|