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

Strict "implements" behaviour #4233

Open
romanagureev opened this issue Sep 10, 2024 · 0 comments
Open

Strict "implements" behaviour #4233

romanagureev opened this issue Sep 10, 2024 · 0 comments

Comments

@romanagureev
Copy link

Version Information

  • vyper Version (output of vyper --version): 0.4.0

What's your issue about?

implements keyword is strict in a sense of forbidding modifying mutability and adding new default parameters. @trocher argumented on strict version, though I need a way to show contract is compatible having implementation-specific parameters.

A.vyi

# pragma version 0.4.0

@external
def bridge(_token: address):
    ...

B.vy

# pragma version 0.4.0
import A
implements: A

@external
# @payable  # <-- Can not add
def bridge(
    _token: address,
#     _specific: uint256=0,  # <-- Can not add
):
    return

How can it be fixed?

  • Relaxed version of implements like compatible: or follows:
  • # noqa style comments to skip specific checks
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