helix-lsp-types: Prefer crate::Url to url::Url

This is a cosmetic change to replace all direct `use`s of the `url::Url`
type in the `helix-lsp-types` crate with `use crate::Url;`. The types
are the same type currently: this refactor will make a future
replacement of the Url type less noisy.

Connects https://github.com/helix-editor/helix/pull/11889
This commit is contained in:
Michael Davis 2024-08-15 17:46:59 -04:00
parent cc3b77b584
commit 1980bd5992
No known key found for this signature in database
6 changed files with 6 additions and 13 deletions

View File

@ -1,10 +1,9 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use serde_json::Value; use serde_json::Value;
use url::Url;
use crate::{ use crate::{
DynamicRegistrationClientCapabilities, PartialResultParams, Range, SymbolKind, SymbolTag, DynamicRegistrationClientCapabilities, PartialResultParams, Range, SymbolKind, SymbolTag,
TextDocumentPositionParams, WorkDoneProgressOptions, WorkDoneProgressParams, TextDocumentPositionParams, Url, WorkDoneProgressOptions, WorkDoneProgressParams,
}; };
pub type CallHierarchyClientCapabilities = DynamicRegistrationClientCapabilities; pub type CallHierarchyClientCapabilities = DynamicRegistrationClientCapabilities;

View File

@ -1,11 +1,10 @@
use std::collections::HashMap; use std::collections::HashMap;
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use url::Url;
use crate::{ use crate::{
Diagnostic, PartialResultParams, StaticRegistrationOptions, TextDocumentIdentifier, Diagnostic, PartialResultParams, StaticRegistrationOptions, TextDocumentIdentifier,
TextDocumentRegistrationOptions, WorkDoneProgressOptions, WorkDoneProgressParams, TextDocumentRegistrationOptions, Url, WorkDoneProgressOptions, WorkDoneProgressParams,
}; };
/// Client capabilities specific to diagnostic pull requests. /// Client capabilities specific to diagnostic pull requests.

View File

@ -1,10 +1,9 @@
use crate::{ use crate::{
PartialResultParams, Range, TextDocumentIdentifier, WorkDoneProgressOptions, PartialResultParams, Range, TextDocumentIdentifier, Url, WorkDoneProgressOptions,
WorkDoneProgressParams, WorkDoneProgressParams,
}; };
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use serde_json::Value; use serde_json::Value;
use url::Url;
#[derive(Debug, Eq, PartialEq, Clone, Deserialize, Serialize)] #[derive(Debug, Eq, PartialEq, Clone, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")] #[serde(rename_all = "camelCase")]

View File

@ -4,9 +4,7 @@
use serde_json::Value; use serde_json::Value;
use url::Url; use crate::{Range, Url};
use crate::Range;
#[derive(Eq, PartialEq, Clone, Copy, Deserialize, Serialize)] #[derive(Eq, PartialEq, Clone, Copy, Deserialize, Serialize)]
#[serde(transparent)] #[serde(transparent)]

View File

@ -1,8 +1,7 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use url::Url;
use crate::{ use crate::{
FullDocumentDiagnosticReport, PartialResultParams, UnchangedDocumentDiagnosticReport, FullDocumentDiagnosticReport, PartialResultParams, UnchangedDocumentDiagnosticReport, Url,
WorkDoneProgressParams, WorkDoneProgressParams,
}; };

View File

@ -1,7 +1,6 @@
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use url::Url;
use crate::OneOf; use crate::{OneOf, Url};
#[derive(Debug, Eq, PartialEq, Clone, Default, Deserialize, Serialize)] #[derive(Debug, Eq, PartialEq, Clone, Default, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")] #[serde(rename_all = "camelCase")]