blob: 3dd2551bbc15c1ace42e58ef59450b0e4ebd4f50 [file] [log] [blame]
Anders Carlsson8e7670d2009-10-12 19:41:04 +00001// RUN: clang-cc %s -emit-llvm -o - | FileCheck %s
2
3struct A {
4 virtual void f();
5};
6
7void f(A a, A *ap, A& ar) {
8 // This should not be a virtual function call.
9
10 // CHECK: call void @_ZN1A1fEv(%struct.A* %a)
11 a.f();
12
13 // CHECK: call void %
14 ap->f();
15
16 // CHECK: call void %
17 ar.f();
Anders Carlsson76366482009-10-12 19:45:47 +000018
19 // CHECK: call void @_ZN1A1fEv
20 A().f();
Anders Carlsson8e7670d2009-10-12 19:41:04 +000021}