From 0ef944fc9d27dc851138b52b14ef385b450d7ee4 Mon Sep 17 00:00:00 2001 From: lauener Date: Fri, 7 Jun 2024 12:01:34 +0200 Subject: [PATCH] Fix some comments --- hash.go | 2 +- internal/test/scheme.go | 2 +- pairing/bn254/curve.go | 2 +- pairing/bn254/gfp12.go | 2 +- pairing/bn254/gfp2.go | 2 +- pairing/bn254/gfp6.go | 2 +- pairing/bn256/curve.go | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/hash.go b/hash.go index 3bfc9c545..f9b99ae14 100644 --- a/hash.go +++ b/hash.go @@ -9,7 +9,7 @@ type HashFactory interface { Hash() hash.Hash } -// HashablePoint is an interface implemented by n +// HashablePoint is an interface implemented by some curves type HashablePoint interface { Hash([]byte) Point } diff --git a/internal/test/scheme.go b/internal/test/scheme.go index ae6fd5449..01ef430aa 100644 --- a/internal/test/scheme.go +++ b/internal/test/scheme.go @@ -40,7 +40,7 @@ func SchemeTesting(t *testing.T, s sign.Scheme) { }) } -// AggregationTesting test an aggrgatable scheme +// AggregationTesting tests an aggregatable scheme func AggregationTesting(t *testing.T, s sign.AggregatableScheme) { t.Run("Aggregation valid", func(tt *testing.T) { msg := []byte("Hello Boneh-Lynn-Shacham") diff --git a/pairing/bn254/curve.go b/pairing/bn254/curve.go index 3b2744d2d..9a6b84cab 100644 --- a/pairing/bn254/curve.go +++ b/pairing/bn254/curve.go @@ -246,7 +246,7 @@ func (c *curvePoint) Neg(a *curvePoint) { c.t = gfP{0} } -// Clone makes a hard copy of the curve point +// Clone makes a deep copy of the curve point func (c *curvePoint) Clone() *curvePoint { n := &curvePoint{} copy(n.x[:], c.x[:]) diff --git a/pairing/bn254/gfp12.go b/pairing/bn254/gfp12.go index 292775ebc..d2988f621 100644 --- a/pairing/bn254/gfp12.go +++ b/pairing/bn254/gfp12.go @@ -159,7 +159,7 @@ func (e *gfP12) Invert(a *gfP12) *gfP12 { return e } -// Clone makes a hard copy of the field +// Clone makes a deep copy of the field func (e *gfP12) Clone() *gfP12 { n := &gfP12{} n.x = e.x.Clone() diff --git a/pairing/bn254/gfp2.go b/pairing/bn254/gfp2.go index eb842ad1a..acf21e1d5 100644 --- a/pairing/bn254/gfp2.go +++ b/pairing/bn254/gfp2.go @@ -155,7 +155,7 @@ func (e *gfP2) Invert(a *gfP2) *gfP2 { return e } -// Clone makes a hard copy of the field +// Clone makes a deep copy of the field func (e *gfP2) Clone() gfP2 { n := gfP2{} copy(n.x[:], e.x[:]) diff --git a/pairing/bn254/gfp6.go b/pairing/bn254/gfp6.go index 758c086b9..d8d80a0c4 100644 --- a/pairing/bn254/gfp6.go +++ b/pairing/bn254/gfp6.go @@ -212,7 +212,7 @@ func (e *gfP6) Invert(a *gfP6) *gfP6 { return e } -// Clone makes a hard copy of the field +// Clone makes a deep copy of the field func (e *gfP6) Clone() gfP6 { n := gfP6{ x: e.x.Clone(), diff --git a/pairing/bn256/curve.go b/pairing/bn256/curve.go index 649a25035..f0f57a10e 100644 --- a/pairing/bn256/curve.go +++ b/pairing/bn256/curve.go @@ -231,7 +231,7 @@ func (c *curvePoint) Neg(a *curvePoint) { c.t = gfP{0} } -// Clone makes a hard copy of the curve point +// Clone makes a deep copy of the curve point func (c *curvePoint) Clone() *curvePoint { n := &curvePoint{} copy(n.x[:], c.x[:])