@verify.register(nodes.MypyFile)
def verify_mypyfile(stub: nodes.MypyFile, runtime: MaybeMissing[types.ModuleType], object_path: List[str]) -> Iterator[Error]:
    if isinstance(runtime, Missing):
        (yield Error(object_path, 'is not present at runtime', stub, runtime))
        return
    if (not isinstance(runtime, types.ModuleType)):
        (yield Error(object_path, 'is not a module', stub, runtime))
        return
    to_check = set((m for (m, o) in stub.names.items() if (o.module_public and ((not m.startswith('_')) or hasattr(runtime, m)))))
    runtime_public_contents = [m for m in dir(runtime) if ((not m.startswith('_')) and (getattr(getattr(runtime, m), '__module__', None) == runtime.__name__))]
    to_check.update(getattr(runtime, '__all__', runtime_public_contents))
    to_check.difference_update({'__file__', '__doc__', '__name__', '__builtins__', '__package__'})
    for entry in sorted(to_check):
        (yield from verify((stub.names[entry].node if (entry in stub.names) else MISSING), getattr(runtime, entry, MISSING), (object_path + [entry])))
@verify.register(nodes.MypyFile)
def verify_mypyfile(stub: nodes.MypyFile, runtime: MaybeMissing[types.ModuleType], object_path: List[str]) -> Iterator[Error]:
    if isinstance(runtime, Missing):
        (yield Error(object_path, 'is not present at runtime', stub, runtime))
        return
    if (not isinstance(runtime, types.ModuleType)):
        (yield Error(object_path, 'is not a module', stub, runtime))
        return
    to_check = set((m for (m, o) in stub.names.items() if (o.module_public and ((not m.startswith('_')) or hasattr(runtime, m)))))
    runtime_public_contents = [m for m in dir(runtime) if ((not m.startswith('_')) and (getattr(getattr(runtime, m), '__module__', None) == runtime.__name__))]
    to_check.update(getattr(runtime, '__all__', runtime_public_contents))
    to_check.difference_update({'__file__', '__doc__', '__name__', '__builtins__', '__package__'})
    for entry in sorted(to_check):
        (yield from verify((stub.names[entry].node if (entry in stub.names) else MISSING), getattr(runtime, entry, MISSING), (object_path + [entry])))