Skip to content

Commit

Permalink
fix[stdlib]: fix IERC4626 signatures (#4425)
Browse files Browse the repository at this point in the history
the signatures should not have default parameters; if used, they will
create a different method id at the callsite than the ERC4626 standard
actually accepts.

- add `stdlib` to the list of valid PR scopes
  • Loading branch information
charles-cooper authored Dec 28, 2024
1 parent 705aa54 commit e9ac7cd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ jobs:
# docs: documentation
# test: test suite
# lang: language changes
# stdlib: changes to the stdlib
# ux: language changes (UX)
# tool: integration
# ir: (old) IR/codegen changes
Expand All @@ -43,6 +44,7 @@ jobs:
docs
test
lang
stdlib
ux
tool
ir
Expand Down
8 changes: 4 additions & 4 deletions vyper/builtins/interfaces/IERC4626.vyi
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def previewDeposit(assets: uint256) -> uint256:
...

@external
def deposit(assets: uint256, receiver: address=msg.sender) -> uint256:
def deposit(assets: uint256, receiver: address) -> uint256:
...

@view
Expand All @@ -58,7 +58,7 @@ def previewMint(shares: uint256) -> uint256:
...

@external
def mint(shares: uint256, receiver: address=msg.sender) -> uint256:
def mint(shares: uint256, receiver: address) -> uint256:
...

@view
Expand All @@ -72,7 +72,7 @@ def previewWithdraw(assets: uint256) -> uint256:
...

@external
def withdraw(assets: uint256, receiver: address=msg.sender, owner: address=msg.sender) -> uint256:
def withdraw(assets: uint256, receiver: address, owner: address) -> uint256:
...

@view
Expand All @@ -86,5 +86,5 @@ def previewRedeem(shares: uint256) -> uint256:
...

@external
def redeem(shares: uint256, receiver: address=msg.sender, owner: address=msg.sender) -> uint256:
def redeem(shares: uint256, receiver: address, owner: address) -> uint256:
...

0 comments on commit e9ac7cd

Please sign in to comment.