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

Interfaces are useless, scrap them. #3420

Closed
1 task done
fulldecent opened this issue Jan 21, 2018 · 2 comments
Closed
1 task done

Interfaces are useless, scrap them. #3420

fulldecent opened this issue Jan 21, 2018 · 2 comments
Labels
language design :rage4: Any changes to the language, e.g. new features

Comments

@fulldecent
Copy link
Contributor

fulldecent commented Jan 21, 2018

Interfaces have extremely limited utility and only academic use in real-world scenarios. While working on standardizing an interface, several shortcomings are apparent:


To recognize the problem, see that none of the draft ERCs https://github.com/ethereum/solidity/issues/ are using interface to specify their standards. Instead, they resort to using functions inlined in markdown. And the functions are not even correct (missing public or other warnings). Clearly interface is not filling the needs of today's ERC writers.

Solution

Completely scrap the way interface keyword is understood. Here is the new definition of interface:

An interface is identical to a contract in all ways except that a) an interface cannot inherit from a contract and b) you cannot compile an interface.

Such a definition would be immediately useful and simpler to explain than the current mechanism.

Additional work:

@fulldecent
Copy link
Contributor Author

I no longer think this is the correct solution to the interface problem. But I'll keep this issue open until the language redesign is complete as a reminder of the current inconsistencies.

@fulldecent
Copy link
Contributor Author

Closing here. Those others issues that need to be open are open.

And there is an Inheritance Manifest #3729 (comment) which is a better collection of issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
language design :rage4: Any changes to the language, e.g. new features
Projects
None yet
Development

No branches or pull requests

2 participants