For a C++ debug application I want to be able to count the number of callstack frames easily. Is there an OS function to do this?
I need this for Windows and Posix, i.e. cross platform. Solutions to either or both platforms would be great.
I can walk the stack to find all of the frames but I wondered if there was an easy call to do this.