From 21a6437eb8b7deff184e72b5d3b1c4d52815e11a Mon Sep 17 00:00:00 2001 From: honzastor Date: Wed, 27 Mar 2024 23:19:40 +0100 Subject: [PATCH] Additional type hint fix. --- ariths_gen/multi_bit_circuits/others/popcount.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ariths_gen/multi_bit_circuits/others/popcount.py b/ariths_gen/multi_bit_circuits/others/popcount.py index cdca327..00e5d79 100644 --- a/ariths_gen/multi_bit_circuits/others/popcount.py +++ b/ariths_gen/multi_bit_circuits/others/popcount.py @@ -1,6 +1,7 @@ """ """ +from typing import Union from ariths_gen.wire_components import ( Wire, @@ -44,7 +45,7 @@ class UnsignedPopCount(GeneralCircuit): """ - def __init__(self, a: Bus, adder : ArithmeticCircuit|None = None, prefix : str = "", name : str = "popcnt", **kwargs): + def __init__(self, a: Bus, adder : Union[ArithmeticCircuit, None] = None, prefix : str = "", name : str = "popcnt", **kwargs): self.N = a.N self.a = a