hokein added a comment. Hi, this patch seems to break the following code which was previously compiled:
#include <type_traits> #include <algorithm> #include <numeric> template <typename It, typename MapFn> auto MapJoin(It first, It last, MapFn map_fn) { return std::accumulate( first, last, map_fn(*first), [=](typename std::result_of<MapFn(decltype(*first))>::type result) { }); // a new diagnostic: error: captured variable 'first' cannot appear here } Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D123909/new/ https://reviews.llvm.org/D123909 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits