[PATCH] Remove __gnu_pbds::detail::binary_heap::is_heap (PR libstdc++/62045)

Marek Polacek polacek@redhat.com
Fri Mar 10 11:21:00 GMT 2017


On Fri, Mar 10, 2017 at 07:18:24PM +0800, Xi Ruoyao wrote:
> Hi,
> 
> The ill-formed checking in binary_heap::push_heap has made it
> O(n). Remove this checking.
> 
> Since assert_valid also checks if (*this) is a legal heap, we can
> remove is_heap and the assertions using it completely.

I think this patch should also go to libstdc++@gcc.gnu.org.

	Marek



More information about the Gcc-patches mailing list