Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumC++perfect forwarding std::forwardSingle-choice MCQ

Why is using `std::forward<decltype(args)>(args)...` the correct idiom in a C++20 generic lambda, rather than `std::move(args)...`?

auto fwd = [](auto&&... args) { return g(std::forward<decltype(args)>(args)...); };