WIP: Determine autoindents asynchronously
We still need to insert yield points in `compute_autoindents`. Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
7f5d454b2d
commit
28ffd750ce
2 changed files with 252 additions and 228 deletions
|
@ -12,18 +12,22 @@ pub struct Anchor {
|
|||
pub version: clock::Global,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct AnchorMap<T> {
|
||||
pub(crate) version: clock::Global,
|
||||
pub(crate) entries: Vec<((usize, Bias), T)>,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct AnchorSet(pub(crate) AnchorMap<()>);
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct AnchorRangeMap<T> {
|
||||
pub(crate) version: clock::Global,
|
||||
pub(crate) entries: Vec<(Range<(usize, Bias)>, T)>,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct AnchorRangeSet(pub(crate) AnchorRangeMap<()>);
|
||||
|
||||
impl Anchor {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue