You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 16, 2022. It is now read-only.
So, ERC223 brought about a new transfer function that cuts the gas necessary in half.
However, we can't bundle both ERC20's old transfer methods and ERC223's new transfer as solidity doesn't allow us to check what type the requested token is AFAIK.
The current smart_contract.sol in this repo "supports" ERC223 by using a fallback, but it still goes through approve and transferFrom .
I propose that, for future proofing, we create some sort of system where each protocol (ERC20, ERC223) can have a separate contract. Then, the interface calls the contracts based on the type of token. That way, we can utilize each protocol's benefits. This would also allow us to add future protocols with ease as we would simply create a new contract for the protocol instead of editing an old one.
This is not necessary NOW, but would be a welcome addition in the future.
The text was updated successfully, but these errors were encountered:
So, ERC223 brought about a new
transfer
function that cuts the gas necessary in half.However, we can't bundle both ERC20's old transfer methods and ERC223's new
transfer
as solidity doesn't allow us to check what type the requested token is AFAIK.The current
smart_contract.sol
in this repo "supports" ERC223 by using a fallback, but it still goes throughapprove
andtransferFrom
.I propose that, for future proofing, we create some sort of system where each protocol (ERC20, ERC223) can have a separate contract. Then, the interface calls the contracts based on the type of token. That way, we can utilize each protocol's benefits. This would also allow us to add future protocols with ease as we would simply create a new contract for the protocol instead of editing an old one.
This is not necessary NOW, but would be a welcome addition in the future.
The text was updated successfully, but these errors were encountered: