summaryrefslogtreecommitdiff
path: root/test/SemaCUDA
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2017-08-12 01:46:03 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2017-08-12 01:46:03 +0000
commit4e37891c39a770085048c2e8c93f676ae8a3cc6a (patch)
tree74de6b13b4355741a5492b2ec7a4b9999893a991 /test/SemaCUDA
parent1b599a5f36a0d4b26cf3c647712916de29b0d915 (diff)
PR34163: Don't cache an incorrect key function for a class if queried between
the class becoming complete and its inline methods being parsed. This replaces the hack of using the "late parsed template" flag to track member functions with bodies we've not parsed yet; instead we now use the "will have body" flag, which carries the desired implication that the function declaration *is* a definition, and that we've just not parsed its body yet. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@310776 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCUDA')
-rw-r--r--test/SemaCUDA/function-overload.cu2
-rw-r--r--test/SemaCUDA/no-destructor-overload.cu10
2 files changed, 6 insertions, 6 deletions
diff --git a/test/SemaCUDA/function-overload.cu b/test/SemaCUDA/function-overload.cu
index 3d4c29c42c..adf488b5ee 100644
--- a/test/SemaCUDA/function-overload.cu
+++ b/test/SemaCUDA/function-overload.cu
@@ -222,7 +222,7 @@ GlobalFnPtr fp_g = g;
// Test overloading of destructors
// Can't mix H and unattributed destructors
struct d_h {
- ~d_h() {} // expected-note {{previous declaration is here}}
+ ~d_h() {} // expected-note {{previous definition is here}}
__host__ ~d_h() {} // expected-error {{destructor cannot be redeclared}}
};
diff --git a/test/SemaCUDA/no-destructor-overload.cu b/test/SemaCUDA/no-destructor-overload.cu
index aa6971ee8c..32dbb8db76 100644
--- a/test/SemaCUDA/no-destructor-overload.cu
+++ b/test/SemaCUDA/no-destructor-overload.cu
@@ -7,27 +7,27 @@
// giant change to clang, and the use cases seem quite limited.
struct A {
- ~A() {} // expected-note {{previous declaration is here}}
+ ~A() {} // expected-note {{previous definition is here}}
__device__ ~A() {} // expected-error {{destructor cannot be redeclared}}
};
struct B {
- __host__ ~B() {} // expected-note {{previous declaration is here}}
+ __host__ ~B() {} // expected-note {{previous definition is here}}
__host__ __device__ ~B() {} // expected-error {{destructor cannot be redeclared}}
};
struct C {
- __host__ __device__ ~C() {} // expected-note {{previous declaration is here}}
+ __host__ __device__ ~C() {} // expected-note {{previous definition is here}}
__host__ ~C() {} // expected-error {{destructor cannot be redeclared}}
};
struct D {
- __device__ ~D() {} // expected-note {{previous declaration is here}}
+ __device__ ~D() {} // expected-note {{previous definition is here}}
__host__ __device__ ~D() {} // expected-error {{destructor cannot be redeclared}}
};
struct E {
- __host__ __device__ ~E() {} // expected-note {{previous declaration is here}}
+ __host__ __device__ ~E() {} // expected-note {{previous definition is here}}
__device__ ~E() {} // expected-error {{destructor cannot be redeclared}}
};