aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/job.rs
diff options
context:
space:
mode:
authorPascal Kuthe2023-02-09 02:24:31 +0000
committerGitHub2023-02-09 02:24:31 +0000
commite474779c8729c36335b76badc98d8211829122d2 (patch)
tree8543a76fca8dfcfe6988e195c6af01b431da3af7 /helix-term/src/job.rs
parentbd14f5a72cec6932cf1792d62e420349eaec60db (diff)
bump msrv to 1.63 (#5570)
* bump msrv to 1.63 * resolve new complex type clippy lints
Diffstat (limited to 'helix-term/src/job.rs')
-rw-r--r--helix-term/src/job.rs7
1 files changed, 5 insertions, 2 deletions
diff --git a/helix-term/src/job.rs b/helix-term/src/job.rs
index 2888b6eb..19f2521a 100644
--- a/helix-term/src/job.rs
+++ b/helix-term/src/job.rs
@@ -5,9 +5,12 @@ use crate::compositor::Compositor;
use futures_util::future::{BoxFuture, Future, FutureExt};
use futures_util::stream::{FuturesUnordered, StreamExt};
+pub type EditorCompositorCallback = Box<dyn FnOnce(&mut Editor, &mut Compositor) + Send>;
+pub type EditorCallback = Box<dyn FnOnce(&mut Editor) + Send>;
+
pub enum Callback {
- EditorCompositor(Box<dyn FnOnce(&mut Editor, &mut Compositor) + Send>),
- Editor(Box<dyn FnOnce(&mut Editor) + Send>),
+ EditorCompositor(EditorCompositorCallback),
+ Editor(EditorCallback),
}
pub type JobFuture = BoxFuture<'static, anyhow::Result<Option<Callback>>>;