#rand #macros #macro #derive #trait #random

nightly rand_macros

#[derive]-like functionality for the rand::Rand trait

10 releases

Uses old Rust 2015

0.1.10 Dec 19, 2015
0.1.9 Aug 31, 2015
0.1.8 May 25, 2015
0.1.6 Apr 18, 2015
0.1.4 Feb 19, 2015
Download history 92/week @ 2022-08-14 89/week @ 2022-08-21 76/week @ 2022-08-28 83/week @ 2022-09-04 93/week @ 2022-09-11 87/week @ 2022-09-18 80/week @ 2022-09-25 92/week @ 2022-10-02 84/week @ 2022-10-09 77/week @ 2022-10-16 82/week @ 2022-10-23 87/week @ 2022-10-30 88/week @ 2022-11-06 82/week @ 2022-11-13 88/week @ 2022-11-20 76/week @ 2022-11-27

346 downloads per month

MIT/Apache

8KB
148 lines

#[derive]-like functionality for the rand::Rand trait.

Example

#![feature(plugin)]

#![plugin(rand_macros)]

extern crate rand;

#[derive_Rand]
struct Foo {
    x: u8,
    y: isize
}

#[derive_Rand]
enum Bar {
    X(char),
    Y(f64)
}

No runtime deps