Let us walk on the 3-isogeny graph
Loading...
Searching...
No Matches
HashErrors Class Reference
Inheritance diagram for HashErrors:
Collaboration diagram for HashErrors:

Public Member Functions

None __init__ (self)
 
None append (self, "HashError" error)
 
str __str__ (self)
 
bool __bool__ (self)
 

Data Fields

 errors
 
 head
 

Detailed Description

Multiple HashError instances rolled into one for reporting

Definition at line 424 of file exceptions.py.

Constructor & Destructor Documentation

◆ __init__()

None __init__ (   self)

Definition at line 427 of file exceptions.py.

427 def __init__(self) -> None:
428 self.errors: List["HashError"] = []
429

Referenced by Protocol.__init_subclass__().

Here is the caller graph for this function:

Member Function Documentation

◆ __bool__()

bool __bool__ (   self)

Definition at line 443 of file exceptions.py.

443 def __bool__(self) -> bool:
444 return bool(self.errors)
445
446

◆ __str__()

str __str__ (   self)

Definition at line 433 of file exceptions.py.

433 def __str__(self) -> str:
434 lines = []
435 self.errors.sort(key=lambda e: e.order)
436 for cls, errors_of_cls in groupby(self.errors, lambda e: e.__class__):
437 lines.append(cls.head)
438 lines.extend(e.body() for e in errors_of_cls)
439 if lines:
440 return "\n".join(lines)
441 return ""
442
for i

◆ append()

None append (   self,
"HashError"  error 
)

Definition at line 430 of file exceptions.py.

430 def append(self, error: "HashError") -> None:
431 self.errors.append(error)
432

Referenced by And.__iadd__(), Each.__iand__(), MatchFirst.__ior__(), Or.__ixor__(), and Stack.push().

Here is the caller graph for this function:

Field Documentation

◆ errors

◆ head

head

Definition at line 437 of file exceptions.py.


The documentation for this class was generated from the following file: