mirror of
https://github.com/status-im/eth2.0-specs.git
synced 2025-01-20 23:49:54 +00:00
- return serialized identity points
- result = None initially
This commit is contained in:
parent
309979d778
commit
f3302a3836
@ -135,7 +135,7 @@ def g2_lincomb(points: Sequence[G2Point], scalars: Sequence[BLSFieldElement]) ->
|
|||||||
assert len(points) == len(scalars)
|
assert len(points) == len(scalars)
|
||||||
|
|
||||||
if len(points) == 0:
|
if len(points) == 0:
|
||||||
return bls.Z2()
|
return bls.G2_to_bytes96(bls.Z2())
|
||||||
|
|
||||||
points_g2 = []
|
points_g2 = []
|
||||||
for point in points:
|
for point in points:
|
||||||
|
@ -279,7 +279,7 @@ def g1_lincomb(points: Sequence[KZGCommitment], scalars: Sequence[BLSFieldElemen
|
|||||||
assert len(points) == len(scalars)
|
assert len(points) == len(scalars)
|
||||||
|
|
||||||
if len(points) == 0:
|
if len(points) == 0:
|
||||||
return bls.Z1()
|
return bls.G1_to_bytes48(bls.Z1())
|
||||||
|
|
||||||
points_g1 = []
|
points_g1 = []
|
||||||
for point in points:
|
for point in points:
|
||||||
|
@ -251,7 +251,7 @@ def multi_exp(points, integers):
|
|||||||
else:
|
else:
|
||||||
raise Exception("Invalid point type")
|
raise Exception("Invalid point type")
|
||||||
|
|
||||||
result = Z1()
|
result = None
|
||||||
if isinstance(points[0], py_ecc_G1):
|
if isinstance(points[0], py_ecc_G1):
|
||||||
result = Z1()
|
result = Z1()
|
||||||
elif isinstance(points[0], py_ecc_G2):
|
elif isinstance(points[0], py_ecc_G2):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user