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:
parent
d50905e000
commit
dc64ec9cc8
802 changed files with 3775 additions and 3662 deletions
|
@ -11,24 +11,24 @@ pub(crate) mod windows_only_instance;
|
|||
use anyhow::Context as _;
|
||||
pub use app_menus::*;
|
||||
use assets::Assets;
|
||||
use assistant2::AssistantDiffToolbar;
|
||||
use assistant_context_editor::AssistantPanelDelegate;
|
||||
use assistant2::AssistantDiffToolbar;
|
||||
use breadcrumbs::Breadcrumbs;
|
||||
use client::{zed_urls, ZED_URL_SCHEME};
|
||||
use client::{ZED_URL_SCHEME, zed_urls};
|
||||
use collections::VecDeque;
|
||||
use command_palette_hooks::CommandPaletteFilter;
|
||||
use debugger_ui::debugger_panel::DebugPanel;
|
||||
use editor::ProposedChangesEditorToolbar;
|
||||
use editor::{scroll::Autoscroll, Editor, MultiBuffer};
|
||||
use editor::{Editor, MultiBuffer, scroll::Autoscroll};
|
||||
use feature_flags::{Debugger, FeatureFlagAppExt, FeatureFlagViewExt};
|
||||
use futures::{channel::mpsc, select_biased, StreamExt};
|
||||
use futures::{StreamExt, channel::mpsc, select_biased};
|
||||
use git_ui::git_panel::GitPanel;
|
||||
use git_ui::project_diff::ProjectDiffToolbar;
|
||||
use gpui::{
|
||||
actions, point, px, Action, App, AppContext as _, AsyncApp, AsyncWindowContext, Context,
|
||||
DismissEvent, Element, Entity, Focusable, KeyBinding, MenuItem, ParentElement,
|
||||
PathPromptOptions, PromptLevel, ReadGlobal, SharedString, Styled, Task, TitlebarOptions,
|
||||
UpdateGlobal, Window, WindowKind, WindowOptions,
|
||||
Action, App, AppContext as _, AsyncApp, AsyncWindowContext, Context, DismissEvent, Element,
|
||||
Entity, Focusable, KeyBinding, MenuItem, ParentElement, PathPromptOptions, PromptLevel,
|
||||
ReadGlobal, SharedString, Styled, Task, TitlebarOptions, UpdateGlobal, Window, WindowKind,
|
||||
WindowOptions, actions, point, px,
|
||||
};
|
||||
use image_viewer::ImageInfo;
|
||||
use migrate::{MigrationBanner, MigrationEvent, MigrationNotification, MigrationType};
|
||||
|
@ -48,9 +48,9 @@ use release_channel::{AppCommitSha, ReleaseChannel};
|
|||
use rope::Rope;
|
||||
use search::project_search::ProjectSearchBar;
|
||||
use settings::{
|
||||
initial_debug_tasks_content, initial_project_settings_content, initial_tasks_content,
|
||||
update_settings_file, InvalidSettingsError, KeymapFile, KeymapFileLoadResult, Settings,
|
||||
SettingsStore, DEFAULT_KEYMAP_PATH, VIM_KEYMAP_PATH,
|
||||
DEFAULT_KEYMAP_PATH, InvalidSettingsError, KeymapFile, KeymapFileLoadResult, Settings,
|
||||
SettingsStore, VIM_KEYMAP_PATH, initial_debug_tasks_content, initial_project_settings_content,
|
||||
initial_tasks_content, update_settings_file,
|
||||
};
|
||||
use std::any::TypeId;
|
||||
use std::path::PathBuf;
|
||||
|
@ -59,19 +59,20 @@ use std::time::Duration;
|
|||
use std::{borrow::Cow, ops::Deref, path::Path, sync::Arc};
|
||||
use terminal_view::terminal_panel::{self, TerminalPanel};
|
||||
use theme::{ActiveTheme, ThemeSettings};
|
||||
use ui::{prelude::*, PopoverMenuHandle};
|
||||
use ui::{PopoverMenuHandle, prelude::*};
|
||||
use util::markdown::MarkdownString;
|
||||
use util::{asset_str, ResultExt};
|
||||
use util::{ResultExt, asset_str};
|
||||
use uuid::Uuid;
|
||||
use vim_mode_setting::VimModeSetting;
|
||||
use welcome::{BaseKeymap, MultibufferHint};
|
||||
use workspace::notifications::{dismiss_app_notification, show_app_notification, NotificationId};
|
||||
use workspace::notifications::{NotificationId, dismiss_app_notification, show_app_notification};
|
||||
use workspace::{
|
||||
AppState, NewFile, NewWindow, OpenLog, Toast, Workspace, WorkspaceSettings,
|
||||
create_and_open_local_file, notifications::simple_message_notification::MessageNotification,
|
||||
open_new, AppState, NewFile, NewWindow, OpenLog, Toast, Workspace, WorkspaceSettings,
|
||||
open_new,
|
||||
};
|
||||
use workspace::{notifications::DetachAndPromptErr, Pane};
|
||||
use workspace::{CloseIntent, RestoreBanner};
|
||||
use workspace::{Pane, notifications::DetachAndPromptErr};
|
||||
use zed_actions::{
|
||||
OpenAccountSettings, OpenBrowser, OpenServerSettings, OpenSettings, OpenZedUrl, Quit,
|
||||
};
|
||||
|
@ -1751,15 +1752,15 @@ mod tests {
|
|||
use super::*;
|
||||
use assets::Assets;
|
||||
use collections::HashSet;
|
||||
use editor::{display_map::DisplayRow, scroll::Autoscroll, DisplayPoint, Editor};
|
||||
use editor::{DisplayPoint, Editor, display_map::DisplayRow, scroll::Autoscroll};
|
||||
use gpui::{
|
||||
actions, Action, AnyWindowHandle, App, AssetSource, BorrowAppContext, SemanticVersion,
|
||||
TestAppContext, UpdateGlobal, VisualTestContext, WindowHandle,
|
||||
Action, AnyWindowHandle, App, AssetSource, BorrowAppContext, SemanticVersion,
|
||||
TestAppContext, UpdateGlobal, VisualTestContext, WindowHandle, actions,
|
||||
};
|
||||
use language::{LanguageMatcher, LanguageRegistry};
|
||||
use project::{project_settings::ProjectSettings, Project, ProjectPath, WorktreeSettings};
|
||||
use project::{Project, ProjectPath, WorktreeSettings, project_settings::ProjectSettings};
|
||||
use serde_json::json;
|
||||
use settings::{watch_config_file, SettingsStore};
|
||||
use settings::{SettingsStore, watch_config_file};
|
||||
use std::{
|
||||
path::{Path, PathBuf},
|
||||
time::Duration,
|
||||
|
@ -1767,9 +1768,10 @@ mod tests {
|
|||
use theme::{ThemeRegistry, ThemeSettings};
|
||||
use util::{path, separator};
|
||||
use workspace::{
|
||||
NewFile, OpenOptions, OpenVisible, SERIALIZATION_THROTTLE_TIME, SaveIntent, SplitDirection,
|
||||
WorkspaceHandle,
|
||||
item::{Item, ItemHandle},
|
||||
open_new, open_paths, pane, NewFile, OpenOptions, OpenVisible, SaveIntent, SplitDirection,
|
||||
WorkspaceHandle, SERIALIZATION_THROTTLE_TIME,
|
||||
open_new, open_paths, pane,
|
||||
};
|
||||
|
||||
#[gpui::test]
|
||||
|
@ -1871,11 +1873,13 @@ mod tests {
|
|||
.update(cx, |workspace, window, cx| {
|
||||
assert_eq!(workspace.worktrees(cx).count(), 2);
|
||||
assert!(workspace.left_dock().read(cx).is_open());
|
||||
assert!(workspace
|
||||
.active_pane()
|
||||
.read(cx)
|
||||
.focus_handle(cx)
|
||||
.is_focused(window));
|
||||
assert!(
|
||||
workspace
|
||||
.active_pane()
|
||||
.read(cx)
|
||||
.focus_handle(cx)
|
||||
.is_focused(window)
|
||||
);
|
||||
})
|
||||
.unwrap();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue