cmp-testhelper.h 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  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. #ifndef EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_
  19. #define EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_
  20. typedef struct VeryLargeInt VeryLargeInt;
  21. typedef struct VeryLargeIntProduct VeryLargeIntProduct;
  22. typedef struct FpElem FpElem;
  23. typedef struct FqElem FqElem;
  24. typedef struct Fq2Elem Fq2Elem;
  25. typedef struct Fq6Elem Fq6Elem;
  26. typedef struct Fq12Elem Fq12Elem;
  27. typedef struct EccPointFq EccPointFq;
  28. typedef struct EccPointJacobiFq EccPointJacobiFq;
  29. typedef struct EccPointFq2 EccPointFq2;
  30. typedef struct EccPointJacobiFq2 EccPointJacobiFq2;
  31. /// compares VeryLargeInt values
  32. bool operator==(VeryLargeInt const& lhs, VeryLargeInt const& rhs);
  33. bool operator==(VeryLargeIntProduct const& lhs, VeryLargeIntProduct const& rhs);
  34. /// compares FpElem values
  35. bool operator==(FpElem const& lhs, FpElem const& rhs);
  36. /// compares FqElem values
  37. bool operator==(FqElem const& lhs, FqElem const& rhs);
  38. /// compares Fq2Elem values
  39. bool operator==(Fq2Elem const& lhs, Fq2Elem const& rhs);
  40. /// compares Fq6Elem values
  41. bool operator==(Fq6Elem const& lhs, Fq6Elem const& rhs);
  42. /// compares Fq12Elem values
  43. bool operator==(Fq12Elem const& lhs, Fq12Elem const& rhs);
  44. /// compares EccPointFq values
  45. bool operator==(EccPointFq const& lhs, EccPointFq const& rhs);
  46. /// compares EccPointJacobiFq values
  47. bool operator==(EccPointJacobiFq const& lhs, EccPointJacobiFq const& rhs);
  48. /// compares EccPointFq2 values
  49. bool operator==(EccPointFq2 const& lhs, EccPointFq2 const& rhs);
  50. /// compares EccPointJacobiFq2 values
  51. bool operator==(EccPointJacobiFq2 const& lhs, EccPointJacobiFq2 const& rhs);
  52. #endif // EPID_MEMBER_TINY_MATH_UNITTESTS_CMP_TESTHELPER_H_