#attributes #macro

singleton-attr

Simple to use singleton procedural attribute and derive macro

2 releases

0.1.9 Oct 31, 2024
0.1.8 Aug 23, 2024

#932 in Rust patterns

Download history 15/week @ 2024-12-05 12/week @ 2024-12-12 18/week @ 2025-02-13

1,145 downloads per month

MIT license

7KB
91 lines

singleton-attr

Simple to use singleton procedural attribute

  • singleton-attr Crates.io Version docs.rs
  • singleton-attr-proc-macro Crates.io Version docs.rs

Manual macros give more control over your structure, but derive macros are simpler to use. Check documentation and examples for details.

Dependencies

~190–620KB
~15K SLoC