ff-derive-num

Crates.ioff-derive-num
lib.rsff-derive-num
version0.2.0
sourcesrc
created_at2021-06-12 03:30:06.050307
updated_at2022-03-10 19:34:27.369556
descriptionProcedural macro library to add the Num trait to Field implementations for ff
homepagehttps://github.com/kwantam/ff-derive-num
repositoryhttps://github.com/kwantam/ff-derive-num
max_upload_size
id409202
size19,496
Riad S. Wahby (kwantam)

documentation

README

ff-derive-num

This crate provides a derive macro for num-traits::Num and associated traits for ff::Field implementations derived with the ff-derive crate.

example

use ff::PrimeField;         // ff should be used with the "derive" feature!
use ff_derive_num::Num;

#[derive(PrimeField,Num)]
#[PrimeFieldModulus = "70386805592835581672624750593"]
#[PrimeFieldGenerator = "17"]
#[PrimeFieldReprEndianness = "little"]
pub struct Ft([u64; 2]);

license

Copyright 2021 Riad S. Wahby

You may choose either the Apache-2.0 license or the MIT license.

Unless you explicitly state otherwise, any contribution you submit will also be dual-licensed.

Commit count: 7

cargo fmt