summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tokio-macros/src/lib.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/tokio-macros/src/lib.rs b/tokio-macros/src/lib.rs
index 71c61e72..0acfbca5 100644
--- a/tokio-macros/src/lib.rs
+++ b/tokio-macros/src/lib.rs
@@ -35,6 +35,12 @@ use proc_macro::TokenStream;
/// [Builder](../tokio/runtime/struct.Builder.html), which provides a more
/// powerful interface.
///
+/// Note: This macro can be used on any function and not just the `main`
+/// function. Using it on a non-main function makes the function behave
+/// as if it was synchronous by starting a new runtime each time it is called.
+/// If the function is called often, it is preferable to create the runtime using
+/// the runtime builder so the runtime can be reused across calls.
+///
/// # Multi-threaded runtime
///
/// To use the multi-threaded runtime, the macro can be configured using