diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2017-02-15 04:18:23 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2017-02-15 04:18:23 +0000 |
commit | 171e4b545df5cedf8f631e6724a93cf90d42502c (patch) | |
tree | 54b377c293abf9630d2e87361608fb5185096d7f /clang/test/SemaCXX/cxx11-inheriting-ctors.cpp | |
parent | 96e36a67ed98340da023595dfc173340d74ecfbb (diff) | |
download | bcm5719-llvm-171e4b545df5cedf8f631e6724a93cf90d42502c.tar.gz bcm5719-llvm-171e4b545df5cedf8f631e6724a93cf90d42502c.zip |
Fix assertion failure due to implicit special member lookup lacking a source location.
llvm-svn: 295149
Diffstat (limited to 'clang/test/SemaCXX/cxx11-inheriting-ctors.cpp')
-rw-r--r-- | clang/test/SemaCXX/cxx11-inheriting-ctors.cpp | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/cxx11-inheriting-ctors.cpp b/clang/test/SemaCXX/cxx11-inheriting-ctors.cpp index c9e01188fd2..7d6f4f09f09 100644 --- a/clang/test/SemaCXX/cxx11-inheriting-ctors.cpp +++ b/clang/test/SemaCXX/cxx11-inheriting-ctors.cpp @@ -105,3 +105,31 @@ namespace PR31606 { // Note, we do *not* allow operator=='s argument to use the inherited A::A(Base&&) constructor to construct from B{}. bool b = A{} == B{}; // expected-error {{invalid operands}} } + +namespace implicit_member_srcloc { + template<class T> + struct S3 { + }; + + template<class T> + struct S2 { + S2(S3<T> &&); + }; + + template<class T> + struct S1 : S2<T> { + using S2<T>::S2; + S1(); + }; + + template<class T> + struct S0 { + S0(); + S0(S0&&) = default; + S1<T> m1; + }; + + void foo1() { + S0<int> s0; + } +} |