In Visual C++, one can find the header file where any name (variable or type) is defined by pressing F12 on it or choosing Go to Definition. This feature is very useful, but it only shows the final location (header file) where the name is defined. Is there a way to figure out the chain of header files that lead from my source file to the final header file for a given name?
For example, consider this code:
// main.cpp
#include <stddef.h>
int main()
{
size_t s;
return 0;
}
In Visual C++ 2010, if I look up the definition of size_t
in the above main.cpp
, it lands me in some file named sourceannotations.h
. I know that this header chain begins with stddef.h
(which I have included) and ends in sourceannotations.h
. How to figure out the links in the middle of this chain?