diff options
Diffstat (limited to 'src/math/numbertheory')
-rw-r--r-- | src/math/numbertheory/point_gfp.cpp | 10 | ||||
-rw-r--r-- | src/math/numbertheory/point_gfp.h | 11 |
2 files changed, 14 insertions, 7 deletions
diff --git a/src/math/numbertheory/point_gfp.cpp b/src/math/numbertheory/point_gfp.cpp index 90885bc94..fcd6a1f4a 100644 --- a/src/math/numbertheory/point_gfp.cpp +++ b/src/math/numbertheory/point_gfp.cpp @@ -38,6 +38,16 @@ BigInt decompress_point(bool yMod2, } +PointGFp::PointGFp(const CurveGFp& curve) : + curve(curve), coord_x(0), coord_y(1), coord_z(0) + { + } + +PointGFp::PointGFp(const CurveGFp& curve, const BigInt& x, const BigInt& y) : + curve(curve), coord_x(x), coord_y(y), coord_z(1) + { + } + // arithmetic operators PointGFp& PointGFp::operator+=(const PointGFp& rhs) { diff --git a/src/math/numbertheory/point_gfp.h b/src/math/numbertheory/point_gfp.h index 3417c7b7f..b994a4532 100644 --- a/src/math/numbertheory/point_gfp.h +++ b/src/math/numbertheory/point_gfp.h @@ -46,21 +46,18 @@ class BOTAN_DLL PointGFp PointGFp() {} /** - * Construct the point O + * Construct the zero point * @param curve The base curve */ - PointGFp(const CurveGFp& curve) : - curve(curve), coord_x(0), coord_y(1), coord_z(0) {} + PointGFp(const CurveGFp& curve); /** - * Construct a point given its affine coordinates + * Construct a point from its affine coordinates * @param curve the base curve * @param x affine x coordinate * @param y affine y coordinate */ - PointGFp(const CurveGFp& curve, - const BigInt& x, const BigInt& y) : - curve(curve), coord_x(x), coord_y(y), coord_z(1) {} + PointGFp(const CurveGFp& curve, const BigInt& x, const BigInt& y); //PointGFp(const PointGFp& other) = default; //PointGFp& operator=(const PointGFp& other) = default; |