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

feat: Updates Comp.sol #49

Merged
merged 5 commits into from
Nov 12, 2024
Merged

Conversation

PacificYield
Copy link
Contributor

@PacificYield PacificYield commented Nov 12, 2024

This PR introduces:

  • a dynamic domain separator with caching logic
  • the support for SC signatures (ERC1271) and 64-byte signatures (EIP2098)
  • totalSupply defined in the constructor

See: #45

@PacificYield PacificYield added the enhancement New feature or request label Nov 12, 2024
@PacificYield PacificYield self-assigned this Nov 12, 2024
@PacificYield PacificYield marked this pull request as ready for review November 12, 2024 11:08
@immortal-tofu
Copy link
Collaborator

Why do we need to differ from original implementation for delegateBySig? https://github.com/compound-finance/compound-protocol/blob/master/contracts/Governance/Comp.sol#L161

@PacificYield
Copy link
Contributor Author

Why do we need to differ from original implementation for delegateBySig? https://github.com/compound-finance/compound-protocol/blob/master/contracts/Governance/Comp.sol#L161

It doesn't support SC signatures (ERC1271), nor EIP2098 since these didn't exist when this was introduced. Also, the domain separator is recomputed each time so it costs unnecessary gas.

Copy link
Collaborator

@immortal-tofu immortal-tofu left a comment

Choose a reason for hiding this comment

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

LGTM

@PacificYield PacificYield merged commit 8870669 into zama-ai:main Nov 12, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants