Describe the bug
Whenever a method is overriden, Solang appends an underscore _ to the method name in the generated metadata file.
To Reproduce
After compiling the following file:
abstract contract Base {
function test() public pure virtual returns (uint8) {
return 42;
}
}
contract TestA is Base {
}
contract TestB is Base {
function test() public pure override returns (uint8) {
return 42;
}
}
with Solang (latest release 0.3.3), the generated metadata file for TestA correctly calls the method test ("label": "test").
However, in contract TestB it is called test_ ("label": "test_").
Expected behavior
The metadata name is also test in the metadata for contract TestB.
This is also the behavior of the Solidity compiler (where the method is called test in both cases in the generated metadata).
Describe the bug Whenever a method is overriden, Solang appends an underscore
_
to the method name in the generated metadata file.To Reproduce After compiling the following file:
with Solang (latest release 0.3.3), the generated metadata file for
TestA
correctly calls the methodtest
("label": "test"
).However, in contract
TestB
it is calledtest_
("label": "test_"
).Expected behavior The metadata name is also
test
in the metadata for contractTestB
.This is also the behavior of the Solidity compiler (where the method is called
test
in both cases in the generated metadata).Hyperledger Solang version 0.3.3