Overriding ERC-20 methods
It seems clear that you can override the ERC-20 methods (transfer, etc) to have them do non-standard things in addition to the intended functionality. Is it true that as long as you implement those methods, you can have them perform other functionality and still be considered ERC-20 (to be able to be listed on an exchange)? Thought maybe gas requirements could be an issue- for example, if a transfer takes a lot more gas than normal, would that be a problem for an exchange?
You are correct that as long as the methods from the ERC20 interface are implemented, they are accepted to be ERC20 tokens and can be supported by Mist wallet. The implementation of the function could be completely different and that wouldn’t still affect the ERC20 status of the token. But, obviously this isn’t a recommended practice and is discouraged.
The gas value would depend on the implementation of the function. ERC20 tokens can perform additional operations in the transfer function – updating values in the storage, setting flags etc which would impact the gas value required to successfully process a transaction. Exchanges will not reject ERC20 tokens based on the gas value required to execute the transfer function.
Our Awesome Tools
- Check your IP Address precisely
- Online JSON Formatter with Syntax Highlight
- Online CSS Minifier Compressor
- Database Administration Tutorials
- Programming Tutorials & IT News
- Linux & DevOps World
- Ebook Reviews
- eSport Matches, Skills Tutorials & News
- Entertainment & General News
- Check your public IP Address precisely