File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -111,14 +111,19 @@ pub struct Patches {
111111 indices : ArrayRef ,
112112 values : ArrayRef ,
113113 /// Stores the patch index offset for each chunk.
114+ ///
115+ /// This allows us to lookup the patches for a given chunk in constant time via
116+ /// `patch_indices[chunk_offsets[i]..chunk_offsets[i+1]]`.
117+ ///
118+ /// This is optional for compatibility reasons.
114119 chunk_offsets : Option < ArrayRef > ,
115120 /// Chunk offsets are only sliced off in case the slice is fully
116121 /// outside of the chunk range.
117122 ///
118123 /// Though the range for indices and values is sliced in terms of
119124 /// individual elements, not chunks. To account for that we do a
120125 /// saturating sub when adjusting the indices based on the chunk offset.
121- //
126+ ///
122127 /// `offset_within_chunk` is necessary in order to keep track of how many
123128 /// elements were sliced off within the chunk.
124129 offset_within_chunk : Option < usize > ,
You can’t perform that action at this time.
0 commit comments