hydroflow_plus 0.10.0

Functional programming API for hydroflow
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use proc_macro2::{Span, TokenStream};
use quote::quote;

pub fn get_this_crate() -> TokenStream {
    let hydroflow_crate = proc_macro_crate::crate_name("hydroflow_plus")
        .expect("hydroflow_plus should be present in `Cargo.toml`");
    match hydroflow_crate {
        proc_macro_crate::FoundCrate::Itself => quote! { hydroflow_plus },
        proc_macro_crate::FoundCrate::Name(name) => {
            let ident = syn::Ident::new(&name, Span::call_site());
            quote! { #ident }
        }
    }
}