aboutsummaryrefslogtreecommitdiff
path: root/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib.rs b/src/lib.rs
index e35dd03..435d508 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -12,11 +12,12 @@
//! Rust 1.39 did not include support for async fn in traits. Trying to include
//! an async fn in a trait produces the following error:
//!
-//! ```compile_fail
+#![cfg_attr(not(native_async_fn_in_trait), doc = "```compile_fail")]
+#![cfg_attr(native_async_fn_in_trait, doc = "```")]
//! trait MyTrait {
//! async fn f() {}
//! }
-//! ```
+#![doc = "```"]
//!
//! ```text
//! error[E0706]: trait fns cannot be declared `async`
@@ -303,7 +304,7 @@
//! let object = &value as &dyn ObjectSafe;
//! ```
-#![doc(html_root_url = "https://docs.rs/async-trait/0.1.73")]
+#![doc(html_root_url = "https://docs.rs/async-trait/0.1.74")]
#![allow(
clippy::default_trait_access,
clippy::doc_markdown,