diff options
author | Teddy Wing | 2017-11-16 23:39:15 +0100 |
---|---|---|
committer | Teddy Wing | 2017-11-16 23:39:15 +0100 |
commit | 84d4e100e93a5e3b630eaa355120871af46667d2 (patch) | |
tree | d8699585eba9f86a59b7e66f3303d7ecae9dcd30 /src/github.rs | |
parent | f9b13604484fa7924efb8cde0dd26de0276065ff (diff) | |
download | kipper-84d4e100e93a5e3b630eaa355120871af46667d2.tar.bz2 |
main(): Add comment above cloned command line variables
Turns out the easiest way to share these variables between both closures
really is to clone them.
Thanks to 'durka42' on Mozilla#rust-beginners for explaining the problem
to me. In durka's words:
> both closures are required to be 'static
> so you can't send references across
> and the router handler has to be callable multiple times so you can't consume anything (that's the error you got)
It's also possible to share references using Arc, but that seems more
complicated than it's worth here. Just do the copy and be done with it.
Diffstat (limited to 'src/github.rs')
0 files changed, 0 insertions, 0 deletions