Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
massun-onibakuchi committed Jun 3, 2024
1 parent 529cf45 commit 7a10a7a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/GrimReaper.huff
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
/// @notice Fetches the token balance of the caller for the provided token
/// @notice Stack Input: [token]
/// @notice Stack Output: [balance, token]
#define macro STATIC_CALL_TOKEN_BALANCE_MINUS_ONE() = takes (0) returns (2) {
#define macro GET_TOKEN_BALANCE_MINUS_ONE() = takes (0) returns (2) {
// Static Call token.balanceOf(address(this))
__FUNC_SIG(balanceOf) 0x00 mstore // [token]
address 0x20 mstore // [token]
Expand All @@ -44,7 +44,7 @@
0x00 calldataload // [token]

// Get the balance of this contract
STATIC_CALL_TOKEN_BALANCE_MINUS_ONE() // [(balance - 1), token]
GET_TOKEN_BALANCE_MINUS_ONE() // [(balance - 1), token]

// Call token.transfer(msg.sender, balance - 1)
caller 0x14 mstore // [(balance - 1), token]
Expand Down

0 comments on commit 7a10a7a

Please sign in to comment.