| Age | Commit message (Collapse) | Author | Lines |
|
Blocking Rayon queries
r? @michaelwoerister
|
|
Add Future and task system to the standard library
This adds preliminary versions of the `std::future` and `std::task` modules in order to unblock development of async/await (https://github.com/rust-lang/rust/issues/50547). These shouldn't be considered as final forms of these libraries-- design questions about the libraries should be left on https://github.com/rust-lang/rfcs/pull/2418. Once that RFC (or a successor) is merged, these APIs will be adjusted as necessary.
r? @aturon
|
|
|
|
Accept `..` in incorrect position to avoid further errors
We currently give a specific message when encountering a `..` anywhere
other than the end of a pattern. Modify the parser to accept it (while
still emitting the error) so that we don't also trigger "missing fields
in pattern" errors afterwards.
Add suggestions to either remove trailing `,` or moving the `..` to the
end.
Follow up to #49268.
|
|
|
|
Refactor the const eval diagnostic API
* no longer report "const eval error" for things that have typeck errors
* errors and lints have saner spans and messages
* unified the diagnostic logic (const eval errors were slightly different depending on where they were reported, and there was also code duplication between the different reporters)
* report errors if an erroneous constant is used inside a promoted (fixes most of #50814)
|
|
Add AdHocCalls and pass self to build_controller as Box<Self>
This makes it easier to write custom drivers.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
When using `..` somewhere other than the end, parse the rest of the
pattern correctly while still emitting an error.
Add suggestions to either remove trailing `,` or moving the `..` to the
end.
|
|
We currently give a specific message when encountering a `..` anywhere
other than the end of a pattern. Modify the parser to accept it (while
still emitting the error) so that we don't also trigger "missing fields
in pattern" errors afterwards.
|
|
Tests that #39963 is fixed on MIR borrowck
As title.
fixes #39963
|
|
test: Ignore some problematic tests on sparc and sparc64
This updates the list of tests which can be safely ignored on sparc and sparc64.
|
|
Check array indices in constant propagation
Previously, uses of constant weren't correctly propagated.
This fixes #48920.
r? @oli-obk because you suggested it
|
|
r=QuietMisdreavus
Fix crate-name option in rustdoc
Fixes #51229.
r? @QuietMisdreavus
|
|
rustdoc: introduce the #[doc(keyword="")] attribute for documenting keywords
Part of #34601.
r? @QuietMisdreavus
|
|
|
|
|
|
|
|
Suggest not mutably borrowing a mutable reference
This PR would (hopefully) solve #45392. I deviated a bit from @estebank's instructions since the error span only included the borrowed expression (e.g. the `b` in `&mut b`). I also didn't check the mutability of the local binding, since this whole case is concerned with an immutable local.
I can see two outstanding questions:
1. `note_immutability_blame` is called in two places, but I only have one test case. I think it covers the call in `report_bckerror`, but I'm not sure how to trigger the call from `report_aliasability_violation`.
2. There is one failing test, where the local binding is `self: &mut Self`. I'm not entirely sure what the correct output should be, but I think the new message should also apply. Unfortunately, since this parameter is parsed differently, its `let_span` covers both the pattern and the type, leading to a wrong suggestion text. I'm not sure how to correctly identify this case.
|
|
|
|
ScalarPairs are offset==0 field + other non-zst field
r? @eddyb
fixes #51300
|
|
|
|
|
|
Do not promote union field accesses
r? @eddyb
technically a breaking change, but the code errored on the previous stable and produces UB + a warning on the current stable. I don't think we need a crater run in that case.
|
|
|
|
|
|
|
|
|
|
Rollup of 6 pull requests
Successful merges:
- #51288 (Remove rustdoc-specific is_import field from HIR)
- #51299 (const fn integer operations)
- #51317 (Allow enabling incremental via config.toml)
- #51323 (Generate br for all two target SwitchInts)
- #51326 (Various minor slice iterator cleanups)
- #51329 (Remove the unused `-Z trans-time-graph` flag.)
Failed merges:
|
|
const fn integer operations
A follow up to #51171
Fixes #51267
Makes a lot of the integer methods (`swap_bytes`, `count_ones` etc) `const fn`s. See #51267 for a discussion about why this is wanted and the solution used.
|
|
r=GuillaumeGomez
Point to the rustdoc attribute where intralink resolution failed.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Rollup of 6 pull requests
Successful merges:
- #51143 (Specify that packed types must derive, not implement, Copy)
- #51226 (Make Layout's align a NonZeroUsize)
- #51297 (Fix run button style)
- #51306 (impl Default for &mut str)
- #51312 (Clarify the difference between get_mut and into_mut for OccupiedEntry)
- #51313 (use type name in E0599 enum variant suggestion)
Failed merges:
|
|
use type name in E0599 enum variant suggestion
Also, rename the variable from "type_str" to "item_kind" to avoid
the ambiguity that caused this bug.
|
|
Specify that packed types must derive, not implement, Copy
|
|
|