mirror of https://github.com/gtank/ristretto255
internal/radix51: remove unused (and a bit broken) SetInt
It would return an invalid element if the input was greater than 2^54 - 1.
This commit is contained in:
parent
22cdf749a2
commit
010995eaa9
|
@ -48,16 +48,6 @@ func (v *FieldElement) One() *FieldElement {
|
|||
return v
|
||||
}
|
||||
|
||||
// SetInt sets the receiving FieldElement to the specified small integer.
|
||||
func (v *FieldElement) SetInt(x uint64) *FieldElement {
|
||||
v[0] = x
|
||||
v[1] = 0
|
||||
v[2] = 0
|
||||
v[3] = 0
|
||||
v[4] = 0
|
||||
return v
|
||||
}
|
||||
|
||||
func (v *FieldElement) Reduce(u *FieldElement) *FieldElement {
|
||||
v.Set(u)
|
||||
|
||||
|
|
Loading…
Reference in New Issue