This is an archive of the discontinued LLVM Phabricator instance.

[LIBC++]std::reduce(begin, end, init) does not accept init with only move constructor
AbandonedPublic

Authored by kamleshbhalui on Nov 30 2019, 8:05 PM.

Details

Summary

As per the c++ when the user-declare move-constructor compiler deletes the copy constructor.
so modified the std::reduce(begin, end, init) so it does not require copy constructor and behavior matches with
std::reduce(begin, end, init,op).

It fixes this https://bugs.llvm.org/show_bug.cgi?id=43013

Diff Detail

Event Timeline

kamleshbhalui created this revision.Nov 30 2019, 8:05 PM
kamleshbhalui abandoned this revision.Dec 11 2019, 7:28 AM
This comment was removed by kamleshbhalui.