Rename feature gate
This commit is contained in:
parent
8b0f5acfcb
commit
d24ae2577f
4 changed files with 4 additions and 4 deletions
|
@ -528,7 +528,7 @@ declare_features! (
|
|||
(active, cfg_sanitize, "1.41.0", Some(39699), None),
|
||||
|
||||
/// Allows using `&mut` in constant functions.
|
||||
(active, const_fn_mut_refs, "1.41.0", None, None),
|
||||
(active, const_mut_refs, "1.41.0", Some(57349), None),
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
// feature-group-end: actual feature gates
|
||||
|
|
|
@ -81,7 +81,7 @@ fn check_ty(tcx: TyCtxt<'tcx>, ty: Ty<'tcx>, span: Span, fn_def_id: DefId) -> Mc
|
|||
for ty in ty.walk() {
|
||||
match ty.kind {
|
||||
ty::Ref(_, _, hir::Mutability::Mutable) => {
|
||||
if !tcx.features().const_fn_mut_refs {
|
||||
if !tcx.features().const_mut_refs {
|
||||
return Err((
|
||||
span,
|
||||
"mutable references in const fn are unstable".into(),
|
||||
|
|
|
@ -203,13 +203,13 @@ symbols! {
|
|||
const_constructor,
|
||||
const_extern_fn,
|
||||
const_fn,
|
||||
const_fn_mut_refs,
|
||||
const_fn_union,
|
||||
const_generics,
|
||||
const_if_match,
|
||||
const_indexing,
|
||||
const_in_array_repeat_expressions,
|
||||
const_let,
|
||||
const_mut_refs,
|
||||
const_panic,
|
||||
const_raw_ptr_deref,
|
||||
const_raw_ptr_to_usize_cast,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// run-pass
|
||||
|
||||
#![feature(const_fn_mut_refs)]
|
||||
#![feature(const_mut_refs)]
|
||||
|
||||
struct Foo {
|
||||
x: i32
|
||||
|
|
Loading…
Reference in a new issue