I'm still new with the solidity and it seems to be a very basics question. What i'm trying to do is to call the link the compound smart contract with mine. And when i try to compile is complaining : "This contract may be abstract, not implement an abstract parent's methods completely or not invoke an inherited contract's constructor correctly." while i try input into the testnet .I would appreciate greatly if anyone could help:
pragma solidity ^0.5.12;
contract testCompound {
address cethAddress = 0x42a628e0c5F3767930097B34b08dCF77e78e4F2B; //Ropsten - Mainnet 0x4ddc2d193948926d02f9b1fe9e1daa0718270ed5
address cusdcAddress = 0x43a1363AFB28235720FCbDF0C2dAb7759091F7e0; //Ropsten - Mainnet 0x39aa39c021dfbae8fac545936693ac917d5e7563
ERC20 usdc = ERC20(0xFE724a829fdF12F7012365dB98730EEe33742ea2); //Ropsten - Mainnet 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48
// ERC20 eth = ERC20(0x00eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee);
address owner;
//CompoundERC20 private cethCompound;
CompoundERC20 private cusdcCompound;
constructor() public {
owner = msg.sender;
usdc = ERC20(0xFE724a829fdF12F7012365dB98730EEe33742ea2);
// cethCompound = CompoundERC20(cethAddress);
cusdcCompound = CompoundERC20(cusdcAddress);
}
function mint(uint256 mintAmount) external returns (bool){
//cethCompound.mint(_mintAmount);
//usdc.approve(cusdcAddress, mintAmount);
cusdcCompound.mint(mintAmount);
return true;
}
}
contract CompoundERC20 {
function approve ( address spender, uint256 amount ) external returns ( bool );
function mint ( uint256 mintAmount ) external returns ( uint );
}
contract ERC20 {
function totalSupply() external view returns (uint supply);
function balanceOf(address _owner) external view returns (uint balance);
function transfer(address _to, uint _value) external returns (bool success);
function transferFrom(address _from, address _to, uint _value) external returns (bool success);
function approve(address _spender, uint _value) external returns (bool success);
function allowance(address _owner, address _spender) external view returns (uint remaining);
function decimals() external view returns(uint digits);
event Approval(address indexed _owner, address indexed _spender, uint _value);
}