graph-derive 0.0.1

#[derive(Graph)] for graph-theory crate
Documentation
// #![deny(missing_debug_implementations, missing_copy_implementations)]
// #![warn(missing_docs, rustdoc::missing_crate_level_docs)]
#![doc = include_str ! ("../readme.md")]
#![doc(html_logo_url = "https://raw.githubusercontent.com/oovm/shape-rs/dev/projects/images/Trapezohedron.svg")]
#![doc(html_favicon_url = "https://raw.githubusercontent.com/oovm/shape-rs/dev/projects/images/Trapezohedron.svg")]

extern crate proc_macro;

mod derive_graph;

use crate::derive_graph::GraphDerive;

use proc_macro::TokenStream;
use quote::ToTokens;
use syn::parse_macro_input;

pub(crate) mod utils;

/// Derive the `Graph` trait for a struct.
#[proc_macro_derive(Graph, attributes(graph, easy_graph))]
pub fn derive_graph(input: TokenStream) -> TokenStream {
    let input = parse_macro_input!(input as GraphDerive);
    TokenStream::from(ToTokens::to_token_stream(&input))
}