Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/fiery-waves-move.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'openzeppelin-solidity': patch
---

Deprecate DOMAIN_SEPARATOR in ERC20Permit.
1 change: 1 addition & 0 deletions contracts/token/ERC20/extensions/ERC20Permit.sol
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712, Nonces {
}

/// @inheritdoc IERC20Permit
/// @custom:deprecated Use ERC-5267 (via {eip712Domain}) instead. This function will be removed in v6.0.
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32) {
return _domainSeparatorV4();
Expand Down
2 changes: 2 additions & 0 deletions contracts/token/ERC20/extensions/IERC20Permit.sol
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The DOMAIN_SEPARATOR function is part of ERC-2612. We cannot just remove it from here

Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ interface IERC20Permit {

/**
* @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
*
* @custom:deprecated Use ERC-5267 (via {eip712Domain}) instead. This function will be removed in v6.0.
*/
// solhint-disable-next-line func-name-mixedcase
function DOMAIN_SEPARATOR() external view returns (bytes32);
Expand Down
Loading
Loading