xwpe
xwpe copied to clipboard
Discuss: defined constants
Hi Alessandro,
I was debugging the xwpe program, because I want to understand what is happening and I find the code somewhat difficult to interpret. During the debugging I regularly encounter (#define SOMECONSTANT) and when used in an expression I cannot see the value in (c)gdb.
My inclination atm is to gradually replace #defined constants by a const variable. That would make it traceable and visible runtime. Of course every change is dangerous, even if it seems simple (i have learned that the hard way xD).
As C is not my primary language, maybe you already have an opinion. Wat do you think?
Regards, Guus.
I agree. This should be done in a phased approach. We should also double-check to see if we can find any recycled variables and figure out what to do with those on a case-by-case basis.