summaryrefslogtreecommitdiff
path: root/lib/MC/MCParser/AsmLexer.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2011-08-04 19:31:26 +0000
committerChris Lattner <sabre@nondot.org>2011-08-04 19:31:26 +0000
commit0ecd825e54f2235c133b44c967a612551633106c (patch)
tree5a5531cb5f0e61a04d93bc38e357eac78293de65 /lib/MC/MCParser/AsmLexer.cpp
parent2a66cea1b82b82c7bf19e232aed741331377ad30 (diff)
downloadllvm-0ecd825e54f2235c133b44c967a612551633106c.tar.gz
llvm-0ecd825e54f2235c133b44c967a612551633106c.tar.bz2
llvm-0ecd825e54f2235c133b44c967a612551633106c.tar.xz
allow \r's in .s files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136908 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/MCParser/AsmLexer.cpp')
-rw-r--r--lib/MC/MCParser/AsmLexer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/MC/MCParser/AsmLexer.cpp b/lib/MC/MCParser/AsmLexer.cpp
index 0c1f8f0df7..bbb0bbc8b2 100644
--- a/lib/MC/MCParser/AsmLexer.cpp
+++ b/lib/MC/MCParser/AsmLexer.cpp
@@ -146,7 +146,7 @@ AsmToken AsmLexer::LexLineComment() {
// FIXME: This is broken if we happen to a comment at the end of a file, which
// was .included, and which doesn't end with a newline.
int CurChar = getNextChar();
- while (CurChar != '\n' && CurChar != '\n' && CurChar != EOF)
+ while (CurChar != '\n' && CurChar != '\r' && CurChar != EOF)
CurChar = getNextChar();
if (CurChar == EOF)