开发者

Customizing debug print format with PyDev

Is it possible to see ints (and ints that are parts of dicts, lists, and tuples, etc.) as hex values when debugging with PyDev?

More broadly, is it possible to make any given data type show up the w开发者_如何学Pythonay you want in the variable display tab?


The PyDev Debugger simply uses the repr() function to show the values. So if overwrite the __repr__() function than you can change how the values are printed.

I don't think there are any other options of changing the way your variables show, although you might (not sure about that) be able to get away with overwriting the repr() function itself.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