This is the mail archive of the gdb@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: pretty printer display hints for collections


>>>>> "Jens" == Elmenthaler, Jens <JENS.ELMENTHALER@advantest.com> writes:

Jens> Before I move to the libstdc++ mailing list or scratch my head how to
Jens> adapt Eclipse CDT being robust AND usable at the same time, is there
Jens> any good reason why the STL pretty printers for list, bitset, dqueue,
Jens> ... don't use display hint "array"?

For list, I can't think of a reason.

deque seems to return 'array' in the current libstdc++ printers.py.

bitset is funny because the interesting information is in the indices.
The values are all '1'.  However, this could be changed.


Jens> Or more generally, shouldn't any pretty printer for a collection
Jens> either use display hint "array" or "map"?

I wouldn't want to make a sweeping statement like that, but it seems
like a reasonable first approximation.

A long time ago we discussed how to get gdb to print multi-dimensional
arrays more nicely.  Those would not fit into this scheme.  (Nobody is
working on this right now, but there's still a bug open somewhere.)

Maybe a "set" style would be appropriate.  I'm not sure.

Tom


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