diff options
| author | Ralf Jung <post@ralfj.de> | 2024-10-26 09:40:03 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2024-10-28 11:48:39 +0100 |
| commit | d066dfdb835f15fe2c4d2bdb31d88cb948b360ad (patch) | |
| tree | ec737bedc6aff10a4cd1ab2d9de28fa4a8280ef8 /compiler/rustc_error_codes | |
| parent | f370f3493d3c85c7032a98e6c22b419251f18d2a (diff) | |
| download | rust-d066dfdb835f15fe2c4d2bdb31d88cb948b360ad.tar.gz rust-d066dfdb835f15fe2c4d2bdb31d88cb948b360ad.zip | |
we can now enable the 'const stable fn must be stable' check
Diffstat (limited to 'compiler/rustc_error_codes')
| -rw-r--r-- | compiler/rustc_error_codes/src/error_codes/E0539.md | 1 | ||||
| -rw-r--r-- | compiler/rustc_error_codes/src/error_codes/E0542.md | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/compiler/rustc_error_codes/src/error_codes/E0539.md b/compiler/rustc_error_codes/src/error_codes/E0539.md index cd28afbc48d..6b2e23ba2d8 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0539.md +++ b/compiler/rustc_error_codes/src/error_codes/E0539.md @@ -45,6 +45,7 @@ const fn unstable_fn() {} #[stable(feature = "stable_struct", since = "1.39.0")] // ok! struct Stable; +#[stable(feature = "stable_fn", since = "1.39.0")] #[rustc_const_stable(feature = "stable_fn", since = "1.39.0")] // ok! const fn stable_fn() {} ``` diff --git a/compiler/rustc_error_codes/src/error_codes/E0542.md b/compiler/rustc_error_codes/src/error_codes/E0542.md index be186dbd2cc..70590f2e48e 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0542.md +++ b/compiler/rustc_error_codes/src/error_codes/E0542.md @@ -30,6 +30,7 @@ To fix this issue, you need to provide the `since` field. Example: #[stable(feature = "_stable_fn", since = "1.0.0")] // ok! fn _stable_fn() {} +#[stable(feature = "_stable_const_fn", since = "1.0.0")] #[rustc_const_stable(feature = "_stable_const_fn", since = "1.0.0")] // ok! const fn _stable_const_fn() {} |
