Discussion: print stack...
Afficher un message
Vieux 16/10/2007, 18h55   #1
call_me_anything
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut print stack...

Here is a code to have a debug printf :

#ifdef DEBUG
#define DEBUG_printf(...)
{printf("[%s]:",__FUNCTION__)rintf(__VA_ARGS__)rintf("\n"); }
#else
#define DEBUG
#endif

int main () {
DEBUG_printf ("%d %s", 5, "abc");
}

Is there something similar, which can print the current stack ?
I mean some C/C++ API which can me get any info related to the
current stack of functions.
Thats is required for debugging.
(Please do not suggest gdb... I want something similar to gdb stack
traces but that should print stack info everytime I compile with DEBUG
on)

  Réponse avec citation
 
Page generated in 0,04597 seconds with 9 queries