Conversation
|
I am for the naming changes, also nice addition the split to What is the use case of the two new Events that don't contain an amount? Maybe we don't want to raise them as, even though the event of an encrypted transfer can be known by an observer, maybe we don't want to explicitly let everybody know that? I didn't think too much about it but I think it is possible to do the plugin system you're talking about. Or maybe as extensions like those in erc721. |
|
Unfortunately the split I'm not sure about the events, without the amount I don't think they end up doing much like you said other than exposing data. |
|
Ah! So your plugin to the hardhat plugin is indeed working and catching good stuff! Yeah, it seems that the plain enc_ functions are indeed problematic Maybe what we could is: |
820a042 to
0585458
Compare
Events now emitted.
Encrypted functions renamed to `enc{ERC20FunctionName}`.
Encrypted variables renamed to `e{Name}`.
`inExxx` renamed to `ie{Name}`.
`wrap` / `unwrap` renamed to `encrypt` / `decrypt`.
Broke encrypted public variables into `enc___` version and `sealed___` version.
Added `_encBeforeTokenTransfer` and `_encAfterTokenTransfer` hooks.
Cleaned up imports, events, and errors.
0585458 to
6789d3c
Compare
Discussion of the FHERC20 standard. It is currently using the draft PermitNFTs (#74) and has some temporary code in it that requires the PermitV2 contract address in the constructor, which will be removed in the future.
Here are the implementation differences compared to
tokens/FHERC20.sol:enc{ERC20FunctionName}.e{Name}.ie{Name}.wrap/unwraprenamed toencrypt/decrypt.enc___(for other FHE enabled contracts) andsealed___(for frontend display)._encBeforeTokenTransferand_encAfterTokenTransferhooks to match the OpenZeppelin ERC20 standard.Open Questions: