aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJ08nY2023-10-16 19:02:54 +0200
committerJ08nY2023-10-16 19:02:54 +0200
commit6e33ca6b07dd09f42949c5f9a3f24e2d87c852e8 (patch)
tree27fa943282d2c17a6677f9d747ece8a1e16ff296
parent1b05664444fdaa785b90055d2a235ec81b4e9b0d (diff)
downloadpyecsca-6e33ca6b07dd09f42949c5f9a3f24e2d87c852e8.tar.gz
pyecsca-6e33ca6b07dd09f42949c5f9a3f24e2d87c852e8.tar.zst
pyecsca-6e33ca6b07dd09f42949c5f9a3f24e2d87c852e8.zip
Fix comb mult reprs.
-rw-r--r--pyecsca/ec/mult/comb.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/pyecsca/ec/mult/comb.py b/pyecsca/ec/mult/comb.py
index 8d51806..252abd7 100644
--- a/pyecsca/ec/mult/comb.py
+++ b/pyecsca/ec/mult/comb.py
@@ -60,6 +60,9 @@ class BGMWMultiplier(AccumulatorMultiplier, ScalarMultiplier):
self.direction = direction
self.width = width
+ def __repr__(self):
+ return f"{self.__class__.__name__}({', '.join(map(str, self.formulas.values()))}, short_circuit={self.short_circuit}, width={self.width}, direction={self.direction.name}, accumulation_order={self.accumulation_order.name})"
+
def init(self, params: DomainParameters, point: Point):
with PrecomputationAction(params, point):
super().init(params, point)
@@ -135,6 +138,9 @@ class CombMultiplier(AccumulatorMultiplier, ScalarMultiplier):
)
self.width = width
+ def __repr__(self):
+ return f"{self.__class__.__name__}({', '.join(map(str, self.formulas.values()))}, short_circuit={self.short_circuit}, width={self.width}, accumulation_order={self.accumulation_order.name})"
+
def init(self, params: DomainParameters, point: Point):
with PrecomputationAction(params, point):
super().init(params, point)