This causes the background executor to hang Release Notes: - N/A *or* Added/Fixed/Improved ...
This commit is contained in:
@@ -170,10 +170,7 @@ impl CommitView {
|
||||
ReplicaId::LOCAL,
|
||||
cx.entity_id().as_non_zero_u64().into(),
|
||||
LineEnding::default(),
|
||||
Rope::from_str(
|
||||
&format_commit(&commit, stash.is_some()),
|
||||
cx.background_executor(),
|
||||
),
|
||||
format_commit(&commit, stash.is_some()).into(),
|
||||
);
|
||||
metadata_buffer_id = Some(buffer.remote_id());
|
||||
Buffer::build(buffer, Some(file.clone()), Capability::ReadWrite)
|
||||
@@ -339,7 +336,7 @@ async fn build_buffer(
|
||||
) -> Result<Entity<Buffer>> {
|
||||
let line_ending = LineEnding::detect(&text);
|
||||
LineEnding::normalize(&mut text);
|
||||
let text = Rope::from_str(&text, cx.background_executor());
|
||||
let text = Rope::from(text);
|
||||
let language = cx.update(|cx| language_registry.language_for_file(&blob, Some(&text), cx))?;
|
||||
let language = if let Some(language) = language {
|
||||
language_registry
|
||||
@@ -379,7 +376,7 @@ async fn build_buffer_diff(
|
||||
let base_buffer = cx
|
||||
.update(|cx| {
|
||||
Buffer::build_snapshot(
|
||||
Rope::from_str(old_text.as_deref().unwrap_or(""), cx.background_executor()),
|
||||
old_text.as_deref().unwrap_or("").into(),
|
||||
buffer.language().cloned(),
|
||||
Some(language_registry.clone()),
|
||||
cx,
|
||||
|
||||
Reference in New Issue
Block a user