Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

type_checker decorator #10

Open
bleudev opened this issue May 28, 2024 · 0 comments
Open

type_checker decorator #10

bleudev opened this issue May 28, 2024 · 0 comments
Assignees
Labels
Milestone

Comments

@bleudev
Copy link
Member

bleudev commented May 28, 2024

type_checker decorator edits function for starting checking for types of arguments and return values when function is calling.

@type_checker
def func(a: int, b: float) -> str: ...

func(1, 2.1) # ok
func(1, '2.1') # TypeError

@type_checker
def func2() -> str:
    return 12

func2() # TypeError
@bleudev bleudev added new feature New feature new function New function labels May 28, 2024
@bleudev bleudev added this to the 1.0 milestone May 28, 2024
@bleudev bleudev self-assigned this May 28, 2024
@bleudev bleudev added this to Ufpy May 28, 2024
@github-project-automation github-project-automation bot moved this to ⚠ To-Do in Ufpy May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: ⚠ To-Do
Development

No branches or pull requests

1 participant