mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 05:51:52 +08:00
Fix build following mypy support for metaclasses (#952)
Mypy now supports metaclasses in Python 2, see python/mypy#2830 so that now __metaclass__ attribute has special treatment. This PR makes small changes to fix the build (also most PRs are red because of this)
This commit is contained in:
committed by
Jukka Lehtosalo
parent
e3fb935ca4
commit
10c5e0cb44
2
third_party/2/google/protobuf/descriptor.pyi
vendored
2
third_party/2/google/protobuf/descriptor.pyi
vendored
@@ -13,7 +13,7 @@ class DescriptorMetaclass(type):
|
||||
def __instancecheck__(cls, obj): ...
|
||||
|
||||
class DescriptorBase:
|
||||
__metaclass__ = ... # type: Any
|
||||
__metaclass__ = DescriptorMetaclass
|
||||
has_options = ... # type: Any
|
||||
def __init__(self, options, options_class_name) -> None: ...
|
||||
def GetOptions(self): ...
|
||||
|
||||
2
third_party/2/yaml/__init__.pyi
vendored
2
third_party/2/yaml/__init__.pyi
vendored
@@ -40,7 +40,7 @@ class YAMLObjectMetaclass(type):
|
||||
def __init__(cls, name, bases, kwds) -> None: ...
|
||||
|
||||
class YAMLObject:
|
||||
__metaclass__ = ... # type: Any
|
||||
__metaclass__ = YAMLObjectMetaclass
|
||||
yaml_loader = ... # type: Any
|
||||
yaml_dumper = ... # type: Any
|
||||
yaml_tag = ... # type: Any
|
||||
|
||||
Reference in New Issue
Block a user