https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80654

--- Comment #9 from Frank Heckenbach <f.heckenb...@fh-soft.de> ---
Found another possible workaround: "Lie" to the compiler (though is it lying
when you're actually telling it the truth? ;) by specializing
std::is_trivially_copy_constructible like this (of course, one needs to repeat
it for all affected types, e.g. other containers and other non-copyable value
types):

namespace std
{
  template <typename T> struct
is_trivially_copy_constructible<std::vector<std::unique_ptr<T>>>: false_type {
};
}

I guess it's totally illegal to put such a specialization into std, but
realistically, can anything bad happen, seeing that it just injects a correct
answer where the default is buggy?

Reply via email to