docs: leave some comments

This commit is contained in:
Zixuan Chen 2024-08-16 10:47:56 +08:00
parent dd5c1bea72
commit cb3458b862
No known key found for this signature in database

View file

@ -44,12 +44,13 @@ pub enum ListOp<'a> {
#[derive(EnumAsInner, Debug, Clone)] #[derive(EnumAsInner, Debug, Clone)]
pub enum InnerListOp { pub enum InnerListOp {
// Note: len may not equal to slice.len() because for text len is unicode len while the slice // TODO: this is only used for list now? We should rename it to InsertList
// is utf8 bytes.
Insert { Insert {
slice: SliceRange, slice: SliceRange,
pos: usize, pos: usize,
}, },
// Note: len may not equal to slice.len() because for text len is unicode len while the slice
// is utf8 bytes.
InsertText { InsertText {
slice: BytesSlice, slice: BytesSlice,
unicode_start: u32, unicode_start: u32,