Skip to content

Conversation

arr00
Copy link
Contributor

@arr00 arr00 commented Jul 3, 2025

No description provided.

@arr00 arr00 requested a review from a team as a code owner July 3, 2025 15:42
Copy link

netlify bot commented Jul 3, 2025

Deploy Preview for confidential-tokens ready!

Name Link
🔨 Latest commit 9b30819
🔍 Latest deploy log https://app.netlify.com/projects/confidential-tokens/deploys/686db3ab793e920008bb162b
😎 Deploy Preview https://deploy-preview-75--confidential-tokens.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@arr00 arr00 force-pushed the feat/emit-erc20-events branch from 2350116 to e9268c7 Compare July 8, 2025 17:15
*/
abstract contract ConfidentialFungibleTokenERC20Events is ConfidentialFungibleToken {
function _update(address from, address to, euint64 amount) internal virtual override returns (euint64) {
emit IERC20.Transfer(from, to, 1);
Copy link
Contributor

Choose a reason for hiding this comment

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

Any reason to use 1 over something else ? I'd personally use 0. That way the arithmetics of inbound - outbound would always be 0, and can never go negative.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

0 value transfers are automatically hidden by Etherscan. Tried that first

Copy link
Contributor

Choose a reason for hiding this comment

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

Interesting, thank you for this test.
Considering what you say, I feel adding Transfer events (with this dummy value of 1), might not be the best path for being compatible with Etherscan (since it looks a bit twisted).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Don't disagree but without any dedicated support from etherescan this is likely the only way. We could do something with ERC1155 or ERC721 too but I feel like that isn't desirable.

@arr00 arr00 marked this pull request as draft July 28, 2025 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants