Skip to content

Commit

Permalink
Fix typing on Python 3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
jakelishman committed Nov 10, 2022
1 parent fcd7f63 commit b333697
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ disable = [
"too-many-instance-attributes",
"too-many-locals",
"trailing-whitespace",
"ungrouped-imports",
"unknown-option-value",
"unnecessary-semicolon",
"unneeded-not",
Expand Down
6 changes: 5 additions & 1 deletion src/qiskit_qasm3_import/converter.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,12 @@
import math
import re
import string
import sys

from collections.abc import Iterator, Sequence
if sys.version_info < (3, 9):
from typing import Iterator, Sequence
else:
from collections.abc import Iterator, Sequence
from typing import Any, Callable, List, NoReturn, Optional, Tuple, Union

from openqasm3 import ast
Expand Down

0 comments on commit b333697

Please sign in to comment.