diff options
| author | Dylan MacKenzie <ecstaticmorse@gmail.com> | 2020-10-05 21:45:55 -0700 |
|---|---|---|
| committer | Dylan MacKenzie <ecstaticmorse@gmail.com> | 2020-10-06 11:22:24 -0700 |
| commit | b5693a39d9d7d1b5404c188899bf7d983c79dfe3 (patch) | |
| tree | d9148a09566065da00d22483cd4e6023b77bc50e /compiler/rustc_error_codes | |
| parent | 9beb6f81e4112eccf9965d46421a1da351b0593a (diff) | |
| download | rust-b5693a39d9d7d1b5404c188899bf7d983c79dfe3.tar.gz rust-b5693a39d9d7d1b5404c188899bf7d983c79dfe3.zip | |
Update error code page
Diffstat (limited to 'compiler/rustc_error_codes')
| -rw-r--r-- | compiler/rustc_error_codes/src/error_codes/E0723.md | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/compiler/rustc_error_codes/src/error_codes/E0723.md b/compiler/rustc_error_codes/src/error_codes/E0723.md index 95d47ab21cb..bc224421915 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0723.md +++ b/compiler/rustc_error_codes/src/error_codes/E0723.md @@ -3,12 +3,8 @@ An unstable feature in `const` contexts was used. Erroneous code example: ```compile_fail,E0723 -trait T {} - -impl T for () {} - -const fn foo() -> impl T { // error: `impl Trait` in const fn is unstable - () +const fn foo<T: Copy>(_: T) { // error! + // ... } ``` @@ -18,11 +14,7 @@ feature flag: ``` #![feature(const_fn)] -trait T {} - -impl T for () {} - -const fn foo() -> impl T { - () +const fn foo<T: Copy>(_: T) { // ok! + // ... } ``` |
