Since when does GCC support std::unordered_map with incomplete types?
EDIT3: It's not `std::unordered_map` that's changed, it's `std::pair`. I suspect it's [this commit](https://github.com/gcc-mirror/gcc/commit/e1543e694dadf1ea70eb72325219bc0cdc914a35) that made this sort of incomplete container possible (yay concepts!), but would love for someone who speaks stdlib to confirm.
Original Post:
[This compiles](https://godbolt.org/z/PnqrKKo9j) on GCC trunk:
#include <unordered_map>
struct Incomplete;
std::unordered_map<int, Incomplete> map;
struct Incomplete {};
int main() {};
Was this an intentional change or just a collateral bonus? It makes implementing certain types of recursive types convenient, and it's been true (though obviously not standards conforming) for `std::map` for awhile. Just wondering if there was some impetus for this change.
EDIT: To be clear, this is _only_ supported on trunk. I'm not literally asking "since when?" I'm asking "How? And why now?"
EDIT2: This supported [on clang trunk](https://godbolt.org/z/K5qr8G3K7) (and only clang trunk) as well, though that makes sense since it's probably a libstdc++ change not a compiler one.