Hello,
Right after initiating a new project thanks to truffle init
, I get the following error message for the constructor:
Syntax error: Expected ".", "[", "constant", "internal", "private", "public", comment, end of line, identifier, or whitespace but "(" found.
The weirdest thing is that I have an older project from 5 months ago, and there, the constructor is not highlighted at all.
I checked my .prettierrc, .eslintrc, .vscode/settings.json, my Solidity linter… Every single configuration is the same and I cannot explain why I got this new error.
Does anyone have an idea of why this is happening? Thanks!
[EDIT] I also get this error from a random other Test.sol:
[EDIT2] The issue is actually described here (even though it’s closed) and it’s still exactly what’s happening to me: constructor
and emit
cause misleading highlights: https://github.com/trufflesuite/truffle/issues/906#