This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: pb_ds debug patch ?


>      While working on libstdc++ I experiment a regression in usage of 
> pb_ds priority_queue. To find out what was wrong I made some 
> modifications in debug mode of this type to have the 
> binary_heap_::assert_valid method report the file:line where the 
> assert_valid is invoked and not always a line in the method 
> implementation code. As most of methods are using a assert_valid
> after enter and an other before exit it helps me detect exactly after
> what code the data structure got corrupted.

I like what you've done here. This is useful for debugging.
 
>      Here is the patch. Now that I found my regression should I
> revert those modifications or are you interested in me generalizing
> this approach to other priority_queue data structure policies and
> submit a final patch ? If so tell me if new macro names are ok with
> you ?

Generalizing sounds good. The new macro names look fine to me.

-benjamin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]