1139825Simp// Copyright (C) 2014-2015 Free Software Foundation, Inc. 21541Srgrimes// 31541Srgrimes// This file is part of the GNU ISO C++ Library. This library is free 41541Srgrimes// software; you can redistribute it and/or modify it under the 51541Srgrimes// terms of the GNU General Public License as published by the 61541Srgrimes// Free Software Foundation; either version 3, or (at your option) 71541Srgrimes// any later version. 81541Srgrimes 91541Srgrimes// This library is distributed in the hope that it will be useful, 101541Srgrimes// but WITHOUT ANY WARRANTY; without even the implied warranty of 111541Srgrimes// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 121541Srgrimes// GNU General Public License for more details. 131541Srgrimes 141541Srgrimes// You should have received a copy of the GNU General Public License along 151541Srgrimes// with this library; see the file COPYING3. If not see 161541Srgrimes// <http://www.gnu.org/licenses/>. 171541Srgrimes 181541Srgrimes// { dg-options "-std=gnu++11" } 191541Srgrimes// { dg-do run { xfail *-*-* } } 201541Srgrimes 211541Srgrimes#include <debug/map> 221541Srgrimes 231541Srgrimes#include <testsuite_hooks.h> 241541Srgrimes#include <testsuite_allocator.h> 251541Srgrimes 261541Srgrimesusing __gnu_test::uneq_allocator; 271541Srgrimes 281541Srgrimesvoid test01() 291541Srgrimes{ 301541Srgrimes bool test __attribute__((unused)) = true; 311541Srgrimes 3214495Shsu typedef uneq_allocator<std::pair<const int, int> > alloc_type; 3350477Speter typedef __gnu_debug::multimap<int, int, std::less<int>, alloc_type> test_type; 341541Srgrimes 351541Srgrimes test_type v1(alloc_type(1)); 362165Spaul v1 = { { 0, 0 } }; 372165Spaul auto it = v1.begin(); 381541Srgrimes 39250623Sed test_type v2(std::move(v1), alloc_type(2)); 40250623Sed 41250623Sed VERIFY( it->first == 0 ); 42250623Sed} 43280958Spfg 44280958Spfgint main() 45280958Spfg{ 46250623Sed test01(); 47250623Sed return 0; 48250623Sed} 49250623Sed