Skip to content

Instantly share code, notes, and snippets.

@rust-play
Created July 5, 2025 14:25
Show Gist options
  • Save rust-play/bbbf0cd0de977323a1f859029d5d9101 to your computer and use it in GitHub Desktop.
Save rust-play/bbbf0cd0de977323a1f859029d5d9101 to your computer and use it in GitHub Desktop.
Code shared from the Rust Playground
#[tokio::main]
async fn main() {
tokio::spawn(async {
print!("{}", get_string().await);
});
}
async fn get_string() -> String {
String::from("string")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment