Return-Path: Delivered-To: apmail-incubator-stdcxx-commits-archive@www.apache.org Received: (qmail 1800 invoked from network); 28 Sep 2006 15:49:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 28 Sep 2006 15:49:56 -0000 Received: (qmail 26078 invoked by uid 500); 28 Sep 2006 15:49:56 -0000 Delivered-To: apmail-incubator-stdcxx-commits-archive@incubator.apache.org Received: (qmail 26059 invoked by uid 500); 28 Sep 2006 15:49:56 -0000 Mailing-List: contact stdcxx-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: stdcxx-dev@incubator.apache.org Delivered-To: mailing list stdcxx-commits@incubator.apache.org Received: (qmail 26045 invoked by uid 99); 28 Sep 2006 15:49:56 -0000 Received: from idunn.apache.osuosl.org (HELO idunn.apache.osuosl.org) (140.211.166.84) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Sep 2006 08:49:56 -0700 X-ASF-Spam-Status: No, hits=-9.4 required=5.0 tests=ALL_TRUSTED,NO_REAL_NAME Received: from [140.211.166.113] ([140.211.166.113:53623] helo=eris.apache.org) by idunn.apache.osuosl.org (ecelerity 2.1.1.8 r(12930)) with ESMTP id 12/35-17533-32FEB154 for ; Thu, 28 Sep 2006 08:49:55 -0700 Received: by eris.apache.org (Postfix, from userid 65534) id 279F91A981A; Thu, 28 Sep 2006 08:49:53 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r450906 - in /incubator/stdcxx/trunk/include: deque list map set string vector Date: Thu, 28 Sep 2006 15:49:52 -0000 To: stdcxx-commits@incubator.apache.org From: faridz@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20060928154953.279F91A981A@eris.apache.org> X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: faridz Date: Thu Sep 28 08:49:51 2006 New Revision: 450906 URL: http://svn.apache.org/viewvc?view=rev&rev=450906 Log: 2006-09-28 Farid Zaripov * deque: Added #ifndef _RWSTD_NO_PART_SPEC_OVERLOAD/#endif around the function std::swap (std::deque&, std::deque&); [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added function std::swap (std::deque&, std::deque&) * list [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added function std::swap (std::list&, std::list&) * map [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added functions std::swap (std::map&, std::map&) and std::swap (std::multimap&, std::multimap&) * set [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added functions std::swap (std::set&, std::set&) and std::swap (std::multiset&, std::multiset&) * string [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added function std::swap (std::string&, std::string&) * vector [_RWSTD_NO_PART_SPEC_OVERLOAD]: Added functions std::swap (std::vector&, std::vector&) and std::swap (std::vector&, std::vector&) Modified: incubator/stdcxx/trunk/include/deque incubator/stdcxx/trunk/include/list incubator/stdcxx/trunk/include/map incubator/stdcxx/trunk/include/set incubator/stdcxx/trunk/include/string incubator/stdcxx/trunk/include/vector Modified: incubator/stdcxx/trunk/include/deque URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/deque?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/deque (original) +++ incubator/stdcxx/trunk/include/deque Thu Sep 28 08:49:51 2006 @@ -7,36 +7,26 @@ * *************************************************************************** * - * Copyright (c) 1994 - * Hewlett-Packard Company - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - * - *************************************************************************** - * - * Copyright 2005-2006 The Apache Software Foundation or its licensors, - * as applicable. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. * * Copyright 1994-2006 Rogue Wave Software. * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Copyright (c) 1994 Hewlett-Packard Company * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * **************************************************************************/ #ifndef _RWSTD_DEQUE_INCLUDED @@ -651,6 +641,13 @@ _RWSTD_ASSERT (_C_is_valid (1 /* valid and empty */)); } +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (deque& __lhs, deque& __rhs) { + __lhs.swap (__rhs); + } +#endif + + private: ////////////////////////////////////////////////////////////////// @@ -983,6 +980,8 @@ } +#ifndef _RWSTD_NO_PART_SPEC_OVERLOAD + template inline void swap (deque<_TypeT, _Allocator> &__lhs, deque<_TypeT, _Allocator> &__rhs) @@ -990,6 +989,7 @@ __lhs.swap (__rhs); } +#endif // _RWSTD_NO_PART_SPEC_OVERLOAD } // namespace end Modified: incubator/stdcxx/trunk/include/list URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/list?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/list (original) +++ incubator/stdcxx/trunk/include/list Thu Sep 28 08:49:51 2006 @@ -7,29 +7,25 @@ * *************************************************************************** * - * Copyright (c) 1994 - * Hewlett-Packard Company + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. + * Copyright 1994-2005 Rogue Wave Software. * - *************************************************************************** - * - * Copyright (c) 1994-2005 Quovadx, Inc., acting through its Rogue Wave - * Software division. Licensed under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * http://www.apache.org/licenses/LICENSE-2.0. Unless required by - * applicable law or agreed to in writing, software distributed under - * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR - * CONDITIONS OF ANY KIND, either express or implied. See the License - * for the specific language governing permissions and limitations under - * the License. + * Copyright (c) 1994 Hewlett-Packard Company * **************************************************************************/ @@ -663,6 +659,12 @@ void clear () { erase (begin (), end ()); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (list& __lhs, list& __rhs) { + __lhs.swap (__rhs); + } +#endif protected: Modified: incubator/stdcxx/trunk/include/map URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/map?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/map (original) +++ incubator/stdcxx/trunk/include/map Thu Sep 28 08:49:51 2006 @@ -7,35 +7,25 @@ * *************************************************************************** * - * Copyright (c) 1994 - * Hewlett-Packard Company - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - * - *************************************************************************** - * - * Copyright 2005-2006 The Apache Software Foundation or its licensors, - * as applicable. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. * * Copyright 1994-2006 Rogue Wave Software. * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright (c) 1994 Hewlett-Packard Company * **************************************************************************/ @@ -300,6 +290,13 @@ equal_range (const key_type& __x) const { return _C_rep.equal_range (__x); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (map& __lhs, map& __rhs) { + __lhs.swap (__rhs); + } +#endif + }; @@ -529,6 +526,13 @@ equal_range (const key_type& __x) const { return _C_rep.equal_range (__x); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (multimap& __lhs, multimap& __rhs) { + __lhs.swap (__rhs); + } +#endif + }; Modified: incubator/stdcxx/trunk/include/set URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/set?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/set (original) +++ incubator/stdcxx/trunk/include/set Thu Sep 28 08:49:51 2006 @@ -7,35 +7,25 @@ * *************************************************************************** * - * Copyright (c) 1994 - * Hewlett-Packard Company - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - * - *************************************************************************** - * - * Copyright 2005-2006 The Apache Software Foundation or its licensors, - * as applicable. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. * * Copyright 1994-2006 Rogue Wave Software. * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright (c) 1994 Hewlett-Packard Company * **************************************************************************/ @@ -301,6 +291,13 @@ equal_range (const key_type& __x) const { return _C_rep.equal_range (__x); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (set& __lhs, set& __rhs) { + __lhs.swap (__rhs); + } +#endif + }; @@ -505,6 +502,13 @@ equal_range (const key_type& __x) const { return _C_rep.equal_range (__x); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (multiset& __lhs, multiset& __rhs) { + __lhs.swap (__rhs); + } +#endif + }; Modified: incubator/stdcxx/trunk/include/string URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/string?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/string (original) +++ incubator/stdcxx/trunk/include/string Thu Sep 28 08:49:51 2006 @@ -7,17 +7,24 @@ * *************************************************************************** * - * Copyright (c) 1994-2005 Quovadx, Inc., acting through its Rogue Wave - * Software division. Licensed under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * http://www.apache.org/licenses/LICENSE-2.0. Unless required by - * applicable law or agreed to in writing, software distributed under - * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR - * CONDITIONS OF ANY KIND, either express or implied. See the License - * for the specific language governing permissions and limitations under - * the License. - * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. + * + * Copyright 1994-2006 Rogue Wave Software. + * **************************************************************************/ #ifndef _RWSTD_STRING_INCLUDED @@ -822,6 +829,12 @@ // lwg Issue 5 int compare (size_type, size_type, const_pointer, size_type) const; + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (basic_string& __lhs, basic_string& __rhs) { + __lhs.swap (__rhs); + } +#endif #if !defined (_RWSTD_NO_INLINE_MEMBER_TEMPLATES) \ && (!defined (_MSC_VER) || _MSC_VER >= 1300 || defined (__INTEL_COMPILER)) \ Modified: incubator/stdcxx/trunk/include/vector URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/vector?view=diff&rev=450906&r1=450905&r2=450906 ============================================================================== --- incubator/stdcxx/trunk/include/vector (original) +++ incubator/stdcxx/trunk/include/vector Thu Sep 28 08:49:51 2006 @@ -7,35 +7,25 @@ * *************************************************************************** * - * Copyright (c) 1994 - * Hewlett-Packard Company - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - * - *************************************************************************** - * - * Copyright 2006 The Apache Software Foundation or its licensors, - * as applicable. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. See the License for the specific language governing + * permissions and limitations under the License. * * Copyright 1994-2006 Rogue Wave Software. * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Copyright (c) 1994 Hewlett-Packard Company * **************************************************************************/ @@ -370,6 +360,12 @@ erase (begin (), end ()); } +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (vector& __lhs, vector& __rhs) { + __lhs.swap (__rhs); + } +#endif + private: // implements assign with repetition @@ -1432,6 +1428,13 @@ { erase(begin(),end()); } + +#if defined (_RWSTD_NO_PART_SPEC_OVERLOAD) + friend void swap (vector& __lhs, vector& __rhs) { + __lhs.swap (__rhs); + } +#endif + }; #undef _Allocator