member-functions.cpp revision e9918d2443ad524e0f488e8f15d9bce4e7373cd1
1// RUN: clang-cc -emit-llvm %s -o %t &&
2struct C {
3  void f();
4  void g(int, ...);
5};
6
7// RUN: grep "define void @_ZN1C1fEv" %t | count 1 &&
8void C::f() {
9}
10
11void f() {
12  C c;
13
14// RUN: grep "call void @_ZN1C1fEv" %t | count 1 &&
15  c.f();
16
17// RUN: grep "call void (.struct.C\*, i32, ...)\* @_ZN1C1gEiz" %t | count 1
18  c.g(1, 2, 3);
19}
20