This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: [RFA] Remove use of queue.h from gdbserver/event-loop.c


>>>>> "Simon" == Simon Marchi <simon.marchi@polymtl.ca> writes:

Simon> On 2018-06-07 22:55, Tom Tromey wrote:
>> This removes a use of queue.h from gdbserver/event-loop.c, replacing
>> it with std::queue.
>> 
>> I was not completely sure whether std::queue is even that useful.
>> Perhaps plain std::list could be used just as easily.

Simon> In the end it probably compiles down to the same thing, since
Simon> std::queue is just a wrapper around the underlying container.  The
Simon> std::queue would probably be useful if we wanted to swap the
Simon> underlying container type without changing the code that uses the
Simon> queue.  I'm fine either way.

In this particular case, I think any future change to the data structure
is likely to be pretty easy even without the queue wrapper.

Tom


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