[cfe-dev] [analyzer] gdb pretty printers for analyzer specific types

Artem Dergachev via cfe-dev cfe-dev at lists.llvm.org
Wed Aug 5 14:27:24 PDT 2020


Whoops, yeah, i mean, anyway, the question stands for gdb as well :)

On 05.08.2020 13:29, David Blaikie wrote:
> On Wed, Aug 5, 2020 at 12:16 PM Artem Dergachev via cfe-dev
> <cfe-dev at lists.llvm.org> wrote:
>> Do i understand correctly that you're basically advocating for a QoL change that'll make lldb commands `p V` and `p V.dump()` equivalent?
> This wouldn't apply to lldb, unfortunately - gdb and lldb have
> different pretty printer interfaces.
>
>> On 05.08.2020 10:40, Balázs Benics via cfe-dev wrote:
>>
>> I was thinking about some pretty printers.
>> And I'm thinking about SVals and SymExprs specifically.
>>
>> Why do we have no pretty printers for such types?
>>
>> I guess we could reuse their dump() method to acquire string representation.
>> The only problem is that that dumps the output to the standard error stream.
>>
>> What options do I have to get a python pretty-printer using this dump method?
>>
>> Another possible way to implement such a pretty printer is to hardcode the SVal
>> kinds in python to do the right thing for each case.
>> I'm not really a big fan of this way though.
>>
>> If you have experience with gdb pretty printers then your comments more then welcomed.
>>
>> Balazs.
>>
>> _______________________________________________
>> cfe-dev mailing list
>> cfe-dev at lists.llvm.org
>> https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>>
>>
>> _______________________________________________
>> cfe-dev mailing list
>> cfe-dev at lists.llvm.org
>> https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev



More information about the cfe-dev mailing list