bfgroup / Lyra

A simple to use, composable, command line parser for C++ 11 and beyond
https://bfgroup.github.io/Lyra/
Boost Software License 1.0
471 stars 56 forks source link

Lambdas passed to `opt` and `arg` constructors cannot be move-only #93

Open mknejp opened 3 months ago

mknejp commented 3 months ago

Because the lambda is taken by const& is can only be copied into the parser object, which is not possible if it contains state that can only be moved.

https://godbolt.org/z/d9hGsa1Te