Clarify that ManuallyDrop<T> has same layout as T
This PR implements the documentation change under discussion in https://github.com/rust-lang/unsafe-code-guidelines/issues/302. It should not be approved or merged until the discussion there is resolved.
Fix typo in `String::try_reserve_exact` docs
Copying the pattern from `Vec::try_reserve_exact` and `String::try_reserve`,
it looks like this doc comment is intending to refer to the currently-being-documented
function.
Provide suggestion for missing `>` in a type parameter list
When encountering an inproperly terminated type parameter list, provide
a suggestion to close it after the last non-constraint type parameter
that was successfully parsed.
Fix#94058.
Copying the pattern from `Vec::try_reserve_exact` and `String::try_reserve`,
it looks like this doc comment is intending to refer to the currently-being-documented
function.
Bump the ripgrep commit exercised by cargotest
This update goes from 3de31f7527 (Aug 1, 2019) to current master, ced5b92aa9 (March 21, 2022).
I need this in order to pick up https://github.com/BurntSushi/ripgrep/pull/1722, which picked up https://github.com/BurntSushi/bstr/pull/58, which unblocks https://github.com/rust-lang/rust/pull/95345. Ripgrep uses the Debug representation of a `BStr` in some of its tests. In old versions of bstr, that used to just use the standard library's `escape_debug()` implementation, so the output ends up being sensitive to whether the standard library renders character 0 as `\u{0}` or as `\0`. The newer bstr always renders character 0 as `\0` and ripgrep's test suite has been correspondingly updated.
Rollup of 5 pull requests
Successful merges:
- #91981 (Recover suggestions and useful information lost in previous PR)
- #93469 (Skip pointing out ambiguous impls in alloc/std crates too in inference errors)
- #95335 (Move resolve_path to rustc_builtin_macros and make it private)
- #95340 (interpret: with enforce_number_validity, ensure integers are truly Scalar::Int (i.e., no pointers))
- #95341 (ARMv6K Horizon OS has_thread_local support)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
ARMv6K Horizon OS has_thread_local support
cc. ```@ian-h-chamberlain```
cc. ```@AzureMarker```
Being an ARM target, it has always had built-in support for `#[thread_local]`. This PR comes in just now because we were testing `std::thread` support with `thread_local_dtor`s. This will hopefully be the last PR for the target specification, unless anymore features will be needed as time goes on.
interpret: with enforce_number_validity, ensure integers are truly Scalar::Int (i.e., no pointers)
This is required for https://github.com/rust-lang/miri/pull/2040
r? ```@oli-obk```
Skip pointing out ambiguous impls in alloc/std crates too in inference errors
This generalizes the logic in `annotate_source_of_ambiguity` to skip printing ambiguity errors traits in `alloc` and `std` as well, not just `core`.
While this does spot-fix the issue mentioned below, it would be nicer to generalize this logic, for example to detect when the trait predicate's `self_ty` has any numerical inference variables. Is it worthwhile to scrap this solution for one like that?
Fixes#93450
r? `@estebank`
feel free to reassign
When encountering an inproperly terminated type parameter list, provide
a suggestion to close it after the last non-constraint type parameter
that was successfully parsed.
Fix#94058.