chore: Prepare for Rust edition bump to 2024 (without autofix) (#27791)

Successor to #27779 - in this PR I've applied changes manually, without
futzing with if let lifetimes at all.

Release Notes:

- N/A
This commit is contained in:
Piotr Osiewicz
2025-03-31 20:10:36 +02:00
committed by GitHub
parent d51aa2ffb0
commit 0729d24d77
162 changed files with 2333 additions and 1937 deletions
+2 -2
View File
@@ -17,7 +17,7 @@ pub fn derive_app_context(input: TokenStream) -> TokenStream {
let type_name = &ast.ident;
let (impl_generics, type_generics, where_clause) = ast.generics.split_for_impl();
let gen = quote! {
let r#gen = quote! {
impl #impl_generics gpui::AppContext for #type_name #type_generics
#where_clause
{
@@ -98,5 +98,5 @@ pub fn derive_app_context(input: TokenStream) -> TokenStream {
}
};
gen.into()
r#gen.into()
}
@@ -7,7 +7,7 @@ pub fn derive_into_element(input: TokenStream) -> TokenStream {
let type_name = &ast.ident;
let (impl_generics, type_generics, where_clause) = ast.generics.split_for_impl();
let gen = quote! {
let r#gen = quote! {
impl #impl_generics gpui::IntoElement for #type_name #type_generics
#where_clause
{
@@ -19,5 +19,5 @@ pub fn derive_into_element(input: TokenStream) -> TokenStream {
}
};
gen.into()
r#gen.into()
}
+2 -2
View File
@@ -7,7 +7,7 @@ pub fn derive_render(input: TokenStream) -> TokenStream {
let type_name = &ast.ident;
let (impl_generics, type_generics, where_clause) = ast.generics.split_for_impl();
let gen = quote! {
let r#gen = quote! {
impl #impl_generics gpui::Render for #type_name #type_generics
#where_clause
{
@@ -17,5 +17,5 @@ pub fn derive_render(input: TokenStream) -> TokenStream {
}
};
gen.into()
r#gen.into()
}
@@ -24,7 +24,7 @@ pub fn derive_visual_context(input: TokenStream) -> TokenStream {
let type_name = &ast.ident;
let (impl_generics, type_generics, where_clause) = ast.generics.split_for_impl();
let gen = quote! {
let r#gen = quote! {
impl #impl_generics gpui::VisualContext for #type_name #type_generics
#where_clause
{
@@ -67,5 +67,5 @@ pub fn derive_visual_context(input: TokenStream) -> TokenStream {
}
};
gen.into()
r#gen.into()
}
+7 -7
View File
@@ -1292,27 +1292,27 @@ fn border_prefixes() -> Vec<BorderStylePrefix> {
quote! { border_widths.bottom },
quote! { border_widths.left },
],
doc_string_prefix: "Sets the border width of the element. [Docs](https://tailwindcss.com/docs/border-width)"
doc_string_prefix: "Sets the border width of the element. [Docs](https://tailwindcss.com/docs/border-width)",
},
BorderStylePrefix {
prefix: "border_t",
fields: vec![quote! { border_widths.top }],
doc_string_prefix: "Sets the border width of the top side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)"
doc_string_prefix: "Sets the border width of the top side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)",
},
BorderStylePrefix {
prefix: "border_b",
fields: vec![quote! { border_widths.bottom }],
doc_string_prefix: "Sets the border width of the bottom side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)"
doc_string_prefix: "Sets the border width of the bottom side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)",
},
BorderStylePrefix {
prefix: "border_r",
fields: vec![quote! { border_widths.right }],
doc_string_prefix: "Sets the border width of the right side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)"
doc_string_prefix: "Sets the border width of the right side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)",
},
BorderStylePrefix {
prefix: "border_l",
fields: vec![quote! { border_widths.left }],
doc_string_prefix: "Sets the border width of the left side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)"
doc_string_prefix: "Sets the border width of the left side of the element. [Docs](https://tailwindcss.com/docs/border-width#individual-sides)",
},
BorderStylePrefix {
prefix: "border_x",
@@ -1320,7 +1320,7 @@ fn border_prefixes() -> Vec<BorderStylePrefix> {
quote! { border_widths.left },
quote! { border_widths.right },
],
doc_string_prefix: "Sets the border width of the vertical sides of the element. [Docs](https://tailwindcss.com/docs/border-width#horizontal-and-vertical-sides)"
doc_string_prefix: "Sets the border width of the vertical sides of the element. [Docs](https://tailwindcss.com/docs/border-width#horizontal-and-vertical-sides)",
},
BorderStylePrefix {
prefix: "border_y",
@@ -1328,7 +1328,7 @@ fn border_prefixes() -> Vec<BorderStylePrefix> {
quote! { border_widths.top },
quote! { border_widths.bottom },
],
doc_string_prefix: "Sets the border width of the horizontal sides of the element. [Docs](https://tailwindcss.com/docs/border-width#horizontal-and-vertical-sides)"
doc_string_prefix: "Sets the border width of the horizontal sides of the element. [Docs](https://tailwindcss.com/docs/border-width#horizontal-and-vertical-sides)",
},
]
}