-
Notifications
You must be signed in to change notification settings - Fork 12
/
NS_snarkfront.hpp
82 lines (66 loc) · 2.56 KB
/
NS_snarkfront.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#ifndef _SNARKFRONT_NS_SNARKFRONT_HPP_
#define _SNARKFRONT_NS_SNARKFRONT_HPP_
#include <istream>
#include <snarkfront/DSL_base.hpp>
#include <snarkfront/DSL_bless.hpp>
namespace snarkfront {
////////////////////////////////////////////////////////////////////////////////
// namespace as type for algorithm template parameter
//
class NS
{
public:
// bless
template <typename T>
static bool bless(T& x, std::istream& is) {
return snarkfront::bless(x, is);
}
// array comparison (imperative)
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint8_x<FR>, N>& x,
const std::array<uint8_x<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint8_x<FR>, N>& x,
const std::array<c_uint8<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<c_uint8<FR>, N>& x,
const std::array<uint8_x<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint32_x<FR>, N>& x,
const std::array<uint32_x<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint32_x<FR>, N>& x,
const std::array<c_uint32<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<c_uint32<FR>, N>& x,
const std::array<uint32_x<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint64_x<FR>, N>& x,
const std::array<uint64_x<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<uint64_x<FR>, N>& x,
const std::array<c_uint64<FR>, N>& y) {
return x != y;
}
template <typename FR, std::size_t N>
static AST_X<Alg_bool<FR>> notequal(const std::array<c_uint64<FR>, N>& x,
const std::array<uint64_x<FR>, N>& y) {
return x != y;
}
};
} // namespace snarkfront
#endif