summaryrefslogtreecommitdiffstats
path: root/lib/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorRichard Trieu <rtrieu@google.com>2014-11-27 01:29:32 +0000
committerRichard Trieu <rtrieu@google.com>2014-11-27 01:29:32 +0000
commitabd574ee5ff726dd7560fcda33c6c0582c9128ae (patch)
tree15b75fecaa522a6d0955dbe6f6b40a44bd4d36fe /lib/Sema/SemaDecl.cpp
parentbde3837a8eea765eb7b3abaaed22f29b4429605d (diff)
When checking for uninitialized values, do not confuse "std::move" with every
other function named "move". git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@222863 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDecl.cpp')
-rw-r--r--lib/Sema/SemaDecl.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp
index 08f5c3c8b8..d299ec1e57 100644
--- a/lib/Sema/SemaDecl.cpp
+++ b/lib/Sema/SemaDecl.cpp
@@ -8489,7 +8489,8 @@ namespace {
// Treat std::move as a use.
if (E->getNumArgs() == 1) {
if (FunctionDecl *FD = E->getDirectCallee()) {
- if (FD->getIdentifier() && FD->getIdentifier()->isStr("move")) {
+ if (FD->isInStdNamespace() && FD->getIdentifier() &&
+ FD->getIdentifier()->isStr("move")) {
HandleValue(E->getArg(0));
return;
}