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: add ConfidentialVestingWallet/ConfidentialVestingWalletCliff #76

Merged
merged 5 commits into from
Dec 23, 2024

Conversation

PacificYield
Copy link
Contributor

@PacificYield PacificYield commented Dec 3, 2024

This PR adds two Solidity contracts: ConfidentialVestingWallet.sol and ConfidentialVestingWalletCliff.sol.

@PacificYield PacificYield self-assigned this Dec 3, 2024
@PacificYield PacificYield changed the title feat: add ConfidentialVestingWallet.sol feat: add ConfidentialVestingWallet Dec 3, 2024
@PacificYield PacificYield changed the title feat: add ConfidentialVestingWallet feat: add ConfidentialVestingWallet (WIP) Dec 3, 2024
@PacificYield PacificYield added the enhancement New feature or request label Dec 3, 2024
@PacificYield PacificYield force-pushed the feat/VestingWallet.sol branch 3 times, most recently from e897ec7 to c593586 Compare December 10, 2024 09:34
@PacificYield PacificYield force-pushed the feat/VestingWallet.sol branch from c593586 to 7212873 Compare December 10, 2024 13:13
@PacificYield PacificYield changed the title feat: add ConfidentialVestingWallet (WIP) feat: add ConfidentialVestingWallet/ConfidentialVestingWalletCliff Dec 16, 2024
@PacificYield PacificYield marked this pull request as ready for review December 16, 2024 10:54
@PacificYield PacificYield force-pushed the feat/VestingWallet.sol branch 3 times, most recently from f9e27fd to 7501cdb Compare December 17, 2024 16:04
@immortal-tofu
Copy link
Collaborator

I prefer let @jatZama review it 🙏

@PacificYield PacificYield force-pushed the feat/VestingWallet.sol branch from 7501cdb to e536334 Compare December 19, 2024 16:16
*/
abstract contract ConfidentialVestingWallet {
/// @notice Emitted when tokens are released to the beneficiary address.
event ConfidentialERC20Released();
Copy link
Member

@jatZama jatZama Dec 20, 2024

Choose a reason for hiding this comment

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

why you didn't keep original OZ specs allowing different tokens? this event should then contain an address argument. It is always better to make standard contracts as generalizable as possible imo.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Adjusted.

IConfidentialERC20 public immutable CONFIDENTIAL_ERC20;

/// @notice Duration (in seconds).
uint64 public immutable DURATION;
Copy link
Member

Choose a reason for hiding this comment

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

can you instead keep OZ's specs, with private variable and public getter functions?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I prefer not to adjust it (for now) because I like that immutable variables that are easy to be spotted. I don't get why OZ does it as such with public getter functions.

@PacificYield PacificYield requested a review from jatZama December 23, 2024 14:04
@PacificYield PacificYield merged commit 500d185 into main Dec 23, 2024
1 check passed
@PacificYield PacificYield deleted the feat/VestingWallet.sol branch December 23, 2024 16:09
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.

3 participants