| 590 | } |
| 591 | |
| 592 | void ContractLevelChecker::checkStorageSize(ContractDefinition const& _contract) |
| 593 | { |
| 594 | using enum VariableDeclaration::Location; |
| 595 | for (VariableDeclaration::Location location: {Unspecified, Transient}) |
| 596 | { |
| 597 | bigint size = contractStorageSizeUpperBound(_contract, location); |
| 598 | if (size >= bigint(1) << 256) |
| 599 | { |
| 600 | if (location == Unspecified) |
| 601 | m_errorReporter.typeError(7676_error, _contract.location(), "Contract requires too much storage."); |
| 602 | else |
| 603 | m_errorReporter.typeError(5026_error, _contract.location(), "Contract requires too much transient storage."); |
| 604 | } |
| 605 | } |
| 606 | } |
nothing calls this directly
no test coverage detected