Override modifier getting deleted ?
So, this might not be the correct place to post this. I'm coming from VScode, using this Solidity extension, which seems to be using your module to format the code, in :14
Might be the problem is coming from another place, tho I doubt it, as the VScode extension seems to manage the override modifier missing error correctly, and the problem arises only as the formatter is applied to the file.
Anyway, a similar issue already exists in the appropriate repo, issue 174, I'm only passing thru to check on you guys as well.
Cheers
Using https://github.com/juanfranblanco/vscode-solidity formatting a contract with the override keyword results in the override keyword being removed
Unformatted
pragma solidity ^0.6.0;
contract A {
function doStuff() public virtual {}
}
contract B is A {
function doStuff() public override {}
}
Formatted
pragma solidity ^0.6.0;
contract A {
function doStuff() public virtual {}
}
contract B is A {
function doStuff() public {}
}
This was solved on version v1.0.0-alpha.49 Perhaps @juanfranblanco can publish a newer release pointing to the latest release?
@Janther @ianmihura yes it is is already there.. i was testing the caching feature before release.
Great, thank you, amazing work 🙌
Closing since this vscode-solidity has been updated
This problem still exists for contract state variables:
Before formatting: mapping(address => bool) public override varName;
After formatting: mapping(address => bool) public varName;
the same problem here do you think @Janther ?
Nope, this one is on us, first I’ll check if the parser identifies
virtual and override in these cases
On Thu, 28 May 2020 at 13:29, Mattia Richetto [email protected] wrote:
the same problem here do you think @Janther https://github.com/Janther ?
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/prettier-solidity/prettier-plugin-solidity/issues/277#issuecomment-635037175, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHZQZR7GDXHEWUTO3YASX3RTW477ANCNFSM4NDETUZQ .
Was this fixed by #281?
Oh, modifiers still pending, sorry.
Using [email protected] and [email protected] and the override keyword is still getting deleted on a non-abstract contract.
Update: nevermind, I upgraded to [email protected] and that works well.
I'm gonna close this issue then 😊