[ create a new paste ] login | about

Link: http://codepad.org/beuXVTtd    [ raw code | output | fork ]

C++, pasted on Apr 3:
1
2
3
4
5
6
7
8
9
10
11
#include <cstdio>


void foo() {}

int main() {
  printf("foo   %p %s\n", (void*)&typeid(foo),   typeid(foo).name());
  printf("&foo  %p %s\n", (void*)&typeid(&foo),  typeid(&foo).name());
  printf("void  %p %s\n", (void*)&typeid(void),  typeid(void).name());
  printf("void* %p %s\n", (void*)&typeid(void*), typeid(void*).name());
}


Output:
1
2
3
4
foo   0x804d4e8 FvvE
&foo  0x804d4f0 PFvvE
void  0x804e440 v
void* 0x804e430 Pv


Create a new paste based on this one


Comments: