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

[feature request] Запретить присваивание void #55

Open
Stepami opened this issue Feb 16, 2024 · 0 comments
Open

[feature request] Запретить присваивание void #55

Stepami opened this issue Feb 16, 2024 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers ir Working on intermediate representation of the interpreter language feature New language feature (grammar, semantics, etc.)

Comments

@Stepami
Copy link
Owner

Stepami commented Feb 16, 2024

Is your feature request related to a problem? Please describe.
Рассмотрим следующий участок кода:

function func(b: boolean) {
    if (b)
        return
    return
}
let x = func(true)

Статический анализ должен завершаться с ошибкой о том, что тип void не может участвовать в присваивании

@Stepami Stepami added enhancement New feature or request ir Working on intermediate representation of the interpreter language feature New language feature (grammar, semantics, etc.) good first issue Good for newcomers labels Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers ir Working on intermediate representation of the interpreter language feature New language feature (grammar, semantics, etc.)
Projects
None yet
Development

No branches or pull requests

1 participant