Skip to content

Commit

Permalink
Fix clippy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Finomnis committed Apr 13, 2024
1 parent dbf1747 commit ba21124
Showing 1 changed file with 16 additions and 22 deletions.
38 changes: 16 additions & 22 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -266,19 +266,15 @@ where
/// }
/// }
///
/// fn main() {
/// // Make a new struct
/// let mut demo = Demo { lol: 100 };
/// // Make a new struct
/// let mut demo = Demo { lol: 100 };
///
/// // Call the entry point future, and pin it
/// let x = core::pin::pin!(demo.entry());
/// // Call the entry point future, and pin it
/// let x = core::pin::pin!(demo.entry());
///
/// // Give the pinned future to Cassette
/// // for execution
/// let mut cm = Cassette::new(x);
///
/// /* ... */
/// }
/// // Give the pinned future to Cassette
/// // for execution
/// let mut cm = Cassette::new(x);
/// ```
pub fn new(thing: T) -> Self {
let raw_waker = noop_raw_waker();
Expand Down Expand Up @@ -312,20 +308,18 @@ where
/// }
/// }
///
/// fn main() {
/// // Make a new struct
/// let mut demo = Demo { lol: 100 };
/// // Make a new struct
/// let mut demo = Demo { lol: 100 };
///
/// // Call the entry point future, and pin it
/// let x = core::pin::pin!(demo.entry());
/// // Call the entry point future, and pin it
/// let x = core::pin::pin!(demo.entry());
///
/// // Give the pinned future to Cassette
/// // for execution
/// let mut cm = Cassette::new(x);
/// // Give the pinned future to Cassette
/// // for execution
/// let mut cm = Cassette::new(x);
///
/// while cm.poll_on().is_none() { }
/// println!("Future done!");
/// }
/// while cm.poll_on().is_none() { }
/// println!("Future done!");
/// ```
//
// TODO: try_poll_on where an error is returned
Expand Down

0 comments on commit ba21124

Please sign in to comment.