提交 3c33eefc authored 作者: Serhij S's avatar Serhij S

doc fixes

上级 c25bf26c
......@@ -26,7 +26,7 @@ impl<T> Supervisor<T> {
Self::default()
}
/// Spawns a new task using a [`Builder`] object and registers it. The task name MUST be unique
/// and SHOULD be 16 characters or less to set a proper thread name
/// and SHOULD be 15 characters or less to set a proper thread name
pub fn spawn<F, B>(&mut self, builder: B, f: F) -> Result<&Task<T>>
where
B: Into<Builder>,
......@@ -39,7 +39,7 @@ impl<T> Supervisor<T> {
Ok(entry.insert(task))
}
/// Spawns a new periodic task using a [`Builder`] object and registers it. The task name MUST
/// be unique and SHOULD be 16 characters or less to set a proper thread name
/// be unique and SHOULD be 15 characters or less to set a proper thread name
pub fn spawn_periodic<F, B>(&mut self, builder: B, f: F, interval: Interval) -> Result<&Task<T>>
where
F: Fn() -> T + Send + 'static,
......
......@@ -79,7 +79,7 @@ impl Builder {
pub fn new() -> Self {
Self::default()
}
/// The task name SHOULD be 16 characters or less to set a proper thread name
/// The task name SHOULD be 15 characters or less to set a proper thread name
pub fn name<N: fmt::Display>(mut self, name: N) -> Self {
self.name = Some(name.to_string());
self
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论