10 releases

0.2.2 Feb 5, 2020
0.2.1 Feb 12, 2019
0.2.0 Jan 30, 2019
0.1.6 Oct 17, 2018
0.1.3 Mar 15, 2017

#54 in #deriving

Download history 939/week @ 2024-08-08 918/week @ 2024-08-15 1135/week @ 2024-08-22 1608/week @ 2024-08-29 1338/week @ 2024-09-05 1320/week @ 2024-09-12 1184/week @ 2024-09-19 509/week @ 2024-09-26 675/week @ 2024-10-03 214/week @ 2024-10-10 548/week @ 2024-10-17 794/week @ 2024-10-24 1219/week @ 2024-10-31 1494/week @ 2024-11-07 586/week @ 2024-11-14 567/week @ 2024-11-21

3,932 downloads per month
Used in 2 crates

MIT/Apache

5KB
74 lines

named_type

crates.io docs.rs CircleCI

This is a small Rust procedural macro that lets you get the name of a type, whether it is an enum or a struct. By simply deriving the trait on your type, you can automatically add a function to return the name of the type.

WARNING: This package is deprecated, because Rust now provides this by default via std::any::typename.


lib.rs:

This crate provides support for deriving the NamedType trait from the named_type crate. See that crate for further documentation.

Dependencies

~1.5MB
~37K SLoC