diff --git a/pysetup/spec_builders/deneb.py b/pysetup/spec_builders/deneb.py index e1ad05184..dc3c17583 100644 --- a/pysetup/spec_builders/deneb.py +++ b/pysetup/spec_builders/deneb.py @@ -17,6 +17,7 @@ from eth2spec.capella import {preset_name} as capella def preparations(cls): return ''' T = TypeVar('T') # For generic function +TPoint = TypeVar('TPoint') # For generic function. G1 or G2 point. ''' @classmethod diff --git a/specs/deneb/polynomial-commitments.md b/specs/deneb/polynomial-commitments.md index a740ca7ef..5f7edb455 100644 --- a/specs/deneb/polynomial-commitments.md +++ b/specs/deneb/polynomial-commitments.md @@ -153,8 +153,8 @@ def bit_reversal_permutation(sequence: Sequence[T]) -> Sequence[T]: This function performs a multi-scalar multiplication between `points` and `integers`. `points` can either be in G1 or G2. ```python -def multi_exp(points: PyUnion[Sequence[G1Point], Sequence[G2Point]], - integers: Sequence[uint64]) -> PyUnion[Sequence[G1Point], Sequence[G2Point]]: +def multi_exp(points: Sequence[TPoint], + integers: Sequence[uint64]) -> Sequence[TPoint]: # pylint: disable=unused-argument ... ```