refactor levels.

only compute strip/bus comp tuples if ldirty.

add comp generator function to util.

added some docstrings

patch bump
This commit is contained in:
onyx-and-iris
2022-07-09 11:06:48 +01:00
parent 210c75ed5f
commit e979595a09
5 changed files with 67 additions and 28 deletions

View File

@@ -1,4 +1,5 @@
import functools
from typing import Iterator
def polling(func):
@@ -50,3 +51,13 @@ def script(func):
return func(remote, script)
return wrapper
def comp(t0: tuple, t1: tuple) -> Iterator[bool]:
"""
Generator function, accepts two tuples.
Evaluates equality of each member in both tuples.
"""
for a, b in zip(t0, t1):
yield a == b