duaraghav8 / Ethlint

(Formerly Solium) Code quality & Security Linter for Solidity
https://ethlint.readthedocs.io/en/latest/
MIT License
926 stars 128 forks source link

Wrong error message for `msg.sender.call{value: amount}("");` #286

Open avatar-lavventura opened 4 years ago

avatar-lavventura commented 4 years ago

For the following line: (bool success, ) = msg.sender.call{value: amount}(""); ; I am getting following error message:

Syntax error: unexpected token {
✖ 1 error found.

But solidity 0.7.0 recommend us to use {value: ...} an usage of { seems correct. Why solium generates this error message even it is correct and recommended usage in Solidity?

TypeError: Using ".value(...)" is deprecated. Use "{value: ...}" instead.
        (bool success, ) = msg.sender.call.value(amount)("");