diff options
author | Nuno Lopes <nunoplopes@sapo.pt> | 2009-12-24 00:28:18 +0000 |
---|---|---|
committer | Nuno Lopes <nunoplopes@sapo.pt> | 2009-12-24 00:28:18 +0000 |
commit | cb1c77f90d4e747b83a0d0cc125dc01567378f82 (patch) | |
tree | 2e43194240fe7d8f7477350b525a277af0b27a6d /lib/AST/Expr.cpp | |
parent | f75b8309e3e40290683e3d34bac3a04e88d9c625 (diff) |
support the warn_unused_result in C++ class methods
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92095 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/Expr.cpp')
-rw-r--r-- | lib/AST/Expr.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/AST/Expr.cpp b/lib/AST/Expr.cpp index cb0165c8df..960d83d103 100644 --- a/lib/AST/Expr.cpp +++ b/lib/AST/Expr.cpp @@ -402,6 +402,8 @@ Decl *CallExpr::getCalleeDecl() { Expr *CEE = getCallee()->IgnoreParenCasts(); if (DeclRefExpr *DRE = dyn_cast<DeclRefExpr>(CEE)) return DRE->getDecl(); + if (MemberExpr *ME = dyn_cast<MemberExpr>(CEE)) + return ME->getMemberDecl(); return 0; } |