2015-04-07 10:13:37 +00:00
|
|
|
/**********************************************************************
|
|
|
|
* Copyright (c) 2013, 2014 Pieter Wuille *
|
|
|
|
* Distributed under the MIT software license, see the accompanying *
|
|
|
|
* file COPYING or http://www.opensource.org/licenses/mit-license.php.*
|
|
|
|
**********************************************************************/
|
2015-01-21 23:35:00 +00:00
|
|
|
|
|
|
|
#ifndef _SECP256K1_NUM_REPR_
|
|
|
|
#define _SECP256K1_NUM_REPR_
|
|
|
|
|
|
|
|
#include <gmp.h>
|
|
|
|
|
|
|
|
#define NUM_LIMBS ((256+GMP_NUMB_BITS-1)/GMP_NUMB_BITS)
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
mp_limb_t data[2*NUM_LIMBS];
|
|
|
|
int neg;
|
|
|
|
int limbs;
|
2015-09-28 15:46:17 +00:00
|
|
|
} secp256k1_num;
|
2015-01-21 23:35:00 +00:00
|
|
|
|
|
|
|
#endif
|