summaryrefslogtreecommitdiff
path: root/lib/MC/MCParser
diff options
context:
space:
mode:
authorJakub Staszak <kubastaszak@gmail.com>2013-09-16 22:03:38 +0000
committerJakub Staszak <kubastaszak@gmail.com>2013-09-16 22:03:38 +0000
commitb06ea25b4c4cff341194279e01c08d23fa022378 (patch)
tree3f71872af461d1721ba5535f45c22014f6486de3 /lib/MC/MCParser
parent26a6348612e825a3ab636dee2f6e79212b2bda44 (diff)
downloadllvm-b06ea25b4c4cff341194279e01c08d23fa022378.tar.gz
llvm-b06ea25b4c4cff341194279e01c08d23fa022378.tar.bz2
llvm-b06ea25b4c4cff341194279e01c08d23fa022378.tar.xz
Use reference instead of copy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190813 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/MCParser')
-rw-r--r--lib/MC/MCParser/AsmParser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/MC/MCParser/AsmParser.cpp b/lib/MC/MCParser/AsmParser.cpp
index ae88a3ee73..2733f64a31 100644
--- a/lib/MC/MCParser/AsmParser.cpp
+++ b/lib/MC/MCParser/AsmParser.cpp
@@ -1646,7 +1646,7 @@ void AsmParser::DiagHandler(const SMDiagnostic &Diag, void *Context) {
// Use the CppHashFilename and calculate a line number based on the
// CppHashLoc and CppHashLineNumber relative to this Diag's SMLoc for
// the diagnostic.
- const std::string Filename = Parser->CppHashFilename;
+ const std::string &Filename = Parser->CppHashFilename;
int DiagLocLineNo = DiagSrcMgr.FindLineNumber(DiagLoc, DiagBuf);
int CppHashLocLineNo =