ambv / flake8-mypy

A plugin for flake8 integrating Mypy.
MIT License
101 stars 17 forks source link

Complain if any function arguments are not typed #3

Open cooperlees opened 7 years ago

cooperlees commented 7 years ago

Assuming we've added a return type to a function (-> AwesomeType:) lets make flake8-mypy complain that you have not typed all the arguments for said function.

# This should cause flake8-mypy to be unhappy
# FIX: def awesome(ambv: bool=False, cooper: int=69) -> bool:
def awesome(ambv=False, cooper=69) -> bool:
    if not ambv and cooper == 69:
        return True
    return False