1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
//! Entry-point macros for [`arty`](https://docs.rs/arty).
//!
//! Enable Arty's `macros` feature and use `#[arty::main]` or `#[arty::test]`.
//! You do not need to depend on this companion crate directly.
//!
//! Both attributes start a runtime, pass its worker capabilities to an
//! async function, and shut down when that function returns. The optional
//! `workers = N` argument caps the runtime's async worker count.
//!
//! The application-facing references are
//! [`arty::main`](https://docs.rs/arty/latest/arty/attr.main.html) and
//! [`arty::test`](https://docs.rs/arty/latest/arty/attr.test.html). They contain
//! runnable examples, configuration syntax, and failure conditions.
use TokenStream;
/// Runs an async entry point on an Arty runtime.
///
/// See [`arty::main`](https://docs.rs/arty/latest/arty/attr.main.html) for the
/// required signature, configuration, examples, and panic behavior.
// Thin proc-macro shim; expansion logic is tested in arty_macros_impl.
/// Runs an async test on an Arty runtime.
///
/// See [`arty::test`](https://docs.rs/arty/latest/arty/attr.test.html) for the
/// required signature, configuration, controlled-time examples, and panic behavior.
// Thin proc-macro shim; expansion logic is tested in arty_macros_impl.