Add _CompareWithType (#884)

It got accidentally removed in 6f5c5ce42f
This commit is contained in:
Hynek Schlawack 2021-12-12 10:25:50 +01:00 committed by GitHub
parent dfa725bdfc
commit 8ae0bd904d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -51,6 +51,7 @@ _OnSetAttrArgType = Union[
_FieldTransformer = Callable[
[type, List[Attribute[Any]]], List[Attribute[Any]]
]
_CompareWithType = Callable[[Any, Any], bool]
# FIXME: in reality, if multiple validators are passed they must be in a list
# or tuple, but those are invariant and so would prevent subtypes of
# _ValidatorType from working when passed in a list or tuple.