[clang] Handle __declspec() attributes in using
[llvm-project.git] / clang / test / CodeCompletion / overrides.cpp
blob7f330904eede98ad15f2f6b302da1881d31cfc39
1 class A {
2 public:
3 virtual void vfunc(bool param);
4 virtual void vfunc(bool param, int p);
5 void func(bool param);
6 };
7 class B : public A {
8 virtual int ttt(bool param, int x = 3) const;
9 void vfunc(bool param, int p) override;
11 class C : public B {
12 public:
13 void vfunc(bool param) override;
14 vf;
17 // Runs completion at ^vf
18 // RUN: %clang_cc1 -fsyntax-only -code-completion-at=%s:%(line-4):3 %s -o - | FileCheck -check-prefix=CHECK-CC1 %s
19 // CHECK-CC1: COMPLETION: Pattern : int ttt(bool param, int x = 3) const override{{$}}
20 // CHECK-CC1: COMPLETION: Pattern : void vfunc(bool param, int p) override{{$}}
21 // CHECK-CC1-NOT: COMPLETION: Pattern : void vfunc(bool param) override{{$}}
23 // Runs completion at vf^
24 // RUN: %clang_cc1 -fsyntax-only -code-completion-at=%s:%(line-10):5 %s -o - | FileCheck -check-prefix=CHECK-CC2 %s
25 // CHECK-CC2-NOT: COMPLETION: Pattern : int ttt(bool param, int x = 3) const override{{$}}
26 // CHECK-CC2: COMPLETION: Pattern : void vfunc(bool param, int p) override{{$}}
27 // CHECK-CC2-NOT: COMPLETION: Pattern : void vfunc(bool param) override{{$}}
29 // Runs completion at void ^ on line 13.
30 // RUN: %clang_cc1 -fsyntax-only -code-completion-at=%s:%(line-17):8 %s -o - | FileCheck -check-prefix=CHECK-CC3 %s
31 // CHECK-CC3-NOT: COMPLETION: Pattern : int ttt(bool param, int x = 3) const override{{$}}
32 // CHECK-CC3-NOT: COMPLETION: Pattern : void vfunc(bool param, int p) override{{$}}
33 // CHECK-CC3-NOT: COMPLETION: Pattern : void vfunc(bool param) override{{$}}
35 void func() {
36 class D : public A {
41 // Runs completion at empty line on line 37.
42 // RUN: not %clang_cc1 -fsyntax-only -code-completion-at=%s:%(line-5):1 %s -o - | FileCheck -check-prefix=CHECK-CC4 %s
43 // CHECK-CC4: COMPLETION: Pattern : void vfunc(bool param, int p) override{{$}}