• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*############################################################################
2 # Copyright 2017 Intel Corporation
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #     http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 ############################################################################*/
16 /// Comparators for tiny math types.
17 /*! \file */
18 
19 #ifndef EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_
20 #define EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_
21 
22 typedef struct VeryLargeInt VeryLargeInt;
23 typedef struct VeryLargeIntProduct VeryLargeIntProduct;
24 typedef struct FpElem FpElem;
25 typedef struct FqElem FqElem;
26 typedef struct Fq2Elem Fq2Elem;
27 typedef struct Fq6Elem Fq6Elem;
28 typedef struct Fq12Elem Fq12Elem;
29 typedef struct EccPointFq EccPointFq;
30 typedef struct EccPointJacobiFq EccPointJacobiFq;
31 typedef struct EccPointFq2 EccPointFq2;
32 typedef struct EccPointJacobiFq2 EccPointJacobiFq2;
33 
34 /// compares VeryLargeInt values
35 bool operator==(VeryLargeInt const& lhs, VeryLargeInt const& rhs);
36 bool operator==(VeryLargeIntProduct const& lhs, VeryLargeIntProduct const& rhs);
37 
38 /// compares FpElem values
39 bool operator==(FpElem const& lhs, FpElem const& rhs);
40 
41 /// compares FqElem values
42 bool operator==(FqElem const& lhs, FqElem const& rhs);
43 
44 /// compares Fq2Elem values
45 bool operator==(Fq2Elem const& lhs, Fq2Elem const& rhs);
46 
47 /// compares Fq6Elem values
48 bool operator==(Fq6Elem const& lhs, Fq6Elem const& rhs);
49 
50 /// compares Fq12Elem values
51 bool operator==(Fq12Elem const& lhs, Fq12Elem const& rhs);
52 
53 /// compares EccPointFq values
54 bool operator==(EccPointFq const& lhs, EccPointFq const& rhs);
55 
56 /// compares EccPointJacobiFq values
57 bool operator==(EccPointJacobiFq const& lhs, EccPointJacobiFq const& rhs);
58 
59 /// compares EccPointFq2 values
60 bool operator==(EccPointFq2 const& lhs, EccPointFq2 const& rhs);
61 
62 /// compares EccPointJacobiFq2 values
63 bool operator==(EccPointJacobiFq2 const& lhs, EccPointJacobiFq2 const& rhs);
64 
65 #endif  // EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_
66