mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-02-06 01:47:41 +08:00
Replace a few instances of IO with protocols (#4296)
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import sys
|
||||
from _typeshed import AnyPath, StrPath
|
||||
from _typeshed import AnyPath, StrPath, SupportsWrite
|
||||
from typing import (
|
||||
IO,
|
||||
AbstractSet,
|
||||
Any,
|
||||
Callable,
|
||||
@@ -122,7 +121,7 @@ class RawConfigParser(_parser):
|
||||
@overload
|
||||
def items(self, section: str, raw: bool = ..., vars: Optional[_section] = ...) -> List[Tuple[str, str]]: ...
|
||||
def set(self, section: str, option: str, value: Optional[str] = ...) -> None: ...
|
||||
def write(self, fp: IO[str], space_around_delimiters: bool = ...) -> None: ...
|
||||
def write(self, fp: SupportsWrite[str], space_around_delimiters: bool = ...) -> None: ...
|
||||
def remove_option(self, section: str, option: str) -> bool: ...
|
||||
def remove_section(self, section: str) -> bool: ...
|
||||
def optionxform(self, optionstr: str) -> str: ...
|
||||
|
||||
Reference in New Issue
Block a user