rust/compiler/rustc_const_eval
Yuki Okushi 61bfe3653b
Rollup merge of #89021 - WaffleLapkin:separate_error_for_dyn_trait_in_const_fn, r=estebank
Add a separate error for `dyn Trait` in `const fn`

Previously "trait bounds other than `Sized` on const fn parameters are unstable" error was used for both trait bounds (`<T: Trait>`) and trait objects (`dyn Trait`). This was pretty confusing.

This PR adds a separate error for trait objects: "trait objects in const fn are unstable". The error for trait bounds is otherwise intact.

This is follow up to #88907

r? ``@estebank``

``@rustbot`` label: +A-diagnostics
2021-09-19 17:31:33 +09:00
..
src Rollup merge of #89021 - WaffleLapkin:separate_error_for_dyn_trait_in_const_fn, r=estebank 2021-09-19 17:31:33 +09:00
Cargo.toml Rename rustc_mir to rustc_const_eval. 2021-09-07 20:46:26 +02:00