Jonathan Wakely | 24 May 18:02 2016
Picon
Gravatar

[PATCH] Add priority_queue::value_compare (LWG 2684)

	* include/bits/stl_queue.h (priority_queue::value_compare): Define.

This is only Tentatively Ready but I don't think there's any harm in
making the change now. Libc++ have been shipping this for years,
without realising it wasn't actually in the standard :-)

Tested x86_64, committed to trunk.

commit 64c647342c0786ae01b4f0b4b4ce716da7faa757
Author: redi <redi <at> 138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Tue May 24 15:59:05 2016 +0000

    Add priority_queue::value_compare (LWG 2684)

    	* include/bits/stl_queue.h (priority_queue::value_compare): Define.

    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk <at> 236646 138bc75d-0d04-0410-961f-82ee72b054a4

diff --git a/libstdc++-v3/include/bits/stl_queue.h b/libstdc++-v3/include/bits/stl_queue.h
index 9caca03..a292309 100644
--- a/libstdc++-v3/include/bits/stl_queue.h
+++ b/libstdc++-v3/include/bits/stl_queue.h
 <at>  <at>  -417,6 +417,9  <at>  <at>  _GLIBCXX_BEGIN_NAMESPACE_VERSION
       typedef typename _Sequence::const_reference           const_reference;
       typedef typename _Sequence::size_type                 size_type;
       typedef          _Sequence                            container_type;
+      // _GLIBCXX_RESOLVE_LIB_DEFECTS
+      // DR 2684. priority_queue lacking comparator typedef
(Continue reading)

François Dumont | 22 May 17:21 2016
Picon

Debug iterator cleanup

Hi

     I just want to make sure that you agree that I can remove the  <at> todo 
by implementing operator-> this way.

     * include/debug/safe_iterator.h
     (_Safe_iterator<>::operator->()): Implement using underlying iterator
     operator ->.
     * include/debug/safe_local_iterator.h
     (_Safe_local_iterator<>::operator->()): Likewise.

François
Attachment (debug_iterator.patch): text/x-patch, 1625 bytes
Pavel P | 20 May 04:46 2016
Picon

Issues with unordered_map and unordered_multimap

Hi,

I noticed that unordered_map with g++ (4.7 or 5.2) cannot be used with
forward declared types:

#include <unordered_map>

class test;
typedef std::unordered_map<int, test> test_map;
typedef test_map::iterator test_map_iterator;  // <== error

here's error output: https://ideone.com/sy05RG

This same code works with std::map: https://ideone.com/poufNk
As far as I understand standard doesn't require that it would work,
still I think it would be nice that it worked similar to std::map. It
works ok with MSVC by the way.

The other issue is with unordered_multimap. Not sure what's going on
behind the scenes, but it was exceptionally slow in my case, and
unorderedmap::operator[] was taking like 80% of CPU in my app. I ended
up replacing it with unordered_map<lkey, list<value> > to solve it.

Any ideas?.

Thanks,
Pavel

Tim Shen | 16 May 05:56 2016
Picon

[Patch] Implement std::experimental::variant

Hi,

I have implemented
p0088r2<http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0088r2.html>.

The interface is massive and the sfinae conditions are complicated, so
I won't be surprised that I made mistakes on interface conformance
(especially for uses-allocator constructors).

I didn't document the public interfaces, since they may still change;
I'll document them if it's preferred. Important implementations are
documented though.

Currently it's in std::experimental::fundamentals_v1. Is there a
better place to put it in?

Thank you!

--

-- 
Regards,
Tim Shen
commit 5d50b1181882e3df43c675acc11e5b013a9af31c
Author: Tim Shen <timshen <at> google.com>
Date:   Sun May 15 18:21:39 2016 -0700

    2016-05-15  Tim Shen  <timshen <at> google.com>
    
    	* include/Makefile.am: Add new file.
(Continue reading)

Jonathan Wakely | 10 May 17:53 2016
Picon
Gravatar

[PATCH] Test begin and end functions for directory iterators

A minor fix for missing noexcept qualifiers, pointed out by Eric
again.

	* include/experimental/bits/fs_dir.h (begin, end): Add noexcept.
	* testsuite/experimental/filesystem/iterators/directory_iterator.cc:
	Test begin and end functions.
	* testsuite/experimental/filesystem/iterators/
	recursive_directory_iterator.cc: Likewise.

Tested x86_64-linux and x86_64-freebsd10, committed to trunk.
Backports to follow.

commit 2f45dbbd2c3f01a1dcdee4c265dc394561f42606
Author: redi <redi <at> 138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Tue May 10 15:39:20 2016 +0000

    Test begin and end functions for directory iterators

    	* include/experimental/bits/fs_dir.h (begin, end): Add noexcept.
    	* testsuite/experimental/filesystem/iterators/directory_iterator.cc:
    	Test begin and end functions.
    	* testsuite/experimental/filesystem/iterators/
    	recursive_directory_iterator.cc: Likewise.

    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk <at> 236085 138bc75d-0d04-0410-961f-82ee72b054a4

diff --git a/libstdc++-v3/include/experimental/bits/fs_dir.h b/libstdc++-v3/include/experimental/bits/fs_dir.h
index 011d398..70a95eb 100644
(Continue reading)

Jonathan Wakely | 10 May 15:50 2016
Picon
Gravatar

[PATCH] libstdc++/71036 Handle EEXIST in filesystem::create_directory

