diff options
| author | Jubilee <46493976+workingjubilee@users.noreply.github.com> | 2024-06-12 03:57:26 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-06-12 03:57:26 -0700 |
| commit | 0a5284917b26496f608bff8737f32fa1b502b3d5 (patch) | |
| tree | 6e8f2b82f04dbb135a90778f6c2000b4e27e2923 /compiler/rustc_hir_analysis/src/errors.rs | |
| parent | 6f4f405c396159a33bf98f2e7ccf638d49542e9d (diff) | |
| parent | bbc55091bb05c11d6770de3e396d81b6221de8d0 (diff) | |
| download | rust-0a5284917b26496f608bff8737f32fa1b502b3d5.tar.gz rust-0a5284917b26496f608bff8737f32fa1b502b3d5.zip | |
Rollup merge of #126314 - lcnr:fix-relnotes, r=pietroalbini
fix RELEASES: we do not support upcasting to auto traits
#119338 does not actually support casts from `dyn Trait` to `dyn Auto`, only from `dyn Trait` to `dyn Trait + Auto`. The following test does not compile
```rust
trait Trait: Send {}
impl<T: Send> Trait for T {}
fn foo() {
let x: &i32 = &1;
let y = x as &dyn Trait as &dyn Send;
}
```
it actually also doesn't compile with `feature(trait_upcasting)`, opened #126313 for that
r? `@Mark-Simulacrum` `@cuviper`
Diffstat (limited to 'compiler/rustc_hir_analysis/src/errors.rs')
0 files changed, 0 insertions, 0 deletions
