1// Simple smoke test to see that the demangler is actually working 2 3namespace abc { 4template <typename T1, typename T2> 5class def { 6 public: 7 T1 xyzzy(T1 *p, T2 *) 8 { 9 return *p ? 10 : 20; 10 } 11 }; 12}; 13 14template <typename T> 15class magic { 16public: 17 T xyzzy(T *p) 18 { 19 return (new abc::def<int,typeof(*this)>)->xyzzy(p, 0); 20 } 21}; 22 23int main() 24{ 25 magic<int> *c = new magic<int>; 26 27 c->xyzzy(new int); 28 return 0; 29} 30