Another bug Eric noticed. I had tests for create_directories() but not
create_directory(), and the former was already checking whether it
existed or not, so I didn't notice this bug.

	PR libstdc++/71036
	* src/filesystem/ops.cc (create_dir): Handle EEXIST from mkdir.
	* testsuite/experimental/filesystem/operations/create_directory.cc:
	New test.

Tested x86_64-linux, committed to trunk. Backports to follow.

commit 50e15efafef5fd7893ff186546e755a6530c348a
Author: redi <redi <at> 138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Tue May 10 13:04:21 2016 +0000

    libstdc++/71036 Handle EEXIST in filesystem::create_directory

    	PR libstdc++/71036
    	* src/filesystem/ops.cc (create_dir): Handle EEXIST from mkdir.
    	* testsuite/experimental/filesystem/operations/create_directory.cc:
    	New test.

    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk <at> 236076 138bc75d-0d04-0410-961f-82ee72b054a4

diff --git a/libstdc++-v3/src/filesystem/ops.cc b/libstdc++-v3/src/filesystem/ops.cc
index e18c751..fab4235 100644
--- a/libstdc++-v3/src/filesystem/ops.cc
+++ b/libstdc++-v3/src/filesystem/ops.cc
(Continue reading)

Unknown | 10 May 15:06 2016

[PATCH] libstdc++/71036 Handle EEXIST in filesystem::create_directory

Another bug Eric noticed. I had tests for create_directories() but not
create_directory(), and the former was already checking whether it
existed or not, so I didn't notice this bug.

	PR libstdc++/71036
	* src/filesystem/ops.cc (create_dir): Handle EEXIST from mkdir.
	* testsuite/experimental/filesystem/operations/create_directory.cc:
	New test.

Tested x86_64-linux, committed to trunk. Backports to follow.
commit 50e15efafef5fd7893ff186546e755a6530c348a
Author: redi <redi <at> 138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Tue May 10 13:04:21 2016 +0000

    libstdc++/71036 Handle EEXIST in filesystem::create_directory

    	PR libstdc++/71036
    	* src/filesystem/ops.cc (create_dir): Handle EEXIST from mkdir.
    	* testsuite/experimental/filesystem/operations/create_directory.cc:
    	New test.

    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk <at> 236076 138bc75d-0d04-0410-961f-82ee72b054a4

diff --git a/libstdc++-v3/src/filesystem/ops.cc b/libstdc++-v3/src/filesystem/ops.cc
index e18c751..fab4235 100644
--- a/libstdc++-v3/src/filesystem/ops.cc
+++ b/libstdc++-v3/src/filesystem/ops.cc
 <at>  <at>  -660,22 +660,26  <at>  <at>  namespace
(Continue reading)

Jonathan Wakely | 10 May 14:03 2016
Picon
Gravatar

[PATCH] Remove unused using declaration in libstdc++ testsuite

A minor tweak. Tested x86_64-linux, committed to trunk.

commit 68e7dfdee8a53d5d18357b654a84221dc5a5529e
Author: Jonathan Wakely <jwakely <at> redhat.com>
Date:   Tue May 10 13:02:09 2016 +0100

    	* testsuite/experimental/type_erased_allocator/2.cc: Remove unused
    	using declaration.

diff --git a/libstdc++-v3/testsuite/experimental/type_erased_allocator/2.cc b/libstdc++-v3/testsuite/experimental/type_erased_allocator/2.cc
index 8f7d0b5..4460498 100644
--- a/libstdc++-v3/testsuite/experimental/type_erased_allocator/2.cc
+++ b/libstdc++-v3/testsuite/experimental/type_erased_allocator/2.cc
 <at>  <at>  -17,9 +17,9  <at>  <at> 
 // with this library; see the file COPYING3.  If not see
 // <http://www.gnu.org/licenses/>.

-#include <memory>
 #include <experimental/memory_resource>
 #include <experimental/utility>
+#include <memory>
 #include <testsuite_hooks.h>
 #include <testsuite_allocator.h>

 <at>  <at>  -27,7 +27,6  <at>  <at>  using std::experimental::pmr::polymorphic_allocator;
 using std::experimental::pmr::memory_resource;
 using std::experimental::pmr::new_delete_resource;
 using std::experimental::pmr::get_default_resource;
(Continue reading)

Jonathan Wakely | 9 May 12:09 2016
Picon
Gravatar

[patch] libstdc++/71004 fix recursive_directory_iterator default constructor

This fixes some uninitialized members in the
filesystem::recursive_directory_iterator default constructor.

Tested x86_64-linux, committed to trunk. Backports to follow soon.

Attachment (patch.txt): text/x-patch, 1736 bytes
Rainer Orth | 5 May 16:36 2016
Picon
Picon

[v3] Enable dg-reqire-sharedlib on Solaris

I happened to notice that dg-require-sharedlib hardcodes the targets
that shared library, and Solaris is missing.  Fixed with the following
patch.

Bootstrapped on i386-pc-solaris2.12, the affected testcases now PASS.
Ok for mainline?

	Rainer

2016-05-04  Rainer Orth  <ro <at> CeBiTec.Uni-Bielefeld.DE>

	* testsuite/lib/libstdc++.exp (libstdc++_init): Enable on
	*-*-solaris*.


--

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
Jonathan Wakely | 28 Apr 14:33 2016
Picon
Gravatar

[patch] libstdc++/70766 use std::addressof instead of operator&

A few more places where we should be using std::addressof.

Tested x86_64-linux, committed to trunk.

Attachment (patch.txt): text/x-patch, 14 KiB

Gmane