chore: Bump Rust edition to 2024 (#27800)

Follow-up to https://github.com/zed-industries/zed/pull/27791

Release Notes:

- N/A
This commit is contained in:
Piotr Osiewicz 2025-03-31 20:55:27 +02:00 committed by GitHub
parent d50905e000
commit dc64ec9cc8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
802 changed files with 3775 additions and 3662 deletions

View file

@ -1,7 +1,7 @@
use gpui::{Hsla, Rgba};
use crate::scale::{ColorScaleSet, ColorScales};
use crate::ColorScale;
use crate::scale::{ColorScaleSet, ColorScales};
use crate::{SystemColors, ThemeColors};
pub(crate) fn neutral() -> ColorScaleSet {

View file

@ -1,11 +1,10 @@
use std::sync::Arc;
use gpui::{hsla, FontStyle, FontWeight, HighlightStyle, Hsla, WindowBackgroundAppearance};
use gpui::{FontStyle, FontWeight, HighlightStyle, Hsla, WindowBackgroundAppearance, hsla};
use crate::{
default_color_scales, AccentColors, Appearance, PlayerColors, StatusColors,
StatusColorsRefinement, SyntaxTheme, SystemColors, Theme, ThemeColors, ThemeFamily,
ThemeStyles,
AccentColors, Appearance, PlayerColors, StatusColors, StatusColorsRefinement, SyntaxTheme,
SystemColors, Theme, ThemeColors, ThemeFamily, ThemeStyles, default_color_scales,
};
/// The default theme family for Zed.

View file

@ -12,9 +12,9 @@ use thiserror::Error;
use util::ResultExt;
use crate::{
default_icon_theme, read_icon_theme, read_user_theme, refine_theme_family, Appearance,
AppearanceContent, ChevronIcons, DirectoryIcons, IconDefinition, IconTheme, Theme, ThemeFamily,
ThemeFamilyContent, DEFAULT_ICON_THEME_NAME,
Appearance, AppearanceContent, ChevronIcons, DEFAULT_ICON_THEME_NAME, DirectoryIcons,
IconDefinition, IconTheme, Theme, ThemeFamily, ThemeFamilyContent, default_icon_theme,
read_icon_theme, read_user_theme, refine_theme_family,
};
/// The metadata for a theme.

View file

@ -4,9 +4,9 @@ use anyhow::Result;
use gpui::{FontStyle, FontWeight, HighlightStyle, Hsla, WindowBackgroundAppearance};
use indexmap::IndexMap;
use palette::FromColor;
use schemars::JsonSchema;
use schemars::r#gen::SchemaGenerator;
use schemars::schema::{Schema, SchemaObject};
use schemars::JsonSchema;
use serde::{Deserialize, Deserializer, Serialize};
use serde_json::Value;
use serde_repr::{Deserialize_repr, Serialize_repr};

View file

@ -1,23 +1,23 @@
use crate::fallback_themes::zed_default_dark;
use crate::{
Appearance, IconTheme, IconThemeNotFoundError, SyntaxTheme, Theme, ThemeNotFoundError,
ThemeRegistry, ThemeStyleContent, DEFAULT_ICON_THEME_NAME,
Appearance, DEFAULT_ICON_THEME_NAME, IconTheme, IconThemeNotFoundError, SyntaxTheme, Theme,
ThemeNotFoundError, ThemeRegistry, ThemeStyleContent,
};
use anyhow::Result;
use derive_more::{Deref, DerefMut};
use gpui::{
px, App, Context, Font, FontFallbacks, FontFeatures, FontStyle, FontWeight, Global, Pixels,
Subscription, Window,
App, Context, Font, FontFallbacks, FontFeatures, FontStyle, FontWeight, Global, Pixels,
Subscription, Window, px,
};
use refineable::Refineable;
use schemars::{
JsonSchema,
r#gen::SchemaGenerator,
schema::{InstanceType, Schema, SchemaObject},
JsonSchema,
};
use serde::{Deserialize, Serialize};
use serde_json::Value;
use settings::{add_references_to_properties, Settings, SettingsJsonSchemaParams, SettingsSources};
use settings::{Settings, SettingsJsonSchemaParams, SettingsSources, add_references_to_properties};
use std::sync::Arc;
use util::ResultExt as _;

View file

@ -2,8 +2,8 @@ use gpui::Hsla;
use serde_derive::Deserialize;
use crate::{
amber, blue, cyan, gold, grass, indigo, iris, jade, lime, orange, pink, purple, tomato,
try_parse_color, AccentContent,
AccentContent, amber, blue, cyan, gold, grass, indigo, iris, jade, lime, orange, pink, purple,
tomato, try_parse_color,
};
/// A collection of colors that are used to color indent aware lines in the editor.

View file

@ -4,7 +4,7 @@ use gpui::Hsla;
use serde_derive::Deserialize;
use crate::{
amber, blue, jade, lime, orange, pink, purple, red, try_parse_color, PlayerColorContent,
PlayerColorContent, amber, blue, jade, lime, orange, pink, purple, red, try_parse_color,
};
#[derive(Debug, Clone, Copy, Deserialize, Default, PartialEq)]

View file

@ -1,6 +1,6 @@
#![allow(missing_docs)]
use gpui::{hsla, Hsla};
use gpui::{Hsla, hsla};
#[derive(Clone, PartialEq)]
pub struct SystemColors {

View file

@ -28,8 +28,8 @@ use anyhow::Result;
use fallback_themes::apply_status_color_defaults;
use fs::Fs;
use gpui::{
px, App, AssetSource, HighlightStyle, Hsla, Pixels, Refineable, SharedString, WindowAppearance,
WindowBackgroundAppearance,
App, AssetSource, HighlightStyle, Hsla, Pixels, Refineable, SharedString, WindowAppearance,
WindowBackgroundAppearance, px,
};
use serde::Deserialize;
use uuid::Uuid;