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
My GovernanceToken.sol is throwing an error while compiling. Please help me out.
Here's my GovernanceToken.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.18;
import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Votes.sol";
contract GovernanceToken is ERC20Votes {
uint256 public s_maxSupply = 1000000000000000000000000;
constructor()
ERC20("GovernanceToken", "GT")
ERC20Permit("GovernanceToken")
{
_mint(msg.sender, s_maxSupply);
}
}
Here's the error during compilation:
DeclarationError: Identifier not found or not unique.
--> contracts/GovernanceToken.sol:12:9:
|
12 | ERC20Permit("GovernanceToken")
| ^^^^^^^^^^^
Error HH600: Compilation failed
For more info go to https://hardhat.org/HH600 or run Hardhat with --show-stack-traces
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
My
GovernanceToken.sol
is throwing an error while compiling. Please help me out.Here's my
GovernanceToken.sol
Here's the error during compilation:
Beta Was this translation helpful? Give feedback.
All reactions