| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
Update cargo
8 commits in e51522ab3db23b0d8f1de54eb1f0113924896331..070e459c2d8b79c5b2ac5218064e7603329c92ae
2021-05-07 21:29:52 +0000 to 2021-05-11 18:12:23 +0000
- Fix rustdoc warnings (rust-lang/cargo#9468)
- Improve performance of git status check in `cargo package`. (rust-lang/cargo#9478)
- Link to the new rustc tests chapter. (rust-lang/cargo#9477)
- Bump index cache version to deal with semver metadata version mismatch. (rust-lang/cargo#9476)
- Fix Url::into_string deprecation warning (rust-lang/cargo#9475)
- Fix rust-lang/cargo#4482 and rust-lang/cargo#9449: set Fossil ignore and clean settings locally (rust-lang/cargo#9469)
- Improve two error messages (rust-lang/cargo#9472)
- Fix `cargo install` with a semver metadata version. (rust-lang/cargo#9467)
|
|
updated deps
filetime v0.2.12 -> v0.2.14
https://github.com/alexcrichton/filetime/compare/0.2.12...0.2.14
socket2 v0.3.16 -> v0.3.19
https://github.com/rust-lang/socket2/commits/v0.3.x
tar v0.4.29 -> v0.4.33
https://github.com/alexcrichton/tar-rs/compare/0.4.29...0.4.33
this drops dependency on redox_syscall 0.1.*
---
measureme v9.1.0 -> v9.1.1
https://github.com/rust-lang/measureme/compare/9.1.0...9.1.1
this drops dependency on memmap v0.7.0
---
version_check v0.9.1 -> v0.9.3
https://github.com/SergioBenitez/version_check/compare/v0.9.1...v0.9.3
fixes version parse
|
|
|
|
r=tmandry
Revert "Auto merge of #84797 - richkadel:cover-unreachable-statements…
This reverts commit e5f83d24aee866a14753a7cedbb4e301dfe5bef5, reversing
changes made to ac888e8675182c703c2cd097957878faf88dad94.
See https://github.com/rust-lang/rust/pull/84797#issuecomment-839068132
r? `@tmandry`
|
|
r=Mark-Simulacrum
Improve rustdoc gui tester
I cherry-picked the commit from https://github.com/rust-lang/rust/pull/84834 (and modified it a bit). I also used this opportunity to update it to last version (forgot to update GUI test in https://github.com/rust-lang/rust/pull/85074, really can't wait to make https://github.com/rust-lang/rust/pull/84586 finally work).
cc `@Mark-Simulacrum` for the changes in bootstrap.
r? `@jsha`
|
|
Use .name_str() to format primitive types in error messages
This pull request fixes #84976. The problem described there is caused by this code
https://github.com/rust-lang/rust/blob/506e75cbf8cb5305e49a41326307004ca3976029/compiler/rustc_middle/src/ty/error.rs#L161-L166
using `Debug` formatting (`{:?}`), while the proper solution is to call `name_str()` of `ty::IntTy`, `ty::UintTy` and `ty::FloatTy`, respectively.
|
|
rustdoc: remove explicit boolean comparisons.
For boolean variables it's shorter and more readable to check the value directly, or negate it with `!`.
In a couple of cases I reordered an if/else pair because it made the initial `if` statement simpler.
An example of a style guide recommending this: https://airbnb.io/javascript/#comparison--shortcuts
r? `@GuillaumeGomez`
|
|
shrinking the deprecated method span
close https://github.com/rust-lang/rust/issues/84637
|
|
rustdoc: Add unstable CLI option to show basic type layout information
Closes #75988.
Right now it just shows the size.
|
|
|
|
r=tmandry"
This reverts commit e5f83d24aee866a14753a7cedbb4e301dfe5bef5, reversing
changes made to ac888e8675182c703c2cd097957878faf88dad94.
|
|
|
|
|
|
|
|
for more libraries
|
|
For boolean variables it's shorter and more readable to check the value
directly, or negate it with `!`.
In a couple of cases I reordered an if/else pair because it made the
initial `if` statement simpler.
Removed unused isType parameter from two functions.
|
|
There are issues with computing layout for type aliases; see #85103.
Once the issues are fixed, we should re-enable layout docs for them.
|
|
|
|
This should prevent confusion about why generic types don't have layout
docs.
|
|
|
|
|
|
Co-authored-by: Ivan Tham <pickfire@riseup.net>
|
|
|
|
|
|
|
|
|
|
At first you might think "why not just click through to the aliased
type?", but if a type alias instantiates all of the generic parameters
of the aliased type, then it can show layout info even though the
aliased type cannot (because we can't compute the layout of a generic
type). So I think it's still useful to show layout info for type
aliases.
|
|
|
|
|
|
Layout errors can occur with valid code, e.g. generic types.
|
|
Right now it just shows the size.
|
|
Improve diagnostics for GATs
Fixes https://github.com/rust-lang/rust/issues/81801
Fixes https://github.com/rust-lang/rust/issues/81961
Fixes https://github.com/rust-lang/rust/issues/81862
r? `@estebank`
|
|
|
|
array-to-raw-elem cast: test that Retag covers entire array
Make sure that we `Retag` *before* doing the `ArrayToPointer` cast.
|
|
|
|
remove const_fn feature gate
Fixes https://github.com/rust-lang/rust/issues/84510
r? `@oli-obk`
|
|
|
|
Fix invalid suggestion of changing impl trait signature
Fix #68049
|
|
Emit errors/warns on some wrong uses of rustdoc attributes
This PR adds a few diagnostics:
- error if conflicting `#[doc(inline)]`/`#[doc(no_inline)]` are found
- introduce the `invalid_doc_attributes` lint (warn-by-default) which triggers:
- if a crate-level attribute is used on a non-`crate` item
- if `#[doc(inline)]`/`#[doc(no_inline)]` is used on a non-`use` item
The code could probably be improved but I wanted to get feedback first. Also, some of those changes could be considered breaking changes, so I don't know what the procedure would be? ~~And finally, for the warnings, they are currently hard warnings, maybe it would be better to introduce a lint?~~ (EDIT: introduced the `invalid_doc_attributes` lint)
Closes #80275.
r? `@jyn514`
|
|
|
|
Rollup of 7 pull requests
Successful merges:
- #84777 (Apply `--cfg parallel_compiler` when documenting)
- #84783 (Allow formatting specific subdirectories)
- #84998 (Show nicer error when an 'unstable fingerprints' error occurs)
- #85002 (RELEASES.md: Use broken_intra_doc_links as an example, not nightly lint)
- #85051 (Allow checking miri and RLS with `x.py check src/tools/{miri,rls}`)
- #85114 (Remove outdated FIXME for download-rustc)
- #85143 (Document Rc::from)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Allow checking miri and RLS with `x.py check src/tools/{miri,rls}`
Helps with https://github.com/rust-lang/rust/issues/80639.
`@Xanewok` would you find this useful for RLS too?
|
|
Allow formatting specific subdirectories
Fixes https://github.com/rust-lang/rust/issues/71094.
|
|
Apply `--cfg parallel_compiler` when documenting
This also reverts commit 9823c2cc700fea541bf2670fcee93af662b63022 working around the bug.
Fixes https://github.com/rust-lang/rust/issues/82301.
|
|
Fix stack overflow when checking for structural recursion
This pull request aims to fix #74224 and fix #84611. The current logic for detecting ADTs with structural recursion is flawed because it only looks at the root type, and then for exact matches. What I mean by this is that for examples such as:
```rust
struct A<T> {
x: T,
y: A<A<T>>,
}
struct B {
z: A<usize>
}
fn main() {}
```
When checking `A`, the compiler correctly determines that it has an infinite size (because the "root" type is `A`, and `A` occurs, albeit with different type arguments, as a nested type in `A`).
However, when checking `B`, it also recurses into `A`, but now `B` is the root type, and it only checks for _exact_ matches of `A`, but since `A` never precisely contains itself (only `A<A<T>>`, `A<A<A<T>>>`, etc.), an endless recursion ensues until the stack overflows.
In this PR, I have attempted to fix this behavior by implementing a two-phase checking: When checking `B`, my code first checks `A` _separately_ and stops if `A` already turns out to be infinite. If not (such as for `Option<T>`), the second phase checks whether the root type (`B`) is ever nested inside itself, e.g.:
```rust
struct Foo { x: Option<Option<Foo>> }
```
Special care needs to be taken for mutually recursive types, e.g.:
```rust
struct A<T> {
z: T,
x: B<T>,
}
struct B<T> {
y: A<T>
}
```
Here, both `A` and `B` both _are_ `SelfRecursive` and _contain_ a recursive type. The current behavior, which I have maintained, is to treat both `A` and `B` as `SelfRecursive`, and accordingly report errors for both.
|
|
Fix `tidy` platform-specific code check
I noticed new platform-specific code was introduced outside of `std::sys` ([example](https://github.com/rust-lang/rust/blob/master/library/std/src/thread/available_concurrency.rs)), which should have been checked against by `tidy`. Apparently there are 2 problems with the current check implementation:
- It ignores everything after encountering "mod tests", which is often at the very top of a file.
- There was a bug where when checking the byte immediately before a found string, the first byte of the file was checked instead.
I fixed the bug and made excluding tests a bit more robust by instead adding the following rules:
- Files with a path containing either `tests` or `benches` are excluded.
- A `cfg(...)` containing `test` is excluded.
(Tests are excluded because almost all tests have something like `#[cfg(not(target_os = "emscripten"))]` somewhere.)
The fixed check found some more cases of platform-specific code; for now I have explicitly excluded them and added a FIXME stating that the platform-specific code must be moved to `sys`.
|
|
Fix source code line number display and make it clickable again
Fixes https://github.com/rust-lang/rust/issues/85119.
I used the same logic we're using for other codeblocks: putting the line number `<span>`s into the `example-wrap` directly and then add `display: inline-flex` on `example-wrap`.
r? `@jsha`
|