Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

31讲IERC20文件补充建议 #178

Closed
jujube109 opened this issue Aug 28, 2022 · 2 comments
Closed

31讲IERC20文件补充建议 #178

jujube109 opened this issue Aug 28, 2022 · 2 comments

Comments

@jujube109
Copy link

31讲中所依赖的IERC20.sol文件只介绍了几个方法名,未展示方法具体写法。小白没法在remix里动手运行
image

@AmazingAng
Copy link
Owner

AmazingAng commented Aug 28, 2022

IERC20是接口合约,没有具体写法的。具体逻辑在ERC20中实现。
你的意思是补充ERC20的具体写法吗?

@qbmiller
Copy link

qbmiller commented Sep 8, 2022

// SPDX-License-Identifier: GPL-3.0

pragma solidity 0.8.7;
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract LearnContact is ERC20{

constructor(uint _totalSuperNum) ERC20("learn test","LT") {
    _mint(msg.sender,_totalSuperNum);
}

}

remix 直接部署,就看到 一堆函数了

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

No branches or pull requests

3 participants