Logo
Explore Help
Sign In
frost/bdk
3
0
Fork 0
You've already forked bdk
Code Issues Pull Requests Actions Packages Projects Releases Wiki Activity
bdk/macros/Cargo.toml

16 lines
346 B
TOML
Raw Normal View History

Make the blockchain interface async again on wasm32-unknown-unknown The procedural macro `#[maybe_async]` makes a method or every method of a trait "async" whenever the target_arch is `wasm32`, and leaves them untouched on every other platform. The macro `maybe_await!($e:expr)` can be used to call `maybe_async` methods on multi-platform code: it expands to `$e` on non-wasm32 platforms and to `$e.await` on wasm32. The macro `await_or_block!($e:expr)` can be used to contain async code as much as possible: it expands to `tokio::runtime::Runtime::new().unwrap().block_on($e)` on non-wasm32 platforms, and to `$e.await` on wasm32.
2020-07-20 15:51:57 +02:00
[package]
name = "magical-macros"
version = "0.1.0"
authors = ["Alekos Filini <alekos.filini@gmail.com>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
syn = { version = "1.0", features = ["parsing"] }
proc-macro2 = "1.0"
quote = "1.0"
[lib]
proc-macro = true
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.5 Page: 202ms Template: 5ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API