unimport icon indicating copy to clipboard operation
unimport copied to clipboard

Unimport does not work correctly when there is a nested if statement.

Open hakancelikdev opened this issue 2 years ago • 0 comments

if sys.version_info < (3, 7):
    if TYPE_CHECKING:

        class ForwardRef:
            def __init__(self, arg: Any):
                pass

            def _eval_type(self, globalns: Any, localns: Any) -> Any:
                pass

    else:
        from typing import _ForwardRef as ForwardRef
else:
    from typing import ForwardRef

hakancelikdev avatar Jul 05 '23 05:07 hakancelikdev