1
Fork 0

Add ergonomic_clones feature flag

This commit is contained in:
Santiago Pastorino 2024-10-29 17:11:57 -03:00
parent 4559163ccb
commit 0cf8dbc96c
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
5 changed files with 50 additions and 0 deletions

View file

@ -489,6 +489,7 @@ pub fn check_crate(krate: &ast::Crate, sess: &Session, features: &Features) {
gate_all!(dyn_star, "`dyn*` trait objects are experimental");
gate_all!(const_closures, "const closures are experimental");
gate_all!(builtin_syntax, "`builtin #` syntax is unstable");
gate_all!(ergonomic_clones, "`.use` calls are experimental");
gate_all!(explicit_tail_calls, "`become` expression is experimental");
gate_all!(generic_const_items, "generic const items are experimental");
gate_all!(guard_patterns, "guard patterns are experimental", "consider using match arm guards");

View file

@ -473,6 +473,8 @@ declare_features! (
(unstable, doc_masked, "1.21.0", Some(44027)),
/// Allows `dyn* Trait` objects.
(incomplete, dyn_star, "1.65.0", Some(102425)),
/// Allows the .use postfix syntax `x.use` and use closures `use |x| { ... }`
(unstable, ergonomic_clones, "CURRENT_RUSTC_VERSION", Some(132290)),
/// Allows exhaustive pattern matching on types that contain uninhabited types.
(unstable, exhaustive_patterns, "1.13.0", Some(51085)),
/// Allows explicit tail calls via `become` expression.

View file

@ -859,6 +859,7 @@ symbols! {
eprint_macro,
eprintln_macro,
eq,
ergonomic_clones,
ermsb_target_feature,
exact_div,
except,