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

VIP: make constructor payable by default #3607

Open
charles-cooper opened this issue Sep 18, 2023 · 0 comments
Open

VIP: make constructor payable by default #3607

charles-cooper opened this issue Sep 18, 2023 · 0 comments

Comments

@charles-cooper
Copy link
Member

Simple Summary

as title

Motivation

it's unlikely a contract deployer would send ETH to it by accident

Specification

make the default only modifiability on __init__ functions to be payable. disallow all modifier decorators on the __init__ function - @view and @pure should also be disallowed as __init__ functions are modifying by nature. For backwards compatibility, allow @payable on __init__ functions for 1-2 minor releases but mark it as deprecated.

Backwards Compatibility

modifer decorators will no longer be allowed on __init__() functions

Dependencies

If this VIP depends on any other VIPs being implemented, please mention them.

References

Add any references that this VIP might reference (other VIPs/issues, links to blog posts, etc.)

Copyright

Copyright and related rights waived via CC0

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