diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2024-04-02 21:22:01 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-02 21:22:01 +0200 |
| commit | a38dde928964a5a6b1b36ae7c45f48f8966762cb (patch) | |
| tree | 70ef980095bcdbcb474a1d33dd1076a1a73d5f66 /tests/rustdoc-js-std/parser-slice-array.js | |
| parent | 1b0e46f8a05de7497ea17c8ad0a1c525c1b123f6 (diff) | |
| parent | f2fd2d8c7080f7a7d770b3e3d27e525250c182dc (diff) | |
| download | rust-a38dde928964a5a6b1b36ae7c45f48f8966762cb.tar.gz rust-a38dde928964a5a6b1b36ae7c45f48f8966762cb.zip | |
Rollup merge of #123302 - compiler-errors:sized-bound-first, r=estebank
Make sure to insert `Sized` bound first into clauses list
#120323 made it so that we don't insert an implicit `Sized` bound whenever we see an *explicit* `Sized` bound. However, since the code that inserts implicit sized bounds puts the bound as the *first* in the list, that means that it had the **side-effect** of possibly meaning we check `Sized` *after* checking other trait bounds.
If those trait bounds result in ambiguity or overflow or something, it may change how we winnow candidates. (**edit: SEE** #123303) This is likely the cause for the regression in https://github.com/rust-lang/rust/issues/123279#issuecomment-2028899598, since the impl...
```rust
impl<T: Job + Sized> AsJob for T { // <----- changing this to `Sized + Job` or just `Job` (which turns into `Sized + Job`) will FIX the issue.
}
```
...looks incredibly suspicious.
Fixes [after beta-backport] #123279.
Alternative is to revert #120323. I don't have a strong opinion about this, but think it may be nice to keep the diagnostic changes around.
Diffstat (limited to 'tests/rustdoc-js-std/parser-slice-array.js')
0 files changed, 0 insertions, 0 deletions
