| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
Rollup of 6 pull requests
Successful merges:
- #133663 (Add a compiler intrinsic to back `bigint_helper_methods`)
- #134798 (Make `ty::Error` implement all auto traits)
- #134808 (compiletest: Remove empty 'expected' files when blessing)
- #134809 (Add `--no-capture`/`--nocapture` as bootstrap arguments)
- #134826 (Add spastorino to users_on_vacation)
- #134828 (Add clubby789 back to bootstrap review rotation)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Add clubby789 back to bootstrap review rotation
|
|
Add spastorino to users_on_vacation
|
|
Add `--no-capture`/`--nocapture` as bootstrap arguments
I often try `x test ... --nocapture` => 'unknown argument' => `x test ... -- --nocapture`. As we forward several other compiletest flags, let's recognise this one in bootstrap as well.
|
|
compiletest: Remove empty 'expected' files when blessing
Fixes #134793
Fixes #134196
This also refactors `compare_output` to return an enum; returning a usize was done for convenience but is misleading
|
|
Make `ty::Error` implement all auto traits
I have no idea what's up with the crashes test I fixed--I really don't want to look into it since it has to do something with borrowck and multiple layers of opaques. I think the underlying idea of allowing error types to implement all auto traits is justified though.
Fixes #134796
Fixes #131050
r? lcnr
|
|
Add a compiler intrinsic to back `bigint_helper_methods`
cc https://github.com/rust-lang/rust/issues/85532
This adds a new `carrying_mul_add` intrinsic, to implement `wide_mul` and `carrying_mul`.
It has fallback MIR for all types -- including `u128`, which isn't currently supported on nightly -- so that it'll continue to work on all backends, including CTFE.
Then it's overridden in `cg_llvm` to use wider intermediate types, including `i256` for `u128::carrying_mul`.
|
|
|
|
|
|
Strip debuginfo from rustc-main and rustdoc
r? `@Kobzol`
Split from #134690
|
|
|
|
Including implementing it for `u128`, so it can be defined in `uint_impl!`.
This way it works for all backends, including CTFE.
|
|
Rollup of 8 pull requests
Successful merges:
- #134606 (ptr::copy: fix docs for the overlapping case)
- #134622 (Windows: Use WriteFile to write to a UTF-8 console)
- #134759 (compiletest: Remove the `-test` suffix from normalize directives)
- #134787 (Spruce up the docs of several queries related to the type/trait system and const eval)
- #134806 (rustdoc: use shorter paths as preferred canonical paths)
- #134815 (Sort triples by name in platform_support.md)
- #134816 (tools: fix build failure caused by PR #134420)
- #134819 (Fix mistake in windows file open)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Fix mistake in windows file open
In #134722 this should have been `c::FileAllocationInfo` not `c::FileEndOfFileInfo`. Oops.
|
|
tools: fix build failure caused by PR #134420
Someone reports build failure after merging pull request #134420: https://github.com/rust-lang/rust/pull/134420#discussion_r1898081258
This pull request fixes the build failure.
|
|
Sort triples by name in platform_support.md
When looking for riscv32emc support, I missed it at first because it was at the end of the tier3 target list [here](https://doc.rust-lang.org/rustc/platform-support.html#tier-3). These lists are *mostly* dictionary sorted so I assumed it should be near the riscv32i* targets.
This PR puts all targets back in dictionary order. There were only a few outside of tier3.
I ended up writing a small program to sort them because I did not trust myself to do it manually, but I stopped short of fully automating it.
I have manually reviewed the output to confirm it still has the same number of entries, and that the changed values do follow the ordering I would expect.
For folks who would prefer to review code than manual textual changes, the sorting program (including inputs) is [here.](https://github.com/9names/platform_sort_arch/blob/main/src/main.rs)
|
|
r=GuillaumeGomez
rustdoc: use shorter paths as preferred canonical paths
This is a solution to [the `std::sync::poison` linking problem](https://github.com/rust-lang/rust/pull/134692#issuecomment-2560373308), and, in general, makes intra-doc links shorter and clearer.
> Done. This helped with the search, but not with the things like `MutexGuard`'s doc's reference to `Mutex::lock` being converted to the absolute (unstable) `std::sync::poison::Mutex` path.
cc `@tgross35`
r? `@GuillaumeGomez`
|
|
Spruce up the docs of several queries related to the type/trait system and const eval
- Editorial
- Proper rustdoc summary/synopsis line by making use of extra paragraphs: Leads to better rendered output on module pages, in search result lists and overall, too
- Use rustdoc warning blocks for admonitions of the form "do not call / avoid calling this query directly"
- Use intra-doc links of the form ``[`Self::$query`]`` to cross-link queries. Indeed, such links are generally a bit brittle due to the existence of `TyCtxtFeed` which only contains a subset of queries. Therefore the docs of `feedable` queries cannot cross-link to non-`feedable` ones. I'd say it's fine to use intra-doc links despite the potential/unlikely occasional future breakage (if a query with the aforementioned characteristics becomes `feedable`). `Self::` is nicer than `TyCtxt::` (which would be more stable) since it accounts for other contexts like `TyCtxt{Feed,At,Ensure{,WithValue}}`
- Informative
- Generally add, flesh out and correct some doc comments
- Add *Panic* sections (to a few selected queries only). The lists of panics aren't necessarily exhaustive and focus on the more "obvious" or "important" panics.
- Where applicable add a paragraph calling attention to the relevant [`#[rustc_*]` TEST attribute](https://rustc-dev-guide.rust-lang.org/compiler-debugging.html#rustc_-test-attributes)
The one non-doc change (it's internal and not observable):
Be even more defensive in `query constness`'s impl (spiritual follow-up to #134122) (see self review comment).
Fixes #133494.
r\? **any**(compiler-errors, oli-obk)
|
|
compiletest: Remove the `-test` suffix from normalize directives
This suffix was an artifact of using the same condition-checking engine as the `ignore-*` and `only-*` directives, but in practice we have only 2 tests that legitimately use a condition, and both of them only care about 32-bit vs 64-bit.
This PR detaches `normalize-*` directives from the condition checker, and replaces it with a much simpler system of four explicit `NormalizeKind` values. It then takes advantage of that simplicity to get rid of the `-test` suffix.
---
Addresses one of the points of #126372.
The new name-checking code is a bit quaint, but I think it's a definite improvement over the status quo.
---
The corresponding dev-guide update is https://github.com/rust-lang/rustc-dev-guide/pull/2172.
r? jieyouxu
|
|
Windows: Use WriteFile to write to a UTF-8 console
If the console code page is UTF-8 then we can simply write to it without needing to convert to UTF-16 and calling `WriteConsole`.
|
|
ptr::copy: fix docs for the overlapping case
Fixes https://github.com/rust-lang/unsafe-code-guidelines/issues/549
As discussed in that issue, it doesn't make any sense for `copy` to read a byte via `src` after it was already written via `dst`. The entire point of this method is that is copies correctly even if they overlap, and that requires always reading any given location before writing it.
Cc `@rust-lang/opsem`
|
|
|
|
|
|
|
|
|
|
const eval
|
|
Fix renaming symlinks on Windows
Previously we only detected mount points and not other types of links when determining reparse point behaviour.
Also added some tests to avoid this regressing again in the future.
|
|
Previously we only detected mount points and not other types of links when determining reparse point behaviour.
|
|
|
|
|
|
This is a little more verbose, but also more explicit, and avoids invoking the
full condition engine when only the pointer-width conditions are used.
|
|
|
|
|
|
Rollup of 8 pull requests
Successful merges:
- #131522 ([macro_metavar_expr_concat] Fix #128346)
- #134379 (Add `into_array` conversion destructors for `Box`, `Rc`, and `Arc`.)
- #134644 (Document collection `From` and `FromIterator` impls that drop duplicate keys.)
- #134649 (Fix forgetting to save statx availability on success)
- #134728 (Use scoped threads in `std::sync::Barrier` examples)
- #134782 (Update Code Example for `Iterator::rposition`)
- #134789 (unwinding: bump version to fix naked_asm on Xous)
- #134791 (docs: inline `std::ffi::c_str` types to `std::ffi`)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
docs: inline `std::ffi::c_str` types to `std::ffi`
Rustdoc has no way to show that an item is stable, but only at a different path. `std::ffi::c_str::NulError` is not stable, but `std::ffi::NulError` is.
To avoid marking these types as unstable when someone just wants to follow a link from `CString`, inline them into their stable paths.
Fixes #134702
r? `@tgross35`
|
|
r=Mark-Simulacrum
unwinding: bump version to fix naked_asm on Xous
With #80608 the `unwinding` crate no longer builds. The upstream crate has been updated to build by manually adding directives to the naked_asm stream.
Bump the dependency in Rust to get this newer version. This fixes the build for Xous, and closes #134403.
|
|
Update Code Example for `Iterator::rposition`
Added an additional assertion to the example to show the behavior of `iter.next_back` after using `iter.rposition`.
|
|
Use scoped threads in `std::sync::Barrier` examples
This removes boilerplate around `Arc`s and makes the code more clear.
|
|
Fix forgetting to save statx availability on success
Looks like we forgot to save the statx state on success which means the first failure (common when checking if a file exists) will always require spending an invalid statx to confirm the failure is real.
r? `@thomcc`
|
|
Document collection `From` and `FromIterator` impls that drop duplicate keys.
This behavior is worth documenting because there are other plausible alternatives, such as panicking when a duplicate is encountered, and it reminds the programmer to consider whether they should, for example, coalesce duplicate keys first.
Followup to #89869.
|
|
Add `into_array` conversion destructors for `Box`, `Rc`, and `Arc`.
Tracking issue: #133508
This PR adds the `into_array` destructor for `alloc::boxed::Box<[T]>`, `alloc::rc::Rc<[T]>`, and `alloc::sync::Arc<[T]>`.
Note that this PR assumes the initial proposal of these functions returning `Option`. It is still an open question whether this should instead be `Result`. We can, however, easily change this in a follow-up PR with the necessary consensus.
|
|
[macro_metavar_expr_concat] Fix #128346
Fix #128346
Fix #131393
The syntax is invalid in both issues so I guess that theoretically the compiler should have aborted early.
This PR tries to fix a local problem but let me know if there are better options.
cc `@petrochenkov` if you are interested
|
|
|
|
|
|
|
|
This is a solution to the `std::sync::poison` linking problem,
and, in general, makes intra-doc links shorter and clearer.
|
|
|
|
Rollup of 4 pull requests
Successful merges:
- #134656 (Migrate `incr-add-rust-src-component` to rmake)
- #134664 (Account for removal of multiline span in suggestion)
- #134772 (Improve/cleanup rustdoc code)
- #134781 (Add more `begin_panic` normalizations to panic backtrace tests)
r? `@ghost`
`@rustbot` modify labels: rollup
|