| Age | Commit message (Collapse) | Author | Lines |
|
Update cargo
12 commits in 0c14026aa84ee2ec4c67460c0a18abc8519ca6b2..dead4b8740c4b6a8ed5211e37c99cf81d01c3b1c
2023-06-14 18:43:05 +0000 to 2023-06-20 20:07:17 +0000
- Convert valid feature name warning to an error. (rust-lang/cargo#12291)
- fix(embedded): Don't pollute script dir with lockfile (rust-lang/cargo#12284)
- fix: remove `-Zjobserver-per-rustc` again (rust-lang/cargo#12285)
- docs: some tweaks around `cargo test` (rust-lang/cargo#12288)
- Enable `doctest-in-workspace` by default (rust-lang/cargo#12221)
- fix(embedded): Don't auto-discover build.rs files (rust-lang/cargo#12283)
- fix(embeded): Don't pollute the scripts dir with `target/` (rust-lang/cargo#12282)
- feat: prepare for the next lockfile bump (rust-lang/cargo#12279)
- fix(embedded): Don't create an intermediate manifest (rust-lang/cargo#12268)
- refactor(embedded): Switch to `syn` for parsing doc comments (rust-lang/cargo#12258)
- fix(embedded): Align package name sanitization with cargo-new (rust-lang/cargo#12255)
- Clarify the default behavior of cargo-install. (rust-lang/cargo#12276)
r? `@ghost`
|
|
|
|
proof tree nits
r? `@BoxyUwU`
|
|
Revert #112758 and add test case
Fixes #112831.
Cannot unwrap `update_resolution` for `resolution.single_imports.remove(&Interned::new_unchecked(import));` because there is a relationship between the `Import` and `&NameBinding` in `NameResolution`. This issue caused by my unfamiliarity with the data structure and I apologize for it.
This PR had been reverted, and test case have been added.
r? `@Nilstrieb`
cc `@petrochenkov`
|
|
|
|
This reverts commit 3b059e0fdbf0257ac4921552781d070e8288233a, reversing
changes made to d70be670474c98e62eefc67674b7bb3c7c4f5053.
|
|
Rollup of 6 pull requests
Successful merges:
- #112464 (Fix windows `Socket::connect_timeout` overflow)
- #112720 (Rustdoc: search: color item type and reduce size to avoid clashing)
- #112762 (Sort the errors from arguments checking so that suggestions are handled properly)
- #112786 (change binders from tuple structs to named fields)
- #112794 (Fix linker failures when #[global_allocator] is used in a dependency)
- #112819 (Disable feature(unboxed_closures, fn_traits) in weird-exprs)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Disable feature(unboxed_closures, fn_traits) in weird-exprs
One shouldn't need a nightly compiler in order to ~~have fun~~ call a function many times.
|
|
Fix linker failures when #[global_allocator] is used in a dependency
Fixes https://github.com/rust-lang/rust/issues/112715
|
|
change binders from tuple structs to named fields
|
|
r=compiler-errors
Sort the errors from arguments checking so that suggestions are handled properly
Fixes #112507
The algorithm of `find_issue` does not make sure the index comes out in order, which will make suggesting `remove` or `add` arguments broken in some cases.
Modifying the algorithm to obey order involves much more trivial change, so it's better to order the `errors` after iterations.
|
|
poliorcetics:rustdoc-item-type-color-same-as-item-color, r=notriddle,GuillaumeGomez
Rustdoc: search: color item type and reduce size to avoid clashing
- rustdoc: search: color item type same as item
- rustdoc: search: reduce item type size to 0.875rem to avoid clashing with path and item
|
|
r=ChrisDenton
Fix windows `Socket::connect_timeout` overflow
This PR want to close #112405
- [x] add unit test
|
|
|
|
|
|
Co-authored-by: Chris Denton <christophersdenton@gmail.com>
|
|
|
|
|
|
Add `implement_via_object` to `rustc_deny_explicit_impl` to control object candidate assembly
Some built-in traits are special, since they are used to prove facts about the program that are important for later phases of compilation such as codegen and CTFE. For example, the `Unsize` trait is used to assert to the compiler that we are able to unsize a type into another type. It doesn't have any methods because it doesn't actually *instruct* the compiler how to do this unsizing, but this is later used (alongside an exhaustive match of combinations of unsizeable types) during codegen to generate unsize coercion code.
Due to this, these built-in traits are incompatible with the type erasure provided by object types. For example, the existence of `dyn Unsize<T>` does not mean that the compiler is able to unsize `Box<dyn Unsize<T>>` into `Box<T>`, since `Unsize` is a *witness* to the fact that a type can be unsized, and it doesn't actually encode that unsizing operation in its vtable as mentioned above.
The old trait solver gets around this fact by having complex control flow that never considers object bounds for certain built-in traits:
https://github.com/rust-lang/rust/blob/2f896da247e0ee8f0bef7cd7c54cfbea255b9f68/compiler/rustc_trait_selection/src/traits/select/candidate_assembly.rs#L61-L132
However, candidate assembly in the new solver is much more lovely, and I'd hate to add this list of opt-out cases into the new solver. Instead of maintaining this complex and hard-coded control flow, instead we can make this a property of the trait via a built-in attribute. We already have such a build attribute that's applied to every single trait that we care about: `rustc_deny_explicit_impl`. This PR adds `implement_via_object` as a meta-item to that attribute that allows us to opt a trait out of object-bound candidate assembly as well.
r? `@lcnr`
|
|
|
|
update rustfmt
changes described in https://github.com/rust-lang/rustfmt/blob/master/CHANGELOG.md#153-2023-06-20
r? `@ghost`
cc `@rust-lang/rustfmt`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
One shouldn't need a nightly compiler in order to ~~have fun~~ call a
function many times.
|
|
Rollup of 8 pull requests
Successful merges:
- #112232 (Better error for non const `PartialEq` call generated by `match`)
- #112499 (Fix python linting errors)
- #112596 (Suggest correct signature on missing fn returning RPITIT/AFIT)
- #112606 (Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses)
- #112781 (Don't consider TAIT normalizable to hidden ty if it would result in impossible item bounds)
- #112787 (Add gha problem matcher)
- #112799 (Clean up "doc(hidden)" check)
- #112803 (Format the examples directory of cg_clif)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
sync subtree in prep for next release
|
|
|
|
|
|
Fixes issue #5416
|
|
Format the examples directory of cg_clif
Formatting has been enforced in cg_clif's CI for a while now.
|
|
Clean up "doc(hidden)" check
It makes the code reading a bit better but putting away the logic inside a common method.
r? `@notriddle`
|
|
Add gha problem matcher
These regexes capture rustfmt errors, panics and regular Rust errors in CI and automatically add messages in the diff view. This should make it simpler to quickly see what went wrong without having to scroll through CI logs.
We can fine tune the regexes or add more matchers after having a look at how it actually works in practice
The relevant documentation can be found at https://github.com/actions/toolkit/blob/main/docs/problem-matchers.md
r? `@jyn514`
|
|
r=lcnr
Don't consider TAIT normalizable to hidden ty if it would result in impossible item bounds
See test for example where we shouldn't consider it possible to alias-relate a TAIT and hidden type.
r? `@lcnr`
|
|
Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses
ACP: rust-lang/libs-team#239
|
|
Suggest correct signature on missing fn returning RPITIT/AFIT
Add `async` and unpeel the future's output type if the function is async
Fixes #108195
|
|
Fix python linting errors
These were flagged by `ruff`, run using the config in https://github.com/rust-lang/rust/pull/112482
|
|
Better error for non const `PartialEq` call generated by `match`
Resolves #90237
|
|
Add `alloc::rc::UniqueRc`
This PR implements `UniqueRc` as described in https://github.com/rust-lang/libs-team/issues/90.
I've tried to stick to the API proposed there, incorporating the feedback from the ACP review. For now I've just implemented `UniqueRc`, but we'll want `UniqueArc` as well. I wanted to get feedback on this implementation first since the `UniqueArc` version should be mostly a copy/paste/rename job.
|
|
Rollup of 7 pull requests
Successful merges:
- #109970 ([doc] `poll_fn`: explain how to `pin` captured state safely)
- #112705 (Simplify `Span::source_callee` impl)
- #112757 (Use BorrowFlag instead of explicit isize)
- #112768 (Rewrite various resolve/diagnostics errors as translatable diagnostics)
- #112777 (Continue folding in query normalizer on weak aliases)
- #112780 (Treat TAIT equation as always ambiguous in coherence)
- #112783 (Don't ICE on bound var in `reject_fn_ptr_impls`)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
This is an `Rc` that is guaranteed to only have one strong reference.
Because it is uniquely owned, it can safely implement `DerefMut`, which
allows programs to have an initialization phase where structures inside
the `Rc` can be mutated.
The `UniqueRc` can then be converted to a regular `Rc`, allowing sharing
and but read-only access.
During the "initialization phase," weak references can be created, but
attempting to upgrade these will fail until the `UniqueRc` has been
converted to a regular `Rc`. This feature can be useful to create
cyclic data structures.
This API is an implementation based on the feedback provided to the ACP
at https://github.com/rust-lang/libs-team/issues/90.
|
|
|
|
Don't ICE on bound var in `reject_fn_ptr_impls`
We may try to use an impl like `impl<T: FnPtr> PartialEq {}` to satisfy a predicate like `for<T> T: PartialEq` -- don't ICE in that case.
Fixes #112735
|
|
Treat TAIT equation as always ambiguous in coherence
Not sure why we weren't treating all TAIT equality as ambiguous -- this behavior combined with `DefineOpaqueTypes::No` leads to coherence overlap failures, since we incorrectly consider impls as not overlapping because the obligation `T: From<Foo>` doesn't hold.
Fixes #112765
|
|
Continue folding in query normalizer on weak aliases
Fixes #112752
Fixes #112731 (same root cause, so didn't make a test for it)
fixes #112776
r? ```@oli-obk```
|
|
Rewrite various resolve/diagnostics errors as translatable diagnostics
additional question:
For trivial strings is it ever accepted to use `fluent_generated::foo` in a `label` for example? Or is an empty struct `Diagnostic` preferred?
|