buffer_diff: Reduce number of entity clones in base_text_buffer (#49573)
Release Notes: - Improved split performance by reducing number of entity clones for very large pre-loaded multibuffers.
This commit is contained in:
1 parent
2409a790ba
commit
0e06137349
4 files changed
+20
-13
No files matched your search
@@ -1978,8 +1978,8 @@ impl BufferDiff {
|
||||
cx.emit(BufferDiffEvent::DiffChanged(change));
|
||||
}
|
||||
|
||||
pub fn base_text_buffer(&self) -> Entity<language::Buffer> {
|
||||
self.inner.base_text.clone()
|
||||
pub fn base_text_buffer(&self) -> &Entity<language::Buffer> {
|
||||
&self.inner.base_text
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user