You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
struct A; struct B;
let id : &Fn(B)->B = &|x|{x};
let di : &Fn(A)->&Fn(B)->B = &|discard:A|{id};
produces the following error message, which is utterly non-informative about how to fix the problem:
<anon>:14:76: 14:85 error: missing lifetime specifier [E0106]
<anon>:14 struct A; struct B; let id : &Fn(B)->B = &|x|{x}; let di : &Fn(A)->&Fn(B)->B = &|discard:A|{id};
^~~~~~~~~
<anon>:14:76: 14:85 help: this function's return type contains a borrowed value, but the signature does not say which one of argument 1's 0 elided lifetimes it is borrowed from
<anon>:14 struct A; struct B; let id : &Fn(B)->B = &|x|{x}; let di : &Fn(A)->&Fn(B)->B = &|discard:A|{id};
^~~~~~~~~
In particular "which one of argument 1's 0 elided lifetimes it is borrowed from" is particularly confusing.
The following code:
produces the following error message, which is utterly non-informative about how to fix the problem:
In particular "which one of argument 1's 0 elided lifetimes it is borrowed from" is particularly confusing.
Version:
rustc 1.0.0-dev (2b01a37ec 2015-02-21) (built 2015-02-21)
The text was updated successfully, but these errors were encountered: