rewrite proc macros, add block

Changed files
+22 -2
futures
+1
futures/result
··· 1 + /nix/store/yzi2mlj92m2pqix3zv5lq3v1xryjpq19-rust-workspace-unknown
+21 -2
futures/src/lib.rs
··· 1 1 #![no_std] 2 2 3 3 pub use futures_combinators; 4 + use futures_compat::{ScopedFutureWrapper, UnscopedFutureWrapper}; 4 5 pub use futures_core; 6 + use futures_core::ScopedFuture; 5 7 pub use futures_derive::async_scoped; 6 8 pub use futures_util; 7 9 8 10 async fn evil() {} 9 11 10 12 #[async_scoped] 11 - fn test<'a>(a: i32, b: &i32) { 12 - // evil().await 13 + fn inner(a: i32, b: &i32) -> i32 { 14 + // evil().await; 15 + 1 16 + } 17 + 18 + #[async_scoped] 19 + fn test(a: i32, b: &i32) -> () { 20 + // evil().await; 21 + let x = inner(a, &b).await; 22 + // async {}.await; 23 + 24 + let test_block = futures_derive::block! { 1 + 1; 2 }.await; 25 + 26 + // let test_closure = futures_derive::closure! { |&ab, &cd| ab + cd }; 27 + 28 + // let asdf = futures_derive::closure! { |a: &i32| { 29 + // *a + b 30 + // }}; 31 + // let x = asdf(&a).await; 13 32 } 14 33 15 34 fn test2<'a>(a: i32) {}