The following code doesn't compile for me in visual studio 2012:
//1. Define struct
struct TestList
{
...
};
//2 define a pointer to 1. struct as typedef
typedef TestList * TestListPtr;
//3. use it latter on in the code as follows:
const TestList* p1 = 0;
const TestListPtr p2 = p1;
Then, get this compile error:
error C2440: 'initializing' : cannot convert from 'const TestList *' to 'const TestListPtr'
An reason why the above can be considered illegal syntax?
Haven't tried it with other compilers yet.