error[E0495]: cannot infer an appropriate lifetime due to conflicting requirements
--> src/network/
udp.rs:80:43
|
80 | ... thread::spawn(move || {
| _____________________________________^
81 | | ... let cfg = self.config.clone();
82 | | ... UDPServer::handle(receiver, *cfg);
83 | | ... });
| |_______________________^
|
note: first, the lifetime cannot outlive the lifetime
'a
as defined on the impl at 33:7...
--> src/network/
udp.rs:33:7
|
33 | impl <'a>UDPServer {
| ^^
note: ...so that the types are compatible
--> src/network/
udp.rs:80:43
|
80 | ... thread::spawn(move || {
| _____________________________________^
81 | | ... let cfg = self.config.clone();
82 | | ... UDPServer::handle(receiver, *cfg);
83 | | ... });
| |_______________________^
= note: expected
&UDPServer
found
&'a UDPServer
= note: but, the lifetime must be valid for the static lifetime...
note: ...so that the type
[closure@src/network/udp.rs:80:43: 83:30]
will meet its required lifetime bounds
--> src/network/
udp.rs:80:29
|
80 | ... thread::spawn(move || {
| ^^^^^^^^^^^^^
error: aborting due to previous error