Date
2011-11-08.00:00:00
Message id
5936

Content

"std::allocator_traits<std::allocator<T>>::propagate_on_container_move_assignment::value" is specified as "false", according to ([default.allocator]) and ([allocator.traits.types]). However, according to ([container.requirements.general]), this specification leads to the unneeded requirements (MoveInsertable and MoveAssignable of the value type) on the move assignment operator of containers with the default allocator.

Proposed resolution:

Either of the following two changes;

  1. adding the nested typedef like "typedef std::true_type propagate_on_container_move_assignment;" in the definition of std::allocator class template,
  2. adding the explicit partial specialization of "std::allocator_traits" class template for "std::allocator" class template, in which "propagate_on_container_move_assignment" nested typedef is specified as "std::true_type".

Pablo prefers the first resolution.