Skip to content

update constructor-self-receiver-03.stderr #1341

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
error[E0637]: `&` without an explicit lifetime name cannot be used here
--> tests/ui/contract/fail/constructor-self-receiver-03.rs:10:34
|
10 | pub fn constructor(this: &Self) -> Self {
| ^ explicit lifetime name needed here

error[E0411]: cannot find type `Self` in this scope
--> tests/ui/contract/fail/constructor-self-receiver-03.rs:10:35
|
Expand All @@ -16,15 +22,16 @@ error[E0411]: cannot find type `Self` in this scope
10 | pub fn constructor(this: &Self) -> Self {
| ^^^^ `Self` is only available in impls, traits, and type definitions

error[E0106]: missing lifetime specifier
--> tests/ui/contract/fail/constructor-self-receiver-03.rs:10:34
|
10 | pub fn constructor(this: &Self) -> Self {
| ^ expected named lifetime parameter
|
help: consider introducing a named lifetime parameter
error[E0277]: the trait bound `&'static Contract: WrapperTypeDecode` is not satisfied
--> tests/ui/contract/fail/constructor-self-receiver-03.rs:10:9
|
10 ~ pub fn constructor(this: &'a Self) -> Self {
11 | Self {}
12 ~ }<'a>
10 | / pub fn constructor(this: &Self) -> Self {
11 | | Self {}
12 | | }
| |_________^ the trait `WrapperTypeDecode` is not implemented for `&'static Contract`
|
= help: the following other types implement trait `WrapperTypeDecode`:
Arc<T>
Box<T>
Rc<T>
= note: required because of the requirements on the impl of `parity_scale_codec::Decode` for `&'static Contract`