Annex C (informative) Compatibility [diff]

C.3 C++ and ISO C++ 2014 [diff.cpp14]

C.3.9 [utilities]: general utilities library [diff.cpp14.utilities]

Affected subclause: [func.wrap]
Change: Constructors taking allocators removed.

Rationale: No implementation consensus.

Effect on original feature: Valid C++ 2014 code may fail to compile or may change meaning in this revision of C++.
Specifically, constructing a std​::​function with an allocator is ill-formed and uses-allocator construction will not pass an allocator to std​::​function constructors in this revision of C++.
Affected subclause: [util.smartptr.shared]
Change: Different constraint on conversions from unique_­ptr.

Rationale: Adding array support to shared_­ptr, via the syntax shared_­ptr<T[]> and shared_­ptr<T[N]>.

Effect on original feature: Valid C++ 2014 code may fail to compile or may change meaning in this revision of C++.
For example: #include <memory> std::unique_ptr<int[]> arr(new int[1]); std::shared_ptr<int> ptr(std::move(arr)); // error: int(*)[] is not compatible with int*