mirror of
https://github.com/Myriad-Dreamin/tinymist.git
synced 2025-11-23 12:46:43 +00:00
feat: bump edition of most crates to rust 2024 (#2042)
Some checks are pending
tinymist::auto_tag / auto-tag (push) Waiting to run
tinymist::ci / announce (push) Blocked by required conditions
tinymist::ci / Duplicate Actions Detection (push) Waiting to run
tinymist::ci / Check Clippy, Formatting, Completion, Documentation, and Tests (Linux) (push) Waiting to run
tinymist::ci / Check Minimum Rust version and Tests (Windows) (push) Waiting to run
tinymist::ci / prepare-build (push) Waiting to run
tinymist::ci / build (push) Blocked by required conditions
tinymist::gh_pages / build-gh-pages (push) Waiting to run
Some checks are pending
tinymist::auto_tag / auto-tag (push) Waiting to run
tinymist::ci / announce (push) Blocked by required conditions
tinymist::ci / Duplicate Actions Detection (push) Waiting to run
tinymist::ci / Check Clippy, Formatting, Completion, Documentation, and Tests (Linux) (push) Waiting to run
tinymist::ci / Check Minimum Rust version and Tests (Windows) (push) Waiting to run
tinymist::ci / prepare-build (push) Waiting to run
tinymist::ci / build (push) Blocked by required conditions
tinymist::gh_pages / build-gh-pages (push) Waiting to run
This commit is contained in:
parent
d227ad2a53
commit
05280aec4d
128 changed files with 340 additions and 331 deletions
|
|
@ -1,7 +1,7 @@
|
|||
use std::path::Path;
|
||||
use std::sync::Arc;
|
||||
|
||||
use ecow::{eco_format, EcoString};
|
||||
use ecow::{EcoString, eco_format};
|
||||
use tinymist_std::path::unix_slash;
|
||||
use tinymist_world::diag::print_diagnostics_to_string;
|
||||
use tinymist_world::vfs::WorkspaceResolver;
|
||||
|
|
@ -9,10 +9,10 @@ use tinymist_world::{
|
|||
DiagnosticFormat, EntryReader, EntryState, ShadowApi, SourceWorld, TaskInputs,
|
||||
};
|
||||
use typlite::{Format, TypliteFeat};
|
||||
use typst::World;
|
||||
use typst::diag::StrResult;
|
||||
use typst::foundations::Bytes;
|
||||
use typst::syntax::FileId;
|
||||
use typst::World;
|
||||
|
||||
use crate::analysis::SharedContext;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
use std::sync::OnceLock;
|
||||
|
||||
use tinymist_analysis::docs::{format_ty, ParamDocs, SignatureDocs, VarDocs};
|
||||
use tinymist_analysis::ty::DocSource;
|
||||
use tinymist_analysis::Signature;
|
||||
use tinymist_analysis::docs::{ParamDocs, SignatureDocs, VarDocs, format_ty};
|
||||
use tinymist_analysis::ty::DocSource;
|
||||
use typst::syntax::Span;
|
||||
|
||||
use crate::LocalContext;
|
||||
|
|
|
|||
|
|
@ -2,18 +2,18 @@
|
|||
|
||||
use std::collections::HashMap;
|
||||
|
||||
use ecow::{eco_vec, EcoString, EcoVec};
|
||||
use ecow::{EcoString, EcoVec, eco_vec};
|
||||
use itertools::Itertools;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use typst::diag::StrResult;
|
||||
use typst::syntax::package::PackageSpec;
|
||||
use typst::syntax::FileId;
|
||||
use typst::syntax::package::PackageSpec;
|
||||
|
||||
use crate::LocalContext;
|
||||
use crate::adt::interner::Interned;
|
||||
use crate::docs::file_id_repr;
|
||||
use crate::package::{get_manifest_id, PackageInfo};
|
||||
use crate::package::{PackageInfo, get_manifest_id};
|
||||
use crate::syntax::{Decl, DefKind, Expr, ExprInfo};
|
||||
use crate::LocalContext;
|
||||
|
||||
use super::DefDocs;
|
||||
|
||||
|
|
|
|||
|
|
@ -7,13 +7,13 @@ use indexmap::IndexSet;
|
|||
use serde::{Deserialize, Serialize};
|
||||
use tinymist_analysis::docs::tidy::remove_list_annotations;
|
||||
use tinymist_world::package::PackageSpec;
|
||||
use typst::diag::{eco_format, StrResult};
|
||||
use typst::diag::{StrResult, eco_format};
|
||||
use typst::syntax::package::PackageManifest;
|
||||
use typst::syntax::{FileId, Span};
|
||||
|
||||
use crate::docs::{file_id_repr, module_docs, DefDocs, PackageDefInfo};
|
||||
use crate::package::{get_manifest_id, PackageInfo};
|
||||
use crate::LocalContext;
|
||||
use crate::docs::{DefDocs, PackageDefInfo, file_id_repr, module_docs};
|
||||
use crate::package::{PackageInfo, get_manifest_id};
|
||||
|
||||
/// Documentation Information about a package.
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
|
|
@ -318,10 +318,10 @@ pub fn package_docs_md(doc: &PackageDoc) -> StrResult<String> {
|
|||
None => "unknown",
|
||||
};
|
||||
let _ = writeln!(
|
||||
out,
|
||||
"#### {} ({ty:?})\n<!-- begin:param-doc {} -->\n{}\n<!-- end:param-doc {} -->",
|
||||
param.name, param.name, param.docs, param.name
|
||||
);
|
||||
out,
|
||||
"#### {} ({ty:?})\n<!-- begin:param-doc {} -->\n{}\n<!-- end:param-doc {} -->",
|
||||
param.name, param.name, param.docs, param.name
|
||||
);
|
||||
let _ = writeln!(out, "<!-- end:param -->");
|
||||
}
|
||||
}
|
||||
|
|
@ -434,7 +434,7 @@ struct ConvertResult {
|
|||
mod tests {
|
||||
use tinymist_world::package::{PackageRegistry, PackageSpec};
|
||||
|
||||
use super::{package_docs, package_docs_md, package_docs_typ, PackageInfo};
|
||||
use super::{PackageInfo, package_docs, package_docs_md, package_docs_typ};
|
||||
use crate::tests::*;
|
||||
|
||||
fn test(pkg: PackageSpec) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue