From bbcdeb128cce04cd95714b7bc7af5a23a7e38bd2 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Wed, 29 Jul 2020 18:09:51 +0200 Subject: =?UTF-8?q?Move,=20rename=20and=20switch=20some=20things=20(boring?= =?UTF-8?q?)=20=F0=9F=9A=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Problems -> Diagnostics - Position -> Pos - offset_spans -> Offset trait - Size -> Length (and some more size types renamed) - Paper into its own module - scope::Parser -> parsing::CallParser - Create `Decorations` alias - Remove lots of double newlines - Switch from f32 to f64 --- src/syntax/mod.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/syntax/mod.rs') diff --git a/src/syntax/mod.rs b/src/syntax/mod.rs index f7321c77..b67d8cd7 100644 --- a/src/syntax/mod.rs +++ b/src/syntax/mod.rs @@ -20,7 +20,6 @@ pub_use_mod!(scope); pub_use_mod!(parsing); pub_use_mod!(tokens); - /// Represents a parsed piece of source that can be layouted and in the future /// also be queried for information used for refactorings, autocomplete, etc. #[async_trait(?Send)] @@ -94,6 +93,9 @@ impl PartialEq for Node { } } +/// A list of spanned decorations. +pub type Decorations = SpanVec; + /// Decorations for semantic syntax highlighting. #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash, Serialize)] #[serde(rename_all = "camelCase")] @@ -110,7 +112,6 @@ pub enum Decoration { /// ^^^^^^ /// ``` InvalidFuncName, - /// A key of a keyword argument: /// ```typst /// [box: width=5cm] @@ -123,7 +124,6 @@ pub enum Decoration { /// ^^^^ ^^^^^ /// ``` ObjectKey, - /// An italic word. Italic, /// A bold word. -- cgit v1.2.3