diff options
| author | Laurenz <laurmaedje@gmail.com> | 2024-04-02 16:16:44 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-02 14:16:44 +0000 |
| commit | b3615ccd493c4791c3c7565fc7417cba50e8fd71 (patch) | |
| tree | 264c711ead8cf76439816b1457429a157e614067 /crates | |
| parent | c4001662b686b0d52e99aa0b72a5b82af6f862fd (diff) | |
A few CI and crate config changes (#3852)
Diffstat (limited to 'crates')
| -rw-r--r-- | crates/typst-cli/Cargo.toml | 3 | ||||
| -rw-r--r-- | crates/typst-ide/Cargo.toml | 5 | ||||
| -rw-r--r-- | crates/typst-macros/Cargo.toml | 3 | ||||
| -rw-r--r-- | crates/typst-macros/src/category.rs | 1 | ||||
| -rw-r--r-- | crates/typst-macros/src/lib.rs | 2 | ||||
| -rw-r--r-- | crates/typst-macros/src/util.rs | 1 | ||||
| -rw-r--r-- | crates/typst-pdf/Cargo.toml | 4 | ||||
| -rw-r--r-- | crates/typst-pdf/src/lib.rs | 1 | ||||
| -rw-r--r-- | crates/typst-render/Cargo.toml | 4 | ||||
| -rw-r--r-- | crates/typst-svg/Cargo.toml | 4 | ||||
| -rw-r--r-- | crates/typst-syntax/Cargo.toml | 4 | ||||
| -rw-r--r-- | crates/typst/Cargo.toml | 4 | ||||
| -rw-r--r-- | crates/typst/src/diag.rs | 4 | ||||
| -rw-r--r-- | crates/typst/src/foundations/cast.rs | 4 | ||||
| -rw-r--r-- | crates/typst/src/foundations/selector.rs | 4 | ||||
| -rw-r--r-- | crates/typst/src/foundations/styles.rs | 7 | ||||
| -rw-r--r-- | crates/typst/src/layout/grid/lines.rs | 2 | ||||
| -rw-r--r-- | crates/typst/src/model/outline.rs | 1 |
18 files changed, 8 insertions, 50 deletions
diff --git a/crates/typst-cli/Cargo.toml b/crates/typst-cli/Cargo.toml index 65803a1d..c2b23df0 100644 --- a/crates/typst-cli/Cargo.toml +++ b/crates/typst-cli/Cargo.toml @@ -15,9 +15,6 @@ readme = { workspace = true } [[bin]] name = "typst" path = "src/main.rs" -test = false -doctest = false -bench = false doc = false [dependencies] diff --git a/crates/typst-ide/Cargo.toml b/crates/typst-ide/Cargo.toml index b2927562..45a83d55 100644 --- a/crates/typst-ide/Cargo.toml +++ b/crates/typst-ide/Cargo.toml @@ -12,11 +12,6 @@ categories = { workspace = true } keywords = { workspace = true } readme = { workspace = true } -[lib] -test = false -doctest = false -bench = false - [dependencies] typst = { workspace = true } comemo = { workspace = true } diff --git a/crates/typst-macros/Cargo.toml b/crates/typst-macros/Cargo.toml index caef7eb4..b6b496cb 100644 --- a/crates/typst-macros/Cargo.toml +++ b/crates/typst-macros/Cargo.toml @@ -14,9 +14,6 @@ readme = { workspace = true } [lib] proc-macro = true -test = false -doctest = false -bench = false [dependencies] heck = { workspace = true } diff --git a/crates/typst-macros/src/category.rs b/crates/typst-macros/src/category.rs index ac8c813d..26ec879c 100644 --- a/crates/typst-macros/src/category.rs +++ b/crates/typst-macros/src/category.rs @@ -33,6 +33,7 @@ pub fn category(_: TokenStream, item: syn::Item) -> Result<TokenStream> { } /// Parse a bare `pub static CATEGORY: Category;` item. +#[allow(dead_code)] pub struct BareStatic { pub attrs: Vec<Attribute>, pub vis: Visibility, diff --git a/crates/typst-macros/src/lib.rs b/crates/typst-macros/src/lib.rs index 35c48b4a..58d96386 100644 --- a/crates/typst-macros/src/lib.rs +++ b/crates/typst-macros/src/lib.rs @@ -136,7 +136,7 @@ pub fn ty(stream: BoundaryStream, item: BoundaryStream) -> BoundaryStream { /// /// This implements `NativeElement` for the given type. /// -/// ``` +/// ```ignore /// /// A section heading. /// #[elem(Show, Count)] /// struct HeadingElem { diff --git a/crates/typst-macros/src/util.rs b/crates/typst-macros/src/util.rs index bfe22285..b6acc7d8 100644 --- a/crates/typst-macros/src/util.rs +++ b/crates/typst-macros/src/util.rs @@ -232,6 +232,7 @@ impl Parse for BlockWithReturn { } /// Parse a bare `type Name;` item. +#[allow(dead_code)] pub struct BareType { pub attrs: Vec<Attribute>, pub type_token: Token![type], diff --git a/crates/typst-pdf/Cargo.toml b/crates/typst-pdf/Cargo.toml index 709ed108..99c52dc6 100644 --- a/crates/typst-pdf/Cargo.toml +++ b/crates/typst-pdf/Cargo.toml @@ -12,10 +12,6 @@ categories = { workspace = true } keywords = { workspace = true } readme = { workspace = true } -[lib] -doctest = false -bench = false - [dependencies] typst = { workspace = true } typst-assets = { workspace = true } diff --git a/crates/typst-pdf/src/lib.rs b/crates/typst-pdf/src/lib.rs index 49ec0d86..e8b1c30a 100644 --- a/crates/typst-pdf/src/lib.rs +++ b/crates/typst-pdf/src/lib.rs @@ -9,7 +9,6 @@ mod outline; mod page; mod pattern; -use std::cmp::Eq; use std::collections::{BTreeMap, HashMap, HashSet}; use std::hash::Hash; use std::sync::Arc; diff --git a/crates/typst-render/Cargo.toml b/crates/typst-render/Cargo.toml index 2db9b5ed..cc58f785 100644 --- a/crates/typst-render/Cargo.toml +++ b/crates/typst-render/Cargo.toml @@ -12,10 +12,6 @@ categories = { workspace = true } keywords = { workspace = true } readme = { workspace = true } -[lib] -doctest = false -bench = false - [dependencies] typst = { workspace = true } typst-macros = { workspace = true } diff --git a/crates/typst-svg/Cargo.toml b/crates/typst-svg/Cargo.toml index 143e88ed..df49a2b1 100644 --- a/crates/typst-svg/Cargo.toml +++ b/crates/typst-svg/Cargo.toml @@ -12,10 +12,6 @@ categories = { workspace = true } keywords = { workspace = true } readme = { workspace = true } -[lib] -doctest = false -bench = false - [dependencies] typst = { workspace = true } typst-macros = { workspace = true } diff --git a/crates/typst-syntax/Cargo.toml b/crates/typst-syntax/Cargo.toml index f92b6d9b..001d405c 100644 --- a/crates/typst-syntax/Cargo.toml +++ b/crates/typst-syntax/Cargo.toml @@ -12,10 +12,6 @@ categories = { workspace = true } keywords = { workspace = true } readme = { workspace = true } -[lib] -doctest = false -bench = false - [dependencies] comemo = { workspace = true } ecow = { workspace = true } diff --git a/crates/typst/Cargo.toml b/crates/typst/Cargo.toml index fd82c2cc..cfc4e32e 100644 --- a/crates/typst/Cargo.toml +++ b/crates/typst/Cargo.toml @@ -12,10 +12,6 @@ repository = { workspace = true } license = { workspace = true } readme = { workspace = true } -[lib] -doctest = false -bench = false - [dependencies] typst-assets = { workspace = true } typst-macros = { workspace = true } diff --git a/crates/typst/src/diag.rs b/crates/typst/src/diag.rs index c6cd6acb..6e119591 100644 --- a/crates/typst/src/diag.rs +++ b/crates/typst/src/diag.rs @@ -21,7 +21,7 @@ use crate::{World, WorldExt}; /// /// You can also emit hints with the `; hint: "..."` syntax. /// -/// ``` +/// ```ignore /// bail!("bailing with a {}", "string result"); /// bail!(span, "bailing with a {}", "source result"); /// bail!( @@ -81,7 +81,7 @@ macro_rules! __error { /// /// You can also emit hints with the `; hint: "..."` syntax. /// -/// ``` +/// ```ignore /// warning!(span, "warning with a {}", "source result"); /// warning!( /// span, "warning with a {}", "source result"; diff --git a/crates/typst/src/foundations/cast.rs b/crates/typst/src/foundations/cast.rs index 3b74f1fb..b29e4473 100644 --- a/crates/typst/src/foundations/cast.rs +++ b/crates/typst/src/foundations/cast.rs @@ -44,9 +44,9 @@ pub trait Reflect { /// Produce an error message for an inacceptable value type. /// - /// ``` + /// ```ignore /// assert_eq!( - /// <Int as Reflect>::error(&Value::None), + /// <i64 as Reflect>::error(&Value::None), /// "expected integer, found none", /// ); /// ``` diff --git a/crates/typst/src/foundations/selector.rs b/crates/typst/src/foundations/selector.rs index 4dc8ab3b..90663500 100644 --- a/crates/typst/src/foundations/selector.rs +++ b/crates/typst/src/foundations/selector.rs @@ -15,10 +15,6 @@ use crate::symbols::Symbol; use crate::text::TextElem; /// A helper macro to create a field selector used in [`Selector::Elem`] -/// -/// ```ignore -/// select_where!(SequenceElem, Children => vec![]); -/// ``` #[macro_export] #[doc(hidden)] macro_rules! __select_where { diff --git a/crates/typst/src/foundations/styles.rs b/crates/typst/src/foundations/styles.rs index dd09b605..35460088 100644 --- a/crates/typst/src/foundations/styles.rs +++ b/crates/typst/src/foundations/styles.rs @@ -321,9 +321,6 @@ trait Blockable: Debug + Send + Sync + 'static { /// Equivalent to `downcast_ref` for the block. fn as_any(&self) -> &dyn Any; - /// Equivalent to `downcast_mut` for the block. - fn as_any_mut(&mut self) -> &mut dyn Any; - /// Equivalent to [`Hash`] for the block. fn dyn_hash(&self, state: &mut dyn Hasher); @@ -336,10 +333,6 @@ impl<T: Debug + Clone + Hash + Send + Sync + 'static> Blockable for T { self } - fn as_any_mut(&mut self) -> &mut dyn Any { - self - } - fn dyn_hash(&self, mut state: &mut dyn Hasher) { // Also hash the TypeId since values with different types but // equal data should be different. diff --git a/crates/typst/src/layout/grid/lines.rs b/crates/typst/src/layout/grid/lines.rs index c976da2d..7ea021d7 100644 --- a/crates/typst/src/layout/grid/lines.rs +++ b/crates/typst/src/layout/grid/lines.rs @@ -597,7 +597,7 @@ pub(super) fn hline_stroke_at_column( #[cfg(test)] mod test { - use super::super::layout::{Entry, RowPiece}; + use super::super::layout::Entry; use super::*; use crate::foundations::Content; use crate::layout::{Axes, Cell, Sides, Sizing}; diff --git a/crates/typst/src/model/outline.rs b/crates/typst/src/model/outline.rs index 15ce3d55..a85d1cdf 100644 --- a/crates/typst/src/model/outline.rs +++ b/crates/typst/src/model/outline.rs @@ -73,7 +73,6 @@ pub struct OutlineElem { /// The outline's heading will not be numbered by default, but you can /// force it to be with a show-set rule: /// `{show outline: set heading(numbering: "1.")}` - /// ``` #[default(Some(Smart::Auto))] pub title: Option<Smart<Content>>, |
