Skip to content

Commit

Permalink
casting to list doesn't seem necessary, remain iterator for lazy eval
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielYang59 committed Oct 18, 2024
1 parent 532cad0 commit 88b5eab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pymatgen/io/vasp/inputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
from pymatgen.util.typing import Kpoint, Tuple3Floats, Tuple3Ints, Vector3D

if TYPE_CHECKING:
from collections.abc import Sequence
from collections.abc import Iterator, Sequence
from typing import Any, ClassVar, Literal

from numpy.typing import ArrayLike
Expand Down Expand Up @@ -855,7 +855,7 @@ def from_str(cls, string: str) -> Self:
Returns:
Incar object
"""
lines: list[str] = list(clean_lines(string.splitlines()))
lines: Iterator[str] = clean_lines(string.splitlines())
params: dict[str, Any] = {}
for line in lines:
for sline in line.split(";"):
Expand Down

0 comments on commit 88b5eab

Please sign in to comment.