summaryrefslogtreecommitdiffstats
path: root/third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs')
-rw-r--r--third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs15
1 files changed, 15 insertions, 0 deletions
diff --git a/third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs b/third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs
new file mode 100644
index 0000000000..56fea7a1f8
--- /dev/null
+++ b/third_party/rust/async-trait/tests/ui/missing-async-in-trait.rs
@@ -0,0 +1,15 @@
+use async_trait::async_trait;
+
+#[async_trait]
+pub trait Trait {
+ fn method();
+}
+
+pub struct Struct;
+
+#[async_trait]
+impl Trait for Struct {
+ async fn method() {}
+}
+
+fn main() {}