Open federicobond opened 6 years ago
Current implementation - master
branch - supports ETH. You deposit ETH and use PlasmaCoin
as ETH on plasma chain.
This pull request #17 implements token ERC20 instead of ETH. You can deposit defined token
(check constructor argument which defines main chain's token address https://github.com/jdkanani/plasma/blob/c189d9808763abe69067277c66dab55b66187c4f/contracts/RootChain.sol#L82) and PlasmaCoin
will represent that token on plasma chain.
Okay so on master, both deposit and PlasmaCoin are ETH. On PR #17, deposit is ETH and PlasmaCoin is "PlasmaWP-mentioned block withholding attack desincentivizing token".
So this ERC-20 token must be used for transaction fee, and PoS validation reward, right?
With #17 you can deposit tokens from an ERC-20 compatible token contract defined in the RootChain constructor a get a UTXO for that token in the Plasma chain.
Deposit is gonna be arbitrary ERC-20 token, PlasmaCoin will represent that Plasma chain's token, okay.
And this PlasmaCoin will be re-implemented on each child Plasma chain, but this repo is gonna be template/framework for building offspring chains, hence no need to reinvent wheel, right?
That's right, a new contract instance must be deployed for each token you want to support.
The rootchain is expensive, hence for example nth-depth PlasmaChain's PlasmaCoin(ERC-20 based) is not able to be processed & defined on the rootchain contract.
Then I guestimated that (n-1)th PlasmaChain might have an ability to define Plasma contract for nth PlasmaChain, and this PlasmaCoin is not defined on the rootchain.
For enabling that, this repo must have EVM to define&process PlasmaContract, rather thab on the rootchain PlasmaContract. CMIIW.
What is this token for? Deposited ETH on Plasma chain? So the PlasmaETH will be ERC-20 token? I wanna know some underlying discussion.