Skip to content

Commit 1352290

Browse files
authored
Merge pull request #9 from popoffka/sort-includes
Ensure everything compiles individually & sort includes
2 parents 0f264a2 + 95c05af commit 1352290

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+109
-61
lines changed

libff/algebra/curves/alt_bn128/alt_bn128_g1.hpp

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#ifndef ALT_BN128_G1_HPP_
99
#define ALT_BN128_G1_HPP_
1010
#include <vector>
11+
1112
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1213
#include <libff/algebra/curves/curve_utils.hpp>
1314

libff/algebra/curves/alt_bn128/alt_bn128_g2.hpp

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#ifndef ALT_BN128_G2_HPP_
99
#define ALT_BN128_G2_HPP_
1010
#include <vector>
11+
1112
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1213
#include <libff/algebra/curves/curve_utils.hpp>
1314

libff/algebra/curves/alt_bn128/alt_bn128_init.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
77

8-
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
98
#include <libff/algebra/curves/alt_bn128/alt_bn128_g1.hpp>
109
#include <libff/algebra/curves/alt_bn128/alt_bn128_g2.hpp>
10+
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1111

1212
namespace libff {
1313

libff/algebra/curves/alt_bn128/alt_bn128_init.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
#define ALT_BN128_INIT_HPP_
1010
#include <libff/algebra/curves/public_params.hpp>
1111
#include <libff/algebra/fields/fp.hpp>
12+
#include <libff/algebra/fields/fp12_2over3over2.hpp>
1213
#include <libff/algebra/fields/fp2.hpp>
1314
#include <libff/algebra/fields/fp6_3over2.hpp>
14-
#include <libff/algebra/fields/fp12_2over3over2.hpp>
1515

1616
namespace libff {
1717

libff/algebra/curves/alt_bn128/alt_bn128_pairing.cpp

+4-3
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
77

8-
#include <libff/algebra/curves/alt_bn128/alt_bn128_pairing.hpp>
9-
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
8+
#include <cassert>
9+
1010
#include <libff/algebra/curves/alt_bn128/alt_bn128_g1.hpp>
1111
#include <libff/algebra/curves/alt_bn128/alt_bn128_g2.hpp>
12-
#include <cassert>
12+
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
13+
#include <libff/algebra/curves/alt_bn128/alt_bn128_pairing.hpp>
1314
#include <libff/common/profiling.hpp>
1415

1516
namespace libff {

libff/algebra/curves/alt_bn128/alt_bn128_pairing.hpp

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#ifndef ALT_BN128_PAIRING_HPP_
99
#define ALT_BN128_PAIRING_HPP_
1010
#include <vector>
11+
1112
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1213

1314
namespace libff {

libff/algebra/curves/alt_bn128/alt_bn128_pp.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77

88
#ifndef ALT_BN128_PP_HPP_
99
#define ALT_BN128_PP_HPP_
10-
#include <libff/algebra/curves/public_params.hpp>
11-
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1210
#include <libff/algebra/curves/alt_bn128/alt_bn128_g1.hpp>
1311
#include <libff/algebra/curves/alt_bn128/alt_bn128_g2.hpp>
12+
#include <libff/algebra/curves/alt_bn128/alt_bn128_init.hpp>
1413
#include <libff/algebra/curves/alt_bn128/alt_bn128_pairing.hpp>
14+
#include <libff/algebra/curves/public_params.hpp>
1515

1616
namespace libff {
1717

libff/algebra/curves/bn128/bn128_g1.hpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@
88
#ifndef BN128_G1_HPP_
99
#define BN128_G1_HPP_
1010
#include <vector>
11+
12+
#include "third_party/ate-pairing/include/bn.h"
13+
1114
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1215
#include <libff/algebra/curves/curve_utils.hpp>
13-
#include "third_party/ate-pairing/include/bn.h"
1416

1517
namespace libff {
1618

libff/algebra/curves/bn128/bn128_g2.hpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,11 @@
99
#define BN128_G2_HPP_
1010
#include <iostream>
1111
#include <vector>
12+
13+
#include "third_party/ate-pairing/include/bn.h"
14+
1215
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1316
#include <libff/algebra/curves/curve_utils.hpp>
14-
#include "third_party/ate-pairing/include/bn.h"
1517

1618
namespace libff {
1719

libff/algebra/curves/bn128/bn128_gt.hpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,13 @@
77

88
#ifndef BN128_GT_HPP_
99
#define BN128_GT_HPP_
10-
#include <libff/algebra/fields/fp.hpp>
11-
#include <libff/algebra/fields/field_utils.hpp>
1210
#include <iostream>
11+
1312
#include "third_party/ate-pairing/include/bn.h"
1413

14+
#include <libff/algebra/fields/field_utils.hpp>
15+
#include <libff/algebra/fields/fp.hpp>
16+
1517
namespace libff {
1618

1719
class bn128_GT;

libff/algebra/curves/bn128/bn128_init.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
77

8-
#include <libff/algebra/curves/bn128/bn128_init.hpp>
98
#include <libff/algebra/curves/bn128/bn128_g1.hpp>
109
#include <libff/algebra/curves/bn128/bn128_g2.hpp>
1110
#include <libff/algebra/curves/bn128/bn128_gt.hpp>
11+
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1212

1313
namespace libff {
1414

libff/algebra/curves/bn128/bn128_init.hpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@
77

88
#ifndef BN128_INIT_HPP_
99
#define BN128_INIT_HPP_
10+
#include "third_party/ate-pairing/include/bn.h"
11+
1012
#include <libff/algebra/curves/public_params.hpp>
1113
#include <libff/algebra/fields/fp.hpp>
12-
#include "third_party/ate-pairing/include/bn.h"
1314

1415
namespace libff {
1516

libff/algebra/curves/bn128/bn128_pairing.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@
1010

1111
#include <sstream>
1212

13-
#include <libff/algebra/curves/bn128/bn128_pairing.hpp>
14-
#include <libff/common/profiling.hpp>
15-
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1613
#include <libff/algebra/curves/bn128/bn128_g1.hpp>
1714
#include <libff/algebra/curves/bn128/bn128_g2.hpp>
1815
#include <libff/algebra/curves/bn128/bn128_gt.hpp>
16+
#include <libff/algebra/curves/bn128/bn128_init.hpp>
17+
#include <libff/algebra/curves/bn128/bn128_pairing.hpp>
18+
#include <libff/common/profiling.hpp>
1919

2020
namespace libff {
2121

libff/algebra/curves/bn128/bn128_pairing.hpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@
1010

1111
#ifndef BN128_PAIRING_HPP_
1212
#define BN128_PAIRING_HPP_
13+
#include "third_party/ate-pairing/include/bn.h"
14+
1315
#include <libff/algebra/curves/bn128/bn128_g1.hpp>
1416
#include <libff/algebra/curves/bn128/bn128_g2.hpp>
1517
#include <libff/algebra/curves/bn128/bn128_gt.hpp>
16-
#include "third_party/ate-pairing/include/bn.h"
1718

1819
namespace libff {
1920

libff/algebra/curves/bn128/bn128_pp.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@
77

88
#ifndef BN128_PP_HPP_
99
#define BN128_PP_HPP_
10-
#include <libff/algebra/curves/public_params.hpp>
11-
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1210
#include <libff/algebra/curves/bn128/bn128_g1.hpp>
1311
#include <libff/algebra/curves/bn128/bn128_g2.hpp>
1412
#include <libff/algebra/curves/bn128/bn128_gt.hpp>
13+
#include <libff/algebra/curves/bn128/bn128_init.hpp>
1514
#include <libff/algebra/curves/bn128/bn128_pairing.hpp>
15+
#include <libff/algebra/curves/public_params.hpp>
1616

1717
namespace libff {
1818

libff/algebra/curves/bn128/bn_utils.hpp

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#ifndef BN_UTILS_HPP_
99
#define BN_UTILS_HPP_
1010
#include <vector>
11+
1112
#include "third_party/ate-pairing/include/bn.h"
1213

1314
namespace libff {

libff/algebra/curves/edwards/edwards_g1.hpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@
88
#ifndef EDWARDS_G1_HPP_
99
#define EDWARDS_G1_HPP_
1010
#include <vector>
11-
#include <libff/algebra/curves/edwards/edwards_init.hpp>
11+
1212
#include <libff/algebra/curves/curve_utils.hpp>
13+
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1314

1415
namespace libff {
1516

libff/algebra/curves/edwards/edwards_g2.hpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@
99
#define EDWARDS_G2_HPP_
1010
#include <iostream>
1111
#include <vector>
12-
#include <libff/algebra/curves/edwards/edwards_init.hpp>
12+
1313
#include <libff/algebra/curves/curve_utils.hpp>
14+
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1415

1516
namespace libff {
1617

libff/algebra/curves/edwards/edwards_init.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
77

8-
#include <libff/algebra/curves/edwards/edwards_init.hpp>
98
#include <libff/algebra/curves/edwards/edwards_g1.hpp>
109
#include <libff/algebra/curves/edwards/edwards_g2.hpp>
10+
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1111

1212
namespace libff {
1313

libff/algebra/curves/edwards/edwards_pairing.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
77

8-
#include <libff/algebra/curves/edwards/edwards_pairing.hpp>
9-
#include <libff/algebra/curves/edwards/edwards_init.hpp>
108
#include <cassert>
9+
1110
#include <libff/algebra/curves/edwards/edwards_g1.hpp>
1211
#include <libff/algebra/curves/edwards/edwards_g2.hpp>
12+
#include <libff/algebra/curves/edwards/edwards_init.hpp>
13+
#include <libff/algebra/curves/edwards/edwards_pairing.hpp>
1314
#include <libff/common/profiling.hpp>
1415

1516
namespace libff {

libff/algebra/curves/edwards/edwards_pairing.hpp

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#ifndef EDWARDS_PAIRING_HPP_
99
#define EDWARDS_PAIRING_HPP_
1010
#include <vector>
11+
1112
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1213

1314
namespace libff {

libff/algebra/curves/edwards/edwards_pp.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77

88
#ifndef EDWARDS_PP_HPP_
99
#define EDWARDS_PP_HPP_
10-
#include <libff/algebra/curves/public_params.hpp>
11-
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1210
#include <libff/algebra/curves/edwards/edwards_g1.hpp>
1311
#include <libff/algebra/curves/edwards/edwards_g2.hpp>
12+
#include <libff/algebra/curves/edwards/edwards_init.hpp>
1413
#include <libff/algebra/curves/edwards/edwards_pairing.hpp>
14+
#include <libff/algebra/curves/public_params.hpp>
1515

1616
namespace libff {
1717

libff/algebra/curves/mnt/mnt4/mnt4_init.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
* @copyright MIT license (see LICENSE file)
1212
*****************************************************************************/
1313

14-
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
1514
#include <libff/algebra/curves/mnt/mnt4/mnt4_g1.hpp>
1615
#include <libff/algebra/curves/mnt/mnt4/mnt4_g2.hpp>
16+
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
1717

1818
namespace libff {
1919

libff/algebra/curves/mnt/mnt4/mnt4_init.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
#ifndef MNT4_INIT_HPP_
1313
#define MNT4_INIT_HPP_
1414

15-
#include <libff/algebra/curves/public_params.hpp>
1615
#include <libff/algebra/curves/mnt/mnt46_common.hpp>
16+
#include <libff/algebra/curves/public_params.hpp>
1717
#include <libff/algebra/fields/fp.hpp>
1818
#include <libff/algebra/fields/fp2.hpp>
1919
#include <libff/algebra/fields/fp4.hpp>

libff/algebra/curves/mnt/mnt4/mnt4_pairing.cpp

+2-3
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@
1313

1414
#include <cassert>
1515

16-
#include <libff/algebra/curves/mnt/mnt4/mnt4_pairing.hpp>
17-
18-
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
1916
#include <libff/algebra/curves/mnt/mnt4/mnt4_g1.hpp>
2017
#include <libff/algebra/curves/mnt/mnt4/mnt4_g2.hpp>
18+
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
19+
#include <libff/algebra/curves/mnt/mnt4/mnt4_pairing.hpp>
2120
#include <libff/algebra/scalar_multiplication/wnaf.hpp>
2221
#include <libff/common/profiling.hpp>
2322

libff/algebra/curves/mnt/mnt4/mnt4_pp.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
#ifndef MNT4_PP_HPP_
1313
#define MNT4_PP_HPP_
1414

15-
#include <libff/algebra/curves/public_params.hpp>
16-
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
1715
#include <libff/algebra/curves/mnt/mnt4/mnt4_g1.hpp>
1816
#include <libff/algebra/curves/mnt/mnt4/mnt4_g2.hpp>
17+
#include <libff/algebra/curves/mnt/mnt4/mnt4_init.hpp>
1918
#include <libff/algebra/curves/mnt/mnt4/mnt4_pairing.hpp>
19+
#include <libff/algebra/curves/public_params.hpp>
2020

2121
namespace libff {
2222

libff/algebra/curves/mnt/mnt6/mnt6_init.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
* @copyright MIT license (see LICENSE file)
1212
*****************************************************************************/
1313

14-
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
1514
#include <libff/algebra/curves/mnt/mnt6/mnt6_g1.hpp>
1615
#include <libff/algebra/curves/mnt/mnt6/mnt6_g2.hpp>
16+
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
1717

1818
namespace libff {
1919

libff/algebra/curves/mnt/mnt6/mnt6_init.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
#ifndef MNT6_INIT_HPP_
1313
#define MNT6_INIT_HPP_
1414

15-
#include <libff/algebra/curves/public_params.hpp>
1615
#include <libff/algebra/curves/mnt/mnt46_common.hpp>
16+
#include <libff/algebra/curves/public_params.hpp>
1717
#include <libff/algebra/fields/fp.hpp>
1818
#include <libff/algebra/fields/fp3.hpp>
1919
#include <libff/algebra/fields/fp6_2over3.hpp>

libff/algebra/curves/mnt/mnt6/mnt6_pairing.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313

1414
#include <cassert>
1515

16-
#include <libff/algebra/curves/mnt/mnt6/mnt6_pairing.hpp>
17-
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
1816
#include <libff/algebra/curves/mnt/mnt6/mnt6_g1.hpp>
1917
#include <libff/algebra/curves/mnt/mnt6/mnt6_g2.hpp>
18+
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
19+
#include <libff/algebra/curves/mnt/mnt6/mnt6_pairing.hpp>
2020
#include <libff/algebra/scalar_multiplication/wnaf.hpp>
2121
#include <libff/common/profiling.hpp>
2222

libff/algebra/curves/mnt/mnt6/mnt6_pp.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
#ifndef MNT6_PP_HPP_
1313
#define MNT6_PP_HPP_
1414

15-
#include <libff/algebra/curves/public_params.hpp>
16-
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
1715
#include <libff/algebra/curves/mnt/mnt6/mnt6_g1.hpp>
1816
#include <libff/algebra/curves/mnt/mnt6/mnt6_g2.hpp>
17+
#include <libff/algebra/curves/mnt/mnt6/mnt6_init.hpp>
1918
#include <libff/algebra/curves/mnt/mnt6/mnt6_pairing.hpp>
19+
#include <libff/algebra/curves/public_params.hpp>
2020

2121
namespace libff {
2222

libff/algebra/curves/tests/test_bilinearity.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
* and contributors (see AUTHORS).
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
7-
#include <libff/common/profiling.hpp>
87
#include <libff/algebra/curves/edwards/edwards_pp.hpp>
8+
#include <libff/common/profiling.hpp>
99
#ifdef CURVE_BN128
1010
#include <libff/algebra/curves/bn128/bn128_pp.hpp>
1111
#endif

libff/algebra/curves/tests/test_groups.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,17 @@
44
* and contributors (see AUTHORS).
55
* @copyright MIT license (see LICENSE file)
66
*****************************************************************************/
7-
#include <libff/common/profiling.hpp>
87
#include <libff/algebra/curves/edwards/edwards_pp.hpp>
98
#include <libff/algebra/curves/mnt/mnt4/mnt4_pp.hpp>
109
#include <libff/algebra/curves/mnt/mnt6/mnt6_pp.hpp>
10+
#include <libff/common/profiling.hpp>
1111
#ifdef CURVE_BN128
1212
#include <libff/algebra/curves/bn128/bn128_pp.hpp>
1313
#endif
14-
#include <libff/algebra/curves/alt_bn128/alt_bn128_pp.hpp>
1514
#include <sstream>
1615

16+
#include <libff/algebra/curves/alt_bn128/alt_bn128_pp.hpp>
17+
1718
using namespace libff;
1819

1920
template<typename GroupT>

0 commit comments

Comments
 (0)