2014-11-15 15:28:10 +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.*
|
|
|
|
**********************************************************************/
|
2013-05-09 15:24:32 +02:00
|
|
|
|
2017-08-26 18:44:21 +03:00
|
|
|
#ifndef SECP256K1_NUM_REPR_H
|
|
|
|
#define SECP256K1_NUM_REPR_H
|
2013-03-10 21:25:19 +01:00
|
|
|
|
|
|
|
#include <gmp.h>
|
|
|
|
|
2013-04-13 17:15:17 +02:00
|
|
|
#define NUM_LIMBS ((256+GMP_NUMB_BITS-1)/GMP_NUMB_BITS)
|
|
|
|
|
2013-03-24 10:38:35 +01:00
|
|
|
typedef struct {
|
2013-04-13 17:15:17 +02:00
|
|
|
mp_limb_t data[2*NUM_LIMBS];
|
|
|
|
int neg;
|
|
|
|
int limbs;
|
2015-09-21 20:57:54 +02:00
|
|
|
} secp256k1_num;
|
2013-03-10 21:25:19 +01:00
|
|
|
|
2017-08-26 18:44:21 +03:00
|
|
|
#endif /* SECP256K1_NUM_REPR_H */
|