mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
27 lines
585 B
Solidity
27 lines
585 B
Solidity
// SPDX-License-Identifier: UNLICENSED
|
|
pragma solidity >=0.8.0;
|
|
|
|
contract C
|
|
{
|
|
function makeSomeError() public pure returns (uint res)
|
|
{
|
|
uint x = "hi";
|
|
// ^^^^^^^^^^^^^ @conversionError
|
|
return;
|
|
// ^^^^^^^ @argumentsRequired
|
|
res = 2;
|
|
}
|
|
}
|
|
|
|
contract D
|
|
{
|
|
function main() public payable returns (uint)
|
|
{
|
|
C c = new C();
|
|
return c.makeSomeError(2, 3);
|
|
// ^^^^^^^^^^^^^^^^^^^^^ @wrongArgumentsCount
|
|
}
|
|
}
|
|
// ----
|
|
// publish_diagnostics_2: @conversionError 9574 @argumentsRequired 6777 @wrongArgumentsCount 6160
|