1 //===----------------------------------------------------------------------===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is dual licensed under the MIT and the University of Illinois Open 6 // Source Licenses. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 10 // <map> 11 12 // Check that std::multimap and its iterators can be instantiated with an incomplete 13 // type. 14 15 #include <map> 16 17 struct A { 18 typedef std::multimap<A, A> Map; 19 int data; 20 Map m; 21 Map::iterator it; 22 Map::const_iterator cit; 23 }; 24 25 inline bool operator==(A const& L, A const& R) { return &L == &R; } 26 inline bool operator<(A const& L, A const& R) { return L.data < R.data; } 27 int main() { 28 A a; 29 } 30