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

Warn on private and public overloads for a given name #959

Open
rikkimax opened this issue Sep 19, 2024 · 0 comments
Open

Warn on private and public overloads for a given name #959

rikkimax opened this issue Sep 19, 2024 · 0 comments

Comments

@rikkimax
Copy link
Contributor

rikkimax commented Sep 19, 2024

From Razvan's DConf 2024 talk.

// over.d
private void gun();
public void gun(int);
public alias t = gun;

// main.d
import over;

void main() {
   t();
}

A warning should be given if private and public is in overloaded set.

(Other potential solutions at compiler level are to error in talk).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant