Home Ask Login Register

Developers Planet

Your answer is one click away!

guglielmo london February 2016

How to use Gdb debugger to find value of ZZ object from Number Theory Library?

I use gdb debugger to print values of a variable which is of type ZZ. This data type is defined in Number Theory Library or NTL. When I use "print x" to find out my variable's value I obtain something like this:

print x 
$1 = {rep=0xab2cc54}. 

I guess this is the address of my ZZ object. How can I print its value ? I should mention that I don't know the internal representation of this class.

Can I use NTL with a compiler like Eclipse to debug easier my application ?


πάντα ῥεῖ February 2016

Can I use NTL with a compiler like Eclipse ...

First off: Eclipse isn't a compiler but an IDE that encapsulates compiler and debugging facilities for you.

In debugging mode the IDE is capable to resolve the actual types and inner representation used from your source code and letting you walk through.

That said I'm pretty sure you can use Eclipse CDT, to inspect your specific type values.

Post Status

Asked in February 2016
Viewed 2,941 times
Voted 7
Answered 1 times


Leave an answer

Quote of the day: live life