diff options
author | Jonas Toth <jonas.toth@gmail.com> | 2018-10-04 15:55:37 +0000 |
---|---|---|
committer | Jonas Toth <jonas.toth@gmail.com> | 2018-10-04 15:55:37 +0000 |
commit | 28a4c0ff3b4658c504399cf485dd370d03d88f14 (patch) | |
tree | b86cd0f22b366f6605e47fbf9de9bd919fac4fc1 /clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp | |
parent | d269579a97b58bcff3dca0b2636e51c6446b4cbb (diff) | |
download | bcm5719-llvm-28a4c0ff3b4658c504399cf485dd370d03d88f14.tar.gz bcm5719-llvm-28a4c0ff3b4658c504399cf485dd370d03d88f14.zip |
[clang-tidy] NFC use CHECK-NOTES in tests for performance-move-constructor-init
Reviewers: alexfh, aaron.ballman, hokein
Reviewed By: alexfh
Subscribers: lebedev.ri, xazax.hun, cfe-commits
Differential Revision: https://reviews.llvm.org/D52691
llvm-svn: 343791
Diffstat (limited to 'clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp')
-rw-r--r-- | clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp b/clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp index c9ed3469894..09108fcca35 100644 --- a/clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp +++ b/clang-tools-extra/test/clang-tidy/performance-move-constructor-init.cpp @@ -30,9 +30,9 @@ struct B { struct D : B { D() : B() {} D(const D &RHS) : B(RHS) {} - // CHECK-MESSAGES: :[[@LINE+3]]:16: warning: move constructor initializes base class by calling a copy constructor [performance-move-constructor-init] - // CHECK-MESSAGES: 26:3: note: copy constructor being called - // CHECK-MESSAGES: 27:3: note: candidate move constructor here + // CHECK-NOTES: :[[@LINE+3]]:16: warning: move constructor initializes base class by calling a copy constructor [performance-move-constructor-init] + // CHECK-NOTES: 26:3: note: copy constructor being called + // CHECK-NOTES: 27:3: note: candidate move constructor here D(D &&RHS) : B(RHS) {} }; @@ -75,8 +75,10 @@ struct L : K { struct M { B Mem; - // CHECK-MESSAGES: :[[@LINE+1]]:16: warning: move constructor initializes class member by calling a copy constructor [performance-move-constructor-init] + // CHECK-NOTES: :[[@LINE+1]]:16: warning: move constructor initializes class member by calling a copy constructor [performance-move-constructor-init] M(M &&RHS) : Mem(RHS.Mem) {} + // CHECK-NOTES: 26:3: note: copy constructor being called + // CHECK-NOTES: 27:3: note: candidate move constructor here }; struct N { @@ -109,7 +111,7 @@ struct TriviallyCopyable { struct Positive { Positive(Movable M) : M_(M) {} - // CHECK-MESSAGES: [[@LINE-1]]:12: warning: pass by value and use std::move [modernize-pass-by-value] + // CHECK-NOTES: [[@LINE-1]]:12: warning: pass by value and use std::move [modernize-pass-by-value] // CHECK-FIXES: Positive(Movable M) : M_(std::move(M)) {} Movable M_; }; |