Closed varshney565 closed 10 months ago
@varshney565 Not sure if you still need this clarification, but the documentation is indeed wrong in this case. See https://github.com/paritytech/ink-docs/pull/281 for details.
You can also use this other example instead.
Has been fixed with https://github.com/paritytech/ink-docs/pull/281.
https://use.ink/basics/trait-definitions
None of the code in the trait definition is working.
The code of the first example is giving the error
ink! trait definitions must not have constructors
as shown in the screenshot below.And When I hover over the code the error given by the analyzer is
I have tried switching to the version
4.x.x
still got the same error, is there something wrong with the documentation or am I doing it wrong