pySim/commands.py: Better type annotations

Change-Id: I68081b5472188f80a964ca48d5ec1f03adc70c4a
This commit is contained in:
Harald Welte
2023-07-09 17:03:17 +02:00
parent ab6897c4cd
commit fdb187d7ff
2 changed files with 55 additions and 45 deletions

View File

@@ -30,6 +30,7 @@ from typing import Optional, List, Dict, Any, Tuple, NewType
Hexstr = NewType('Hexstr', str)
SwHexstr = NewType('SwHexstr', str)
SwMatchstr = NewType('SwMatchstr', str)
ResTuple = Tuple[Hexstr, SwHexstr]
def h2b(s: Hexstr) -> bytearray:
"""convert from a string of hex nibbles to a sequence of bytes"""