summaryrefslogtreecommitdiff
path: root/crates/typst-syntax/src
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2023-11-23 16:25:49 +0100
committerLaurenz <laurmaedje@gmail.com>2023-11-24 12:30:02 +0100
commit7eebafa7837ec173a7b2064ae60fd45b5413d17c (patch)
treeb63b302b6d7747bcbb28571713745b9ca1aa83a4 /crates/typst-syntax/src
parent76e173b78b511b506b928c27ac360f75fa455747 (diff)
Merge `typst` and `typst-library`
Diffstat (limited to 'crates/typst-syntax/src')
-rw-r--r--crates/typst-syntax/src/reparser.rs2
-rw-r--r--crates/typst-syntax/src/span.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/crates/typst-syntax/src/reparser.rs b/crates/typst-syntax/src/reparser.rs
index 1374bde0..1b7dc42f 100644
--- a/crates/typst-syntax/src/reparser.rs
+++ b/crates/typst-syntax/src/reparser.rs
@@ -11,7 +11,7 @@ use crate::{
/// ultimately reparsed.
///
/// The high-level API for this function is
-/// [`Source::edit`](super::Source::edit).
+/// [`Source::edit`](crate::Source::edit).
pub fn reparse(
root: &mut SyntaxNode,
text: &str,
diff --git a/crates/typst-syntax/src/span.rs b/crates/typst-syntax/src/span.rs
index 5b8fd693..14e5e216 100644
--- a/crates/typst-syntax/src/span.rs
+++ b/crates/typst-syntax/src/span.rs
@@ -7,7 +7,7 @@ use crate::FileId;
/// A unique identifier for a syntax node.
///
/// This is used throughout the compiler to track which source section an error
-/// or element stems from. Can be [mapped back](super::Source::range) to a byte
+/// or element stems from. Can be [mapped back](crate::Source::range) to a byte
/// range for user facing display.
///
/// During editing, the span values stay mostly stable, even for nodes behind an
@@ -76,7 +76,7 @@ impl Span {
Some(FileId::from_raw(bits))
}
- /// The unique number of the span within its [`Source`](super::Source).
+ /// The unique number of the span within its [`Source`](crate::Source).
pub const fn number(self) -> u64 {
self.0.get() & ((1 << Self::BITS) - 1)
}