Skip to content

Commit

Permalink
merge interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
AlbertoCentonze committed Nov 5, 2024
1 parent 0abcf45 commit fe609dc
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 18 deletions.
19 changes: 19 additions & 0 deletions vyper/builtins/interfaces/IERC20.vyi
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,22 @@ def transferFrom(_from: address, _to: address, _value: uint256) -> bool:
@external
def approve(_spender: address, _value: uint256) -> bool:
...

#NOTE: interface uses `String[1]` where 1 is the lower bound of the string returned by the function.
# For end-users this means they can't use `implements: ERC20Detailed` unless their implementation
# uses a value n >= 1. Regardless this is fine as one can't do String[0] where n == 0.

@view
@external
def name() -> String[1]:
...

@view
@external
def symbol() -> String[1]:
...

@view
@external
def decimals() -> uint8:
...
18 changes: 0 additions & 18 deletions vyper/builtins/interfaces/IERC20Detailed.vyi

This file was deleted.

0 comments on commit fe609dc

Please sign in to comment.